FAQ - JEB Decompiler
Author: PNF Software

# JEB3 FAQ

Frequently asked answers to common questions and issues regarding JEB3. (The last section answers questions regarding JEB2, and is kept for reference only. All users are encouraged to migrate to JEB3.)

## Licensing

### Where is the end-user license agreement?

The up-to-date end-user license agreement for JEB can be found here.

### Can I generate license keys for additional machines?

Yes, as long as the additional machines are operated by the licensee, they may install JEB on them. Contact licensing to request the ability to generate additional keys. We handle those requests promptly.

### Can I revoke license keys?

Yes, JEB license keys can be deprecated. Contact licensing to request key revocation. We handle those requests promptly.

### How do I check my license type, license identifier, or license key?

From the command-line: execute JEB with the `-c --license` switches, eg:

    $ jeb_wincon.bat -c --license

From the UI client: open the menu entry Help, About.

### How do floating licenses work?

Floating licenses work on a per-seat basis, as opposed to other license types that work on a per-user basis. Example:

- A floating build valid for 3 seats allow any 3 users within your organization concurrently.
- A non-floating build valid for 3 users allow 3 fixed, determined users to use JEB. No other user can use it.

Therefore, floating builds provide great flexibility for organizations where many users are planning to use JEB irregularly and/or at different times (eg, teams split across various regions).

Please refer to this Manual entry to learn about setting up floating Controller and Clients.

### What happens when my license subscription expires?

JEB works on subscription. Past the expiration date, your software will continue to work and allow you to open and work on existing JDB2 projects, but you will not be able to create new projects.

### Do subscriptions renew automatically?

No. We do not perform auto-payments or auto-renewals. Please email sales when you need to renew a subscription.

### Do you offer subscriptions valid for more than one year?

Yes, we do offer custom subscriptions for up to 3 years. Email us at sales for details.

### Do you offer perpetual licenses?

No, we do not offer perpetual licenses at this point. However, we recommend you email sales and let us know your specific needs: we always strive to accommodate our customer's needs.

### Do you provide professional support?

We do offer an additional support plan for JEB Pro and JEB Pro Floating licenses. Refer to the Buy page for details.

### Do you offer large volume subscriptions?

Yes, we do have plans for large enterprise and government. Those plans include the possibility to generate large amount of license keys. Reach out to sales for additional details.

### We developed internal tools built around JEB. Can other users in my organization use them without breaking the EULA?

Yes. As long as your JEB subscription is valid, users in your organization may access and use data produced by JEB.

## Java

### Which version of Java shall I use to run JEB UI client?

We recommend users to run the JEB3 client with Java 8.191.

You may use newer versions of Java (9/10/11/12+) as well. However, at the time of writing, the native launcher (jeb.exe on Windows, jeb on Linux, jeb.app/ on macOS) may not start as smoothly with those newer JDK. If that happens, you can bypass the native launcher by using the '-j' flag with your start-up script. Example, on Linux: `jeb_linux.sh -j`.

If you have installed multiple versions of Java, we recommend you set the `JAVA_HOME` environment variable to point to your JDK version 8 folder.

Finally, the JEB3 client can always be started directly by running jebc.jar on the command line: `java -jar bin/app/jebc.jar`

### Which version of Java shall I use to run non-UI clients?

The back-end components of JEB3 (jeb.jar) work fine with with any version of Java 8.191 or above.

### JEB complains that it "requires a Java runtime environment", although I have one installed.

Your `java` binary should be accessible from the `PATH` environment variable. It is also recommended to set a `JAVA_HOME` environment variable pointing to your Java installation folder (bin/).

Make sure to install a 64-bit Java environment. A common source of problems are 64-bit systems having a 32-bit JRE accessible from the PATH or JAVA_HOME. You may have different versions of Java installed, but always make sure that paths refer to one that matches your system specifications.

### How can I increase the maximum amount of memory usable by JEB?

Edit the `jvmopt.txt` file at the root of your JEB folder. To increase the maximum amount of memory usable by JEB, adjust the `-Xmx` value.

Example: `-Xmx8G`: allow JEB to use up to 8 Gb of memory.

The settings in jvmopt.txt must be on a single line. After modifying this file, restart JEB with the platform-specific start-up script. On startup, a message in the logger output will reflect the updated capability:

> Note: do not attempt to edit the jeb.cfg files buried in bin/app or bin/jeb.app folders. The memory settings in those files are automatically pulled from jvmopt.txt.

## Program

### On which platforms can I run JEB?

The official JEB UI desktop client runs on 64-bit Windows, Linux, and macOS.

The JEB back-end components, which can be used separately to build other clients or analysis pipelines, run on all systems (64-bit and 32-bit) for which a Java Runtime Environment version 8 or above is available.

### What do I need to run JEB?

The only external dependency is a Java JRE or JDK. We strongly encourage users to install and use the Java JDK 8.191 to have a smooth JEB experience.

### How can I run multiple instances of JEB?

Multiple instances of JEB3 can run natively without configuration changes.

### How can I redirect JEB logs to files on disk?

Command-line runners, such as a floating license Controller or a script runner, can easily write log output to files. JEB version 3.1.1+ is required. (Note that other clients, such as the UI desktop client, can do that via scripting - refer to GlobalLog.)

Use the `--logfile=...` flag. Consult the Usage info for additional details on that switch (`"--help"`)

Example: Start a JEB Controller on Windows and log all INFO-level (or above) output to "controller.log.N" files (max. 5 rotating files, max. 2 Mb of log per file):

`jeb_wincon.bat -c --controller --logfiles=controller.log,INFO,5,2`

## UI

### JEB messages and strings are in my current (non-English) locale. How do I switch to English?

By default, JEB does its best to display messages in the current user's language settings. You may change the locale to English (or another one of the 10 supported languages) via the Edit, Language menu. See the Settings for details.

### I am trying to debug an Android application, but my device cannot be found.

JEB relies on the Android Debug Bridge (`adb`) to debug Android applications. Make sure to:

- install the Android SDK (or at least have a stand-alone, working adb binary accessible from your `PATH` - some Linux distros ship adb and other SDK platform tools in separate, leaner packages)
- have the SDK path referenced in one of the following environment variables: `ANDROID_SDK_ROOT` (preferred) or `ANDROID_HOME` (legacy).

To troubleshoot your system, you may enable Developer Mode in your JEB options and examine the logger output. You will see lines like the following indicating how and where JEB is attempting to find `adb`:

    [adb] ANDROID_HOME: Environment variable added to list of candidate Android SDK locations
    [adb] ANDROID_SDK_ROOT: Environment variable NOT found
    [adb] PATH: added to list of searched folders: (redacted)
    [adb] Searching for 'adb.exe' in folders, by order: (redacted)
    [adb] Found and using: C:\Users\nicol\AppData\Local\Android\sdk\platform-tools\adb.exe

### In JEB "Find text" or filter fields, why are my regular expressions invalid or not working?

JEB uses Java-style regular expressions, not PCRE, Boost, or other type of regex. Although the differences are minimal and subtle, complex regular expressions need to be carefully crafted and abide by the Java Pattern standard (refer to the "Comparison to Perl 5" section specifically).

## Updating

### I work in a limited-connectivity environment, how can I update the software manually?

If you are updating from JEB 2.2.5 or above, simply follow the prompt when JEB starts up or follow the procedure when executing the menu entry Help, Software Update.

If you are updating from JEB 2.2.4 or below, the procedure is the following:

- Check your registered email address for a JEB update email ("JEB xxx is available...")
- Download the software archive
- Copy the archive to the root of your JEB folder and rename the file to `update.zip`
- Create a text file named `update.pwd`
- Store the email-provided password inside this file
- Start JEB as normal; the update will be installed automatically

### I access Internet via a proxy. Can I still use JEB?

First, make sure to use JEB 3.0.8 or above. Proxy settings can be stored at those two locations:

- The UI client's settings, stored in `jeb-client.cfg`. If you are using the UI desktop client, they can be modified via the Options panel.
- In headless mode, set the proxy settings in `jeb-engines.cfg` instead.

In each aforementioned configuration file, the network proxy data is stored as a key-value pair having the following format: `.NetworkProxy = type|hostname|port|<username>|<password>|<whitelist>`

- Allowed types: http, socks.
- 'username'/'password' can be left blank if your proxy does not require authentication
- 'whitelist' is an optional, comma-separated list of wildcard hostnames/IPs to which JEB should always attempt to direct-connect (no proxy)

A few examples of valid proxy strings:

- http|10.0.0.123|8080
- http|10.0.0.123|8080||
- http|10.0.0.123|8080|||
- http|10.0.0.123|8080|||*.pnfsoftware.com
- socks|proxy0.intranet.com|8088|user|pass|*.pnfsoftware.com

Note: Do not forget the leading dot in .NetworkProxy!

### How do I update from JEB2 to JEB3?

At the time of writing, you must install JEB3 Beta (version: 3.0-beta.X) in a separate location. The auto-updater in JEB2 will only notify you that a JEB3 build is available for you to install. Check your email to download and install JEB3.

### Can I update from the command-line?

Yes, you can run:

`$ <jeb_startup_script> -c --check-update`

After the update is downloaded, execute JEB normally.

### JEB just auto-updated and I am now experiencing strange runtime issues. What can I do?

If the issues you are experiencing are showing up after a software update, at seemingly random times during program execution, and involve error messages like "Error invoking method" or "Failed to launch JVM", it is likely that your last JEB update did not fully complete.

Try to execute your start-up script (eg, on Windows, `jeb_wincon.bat`) instead of any native launcher you may have been previously using (such as an OS desktop taskbar shortcut).

If the issue is still happening, please email Support.

## Scripting

### Can I execute a JEB Python script from the command line?

Yes. Here's how to use the built-in script runner. You will need a Pro license.

- Make sure your JEB scripts/ folder contains the `jython-xxx.jar`. It should be the case if you are using JEB 3.1.
- Execute your JEB startup script with `--srv2` and `--script` parameters, as well as optional script arguments after `--`

Example on Windows:

    $ jeb_wincon.bat -c --srv2 --script=SampleScript.py -- foo bar

Use `-c --help` to learn about other options.

> Note: The command-line arguments (in the example above: foo, bar) can be retrieved via IClientContext.

> Note: Alternate ways exist to run scripts or plugins in headless contexts. Read through this guide and associated sample code if you want to know more about writing your own front-end clients.

### Can I write back-end extensions (plugins, contributions, etc.) in Python?

Soon! If all goes according to plan, we open support for Python back-end extensions starting with JEB 2.3.6.

## Other

### Is there a public bug/feature tracker?

Not at the moment. We are pretty responsive when it comes to answering users' queries though. Here's how to reach out:

- Send an email to Support
- Join us on Slack
- Ask your question on the JEB Google Groups
- Tweet or DM us @jebdec

## JEB2 (Legacy)

### (JEB2-only) Can I run the JEB2 desktop client on my 32-bit machine?

Yes. Prior to JEB 3.0-beta.8, JEB UI can also run on Windows 32-bit and Linux 32-bit.

### (JEB2-only) Which version of Java shall I use to run JEB2?

The JEB2 desktop client requires Java 8. The back-end components of JEB2 (`jeb.jar`) work fine with with Java 8, 9, and 10.

### (JEB2-only) How can I increase the maximum amount of memory usable by JEB2?

If unspecified, the memory cap is automatically decided upon starting up - and it will almost certainly be lower than what your system can offer.

In order to manually specify the maximum amount of memory usable by JEB, edit the file `bin/jeb.ini` located in your JEB folder. Add the following lines:

    -vmargs
    -Xmx????m

Replace `????` by the size amount of your choice, in Mb; eg, `4096` to allow JEB to use up to 4Gb. Note that other Java Virtual Machine options may be provided after the `-vmargs` (one option per line). Refer to the JVM manual for a complete list of options.

### (JEB2-only) I just upgraded to Java 8u131 or above (or Java 7u131), and JEB2 close immediately after start-up. What can I do?

The probable reason is that you must be using JEB 2.2.10 or below. Older versions of JEB are no compatible with the newer JDK/SDK. There are two ways to solve this problem:

- If you wish to stay on the JEB 2.2.x branch, install the latest update 2.2.11. You may use Java 7 or Java 8.

- We recommend you upgrade to the latest version of JEB, on the 2.3 or 3.0 branch. Make sure to use Java 8.

### (JEB2-only) How can I run multiple instances of JEB2?

Start your second and more instances of the JEB2 UI client by using the `-data @none` command-line argument.

Example on Windows:

    $ jeb_wincon.bat -data @none

Note that the customization of your UI workspace will not be ported over to this new instance, and will not be persisted upon closing either.

### (JEB2-only) JEB2 closes unexpectedly at start-up. How do I troubleshoot potential issues?

By default, console messages generated by JEB2 are logged to the `workspace/*log` or `workspace/.metadata/.log` file within your JEB directory. If you are using the UI client, adding those settings to your `bin/jeb.ini` file will instruct the UI framework to log debug messages to the console:

    -debug
    -consoleLog
    -noExit

Make sure to add them before any `-vmarg` parameter!

Restart JEB and examine the console log. If all else fails, please reach out to Support.

### (JEB2-only) How to execute a JEB Python script from the command line with JEB 2.3.4 (or older)?

Here is how to run Python scripts in a headless environment with JEB 2.3.4 or older:

- Make sure to drop a copy of Jython stand-alone JAR into your `scripts` folder
- Navigate to your JEB folder, sub-folder `bin/cl`
- Execute jeb.jar with `--script` and `--libdir` parameters, as well as optional script arguments (preceded by `--`)
- Also remember to set up two Java properties, using `-Dkey=value` command-lines flags:
  - `jeb.engcfg`: points to your `jeb-engines.cfg` file
  - `jeb.lickey`: contains a valid JEB license key (such as the value referenced in `.LicenseKey` in your `jeb-client.cfg` file)

Example:

    $ java -Djeb.engcfg=jeb-engines.cfg -Djeb.lickey=xxxxxxx -jar jeb.jar --script=1.py --libdir=xxxxx -- arg1 arg2 ...

> Note: The command-line arguments (arg1, arg2, ...) can be retrieved via IClientContext.

### (JEB2-only) I'm using JEB2 and cannot find menu entry [xxx], where is it?

You may need to reset the user interface state, via the Reset, UI State menu entry. A hard reset is to remove your `workspace/` folder within your JEB installation folder.

### (JEB2-only) What are the views marked as "Unbound" in the JEB2 UI Client?

Those entries are layout placeholders from previous JEB sessions. They help JEB determine the best location to display a unit of a given type. (Note that "Unbound Views" can be closed at any time.)

In the example below, DEX views and Java Decompiled views would be opened in their corresponding placeholders before attempting to create additional views.

#### Search

From here you can search these documents. Enter your search terms below.

#### Keyboard Shortcuts

Keys | Action
--- | ---
`?` | Open this help
`n` | Next page
`p` | Previous page
`s` | Search