Deconstruct VncThumbnailViewer 1.4.2 and add self-contained build
The shipped VncThumbnailViewerWin1.4.2.exe is a native launcher stub with a Java JAR appended. This commit adds: - src/: full Java source recovered from the bundled .class files (CFR), plus src/summary.txt with decompiler caveats - ANALYSIS.md: architecture, data flow, hosts-file format, and security notes - build-app-image.ps1: reproducible jpackage build that repackages the original classes and bundles a slim jlinked runtime (java.base + java.desktop) into a self-contained native app-image (no Java required on the target) The 74 MB app-image is shipped as a release asset rather than tracked. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,76 @@
|
||||
/*
|
||||
* Decompiled with CFR 0.152.
|
||||
*/
|
||||
import java.awt.Button;
|
||||
import java.awt.Color;
|
||||
import java.awt.Font;
|
||||
import java.awt.GridBagConstraints;
|
||||
import java.awt.GridBagLayout;
|
||||
import java.awt.Insets;
|
||||
import java.awt.Label;
|
||||
import java.awt.Panel;
|
||||
import java.awt.TextField;
|
||||
import java.awt.event.ActionEvent;
|
||||
import java.awt.event.ActionListener;
|
||||
|
||||
class AuthPanel
|
||||
extends Panel
|
||||
implements ActionListener {
|
||||
TextField passwordField;
|
||||
Button okButton;
|
||||
|
||||
public AuthPanel(VncViewer vncViewer) {
|
||||
Label label = new Label("VNC Authentication", 1);
|
||||
label.setFont(new Font("Helvetica", 1, 18));
|
||||
Label label2 = new Label("Password:", 1);
|
||||
this.passwordField = new TextField(10);
|
||||
this.passwordField.setForeground(Color.black);
|
||||
this.passwordField.setBackground(Color.white);
|
||||
this.passwordField.setEchoChar('*');
|
||||
this.okButton = new Button("OK");
|
||||
GridBagLayout gridBagLayout = new GridBagLayout();
|
||||
GridBagConstraints gridBagConstraints = new GridBagConstraints();
|
||||
this.setLayout(gridBagLayout);
|
||||
gridBagConstraints.gridwidth = 0;
|
||||
gridBagConstraints.insets = new Insets(0, 0, 20, 0);
|
||||
gridBagLayout.setConstraints(label, gridBagConstraints);
|
||||
this.add(label);
|
||||
gridBagConstraints.fill = 0;
|
||||
gridBagConstraints.gridwidth = 1;
|
||||
gridBagConstraints.insets = new Insets(0, 0, 0, 0);
|
||||
gridBagLayout.setConstraints(label2, gridBagConstraints);
|
||||
this.add(label2);
|
||||
gridBagLayout.setConstraints(this.passwordField, gridBagConstraints);
|
||||
this.add(this.passwordField);
|
||||
this.passwordField.addActionListener(this);
|
||||
gridBagConstraints.gridwidth = 0;
|
||||
gridBagConstraints.fill = 1;
|
||||
gridBagConstraints.insets = new Insets(0, 20, 0, 0);
|
||||
gridBagConstraints.ipadx = 30;
|
||||
gridBagLayout.setConstraints(this.okButton, gridBagConstraints);
|
||||
this.add(this.okButton);
|
||||
this.okButton.addActionListener(this);
|
||||
}
|
||||
|
||||
public void moveFocusToDefaultField() {
|
||||
this.passwordField.requestFocus();
|
||||
}
|
||||
|
||||
public synchronized void actionPerformed(ActionEvent actionEvent) {
|
||||
if (actionEvent.getSource() == this.passwordField || actionEvent.getSource() == this.okButton) {
|
||||
this.passwordField.setEnabled(false);
|
||||
this.notify();
|
||||
}
|
||||
}
|
||||
|
||||
public synchronized String getPassword() throws Exception {
|
||||
try {
|
||||
this.wait();
|
||||
}
|
||||
catch (InterruptedException interruptedException) {
|
||||
// empty catch block
|
||||
}
|
||||
return this.passwordField.getText();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user