Konloch / Konloch/bytecode-viewer

BCV is awesome, blocking write

Open
#389 1 comment 0 reactions 0 assignees View on GitHub
Bug
Dominant language
Java
Stars
15.6k
Forks
1.3k
PR merge metrics
No merged PRs in 30d

Description

Bytecode Viewer Version: 2.11.0

Please send this to [konloch@gmail.com](mailto:konloch@gmail.com).

Bytecode Viewer Version: 2.11.0

java.lang.SecurityException: BCV is awesome, blocking write(/Users/hekangbin);
at the.bytecode.club.bytecodeviewer.util.SecurityMan.checkWrite(SecurityMan.java:342)
at java.io.File.canWrite(File.java:791)
at sun.awt.shell.ShellFolder.canWrite(ShellFolder.java:368)
at com.apple.laf.AquaFileChooserUI$2.propertyChange(AquaFileChooserUI.java:403)
at java.beans.PropertyChangeSupport.fire(PropertyChangeSupport.java:335)
at java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:327)
at java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:263)
at java.awt.Component.firePropertyChange(Component.java:8434)
at javax.swing.JFileChooser.setCurrentDirectory(JFileChooser.java:598)
at javax.swing.JFileChooser.(JFileChooser.java:344)
at javax.swing.JFileChooser.(JFileChooser.java:296)
at the.bytecode.club.bytecodeviewer.gui.components.FileChooser.(FileChooser.java:43)
at the.bytecode.club.bytecodeviewer.util.DialogUtils.fileChooser(DialogUtils.java:95)
at the.bytecode.club.bytecodeviewer.util.DialogUtils.fileChooser(DialogUtils.java:84)
at the.bytecode.club.bytecodeviewer.util.DialogUtils.fileChooser(DialogUtils.java:76)
at the.bytecode.club.bytecodeviewer.resources.ExternalResources.selectJavac(ExternalResources.java:261)
at the.bytecode.club.bytecodeviewer.compilers.impl.JavaCompiler.compile(JavaCompiler.java:62)
at the.bytecode.club.bytecodeviewer.gui.resourceviewer.BytecodeViewPanel.compile(BytecodeViewPanel.java:91)
at the.bytecode.club.bytecodeviewer.BytecodeViewer.compile(BytecodeViewer.java:483)
at the.bytecode.club.bytecodeviewer.BytecodeViewer.autoCompileSuccessful(BytecodeViewer.java:457)
at the.bytecode.club.bytecodeviewer.resources.ResourceDecompiling.lambda$decompileSaveAll$8(ResourceDecompiling.java:54)
at java.lang.Thread.run(Thread.java:748)
Exception in thread "Decompile Thread" java.lang.SecurityException: BCV is awesome, blocking write(/Users/hekangbin);
at the.bytecode.club.bytecodeviewer.util.SecurityMan.checkWrite(SecurityMan.java:342)
at java.io.File.canWrite(File.java:791)
at sun.awt.shell.ShellFolder.canWrite(ShellFolder.java:368)
at com.apple.laf.AquaFileChooserUI$2.propertyChange(AquaFileChooserUI.java:403)
at java.beans.PropertyChangeSupport.fire(PropertyChangeSupport.java:335)
at java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:327)
at java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:263)
at java.awt.Component.firePropertyChange(Component.java:8434)
at javax.swing.JFileChooser.setCurrentDirectory(JFileChooser.java:598)
at javax.swing.JFileChooser.(JFileChooser.java:344)
at javax.swing.JFileChooser.(JFileChooser.java:296)
at the.bytecode.club.bytecodeviewer.gui.components.FileChooser.(FileChooser.java:43)
at the.bytecode.club.bytecodeviewer.gui.components.FileChooser.(FileChooser.java:39)
at the.bytecode.club.bytecodeviewer.resources.ResourceDecompiling.lambda$decompileSaveAll$8(ResourceDecompiling.java:57)
at java.lang.Thread.run(Thread.java:748)

Contributor guide

Open the contributing guide

Research direction

Start with SecurityMan.java at checkWrite line 342 and trace the file chooser path through FileChooser.java line 43, DialogUtils.java, and ExternalResources.java. Reproduce the compile or decompile-save flow on the reported macOS setup and determine why JFileChooser triggers the blocked write. Done means the flow no longer raises this SecurityException.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
desktop-dev
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.