enterprise module¶
Class |
Description |
---|---|
Authenticate to the Enterprise Server with username/password credentials. |
|
Authenticate to the Enterprise Server with a non-password method. Note that many of these will |
|
Get a list of authentication methods accepted by the Enterprise Server. |
|
Cancel a call to |
|
Connect to the Enterprise Server. |
|
Deauthenticate from the Enterprise server, clearing any cached credentials. |
|
Initialize the Enterprise Client |
|
Determine if you have authenticated to the Enterprise Server. |
|
Determine if the Enterprise Server is currently connected. |
|
Determine if a floating license is currently active |
|
Determine if the Enterprise Client has been initialized yet. |
|
Determine if your current license checkout is still valid. |
|
Get a text representation the last error encountered by the Enterprise Client |
|
Get the duration of the current license checkout. |
|
Get the expiry time of the current license checkout. |
|
Release the currently checked out license back to the Enterprise Server. |
|
Get the maximum checkout duration allowed by the Enterprise Server. |
|
Get the build id string of the server |
|
Get the internal id of the server |
|
Get the display name of the server |
|
Get the url of the Enterprise Server. |
|
Get the version number of the server |
|
Set the url of the Enterprise Server. |
|
Get the token of the currently authenticated user to the Enterprise Server. |
|
Acquire or refresh a floating license from the Enterprise server. |
|
Get the username of the currently authenticated user to the Enterprise Server. |
LicenseCheckout¶
- class LicenseCheckout[source]¶
Bases:
object
Helper class for scripts to make use of a license checkout in a scope.
- Parameters:
duration – Duration between refreshes
_cache – Deprecated but left in for compatibility
release – If the license should be released at the end of scope. If False, you can either manually release it later or it will expire after duration.
- Example:
>>> enterprise.connect() >>> enterprise.authenticate_with_credentials("username", "password") >>> with enterprise.LicenseCheckout(): ... # Do some operation ... with load("/bin/ls") as bv: # e.g. ... print(hex(bv.start)) # License is released at end of scope
- __init__(duration=900, _cache=True, release=True)[source]¶
Get a new license checkout
- Parameters:
duration – Duration between refreshes
_cache – Deprecated but left in for compatibility
release – If the license should be released at the end of scope. If False, you can either manually release it later or it will expire after duration.
authenticate_with_credentials¶
authenticate_with_method¶
- class authenticate_with_method[source]¶
Bases:
Authenticate to the Enterprise Server with a non-password method. Note that many of these will open a URL for a browser-based login prompt, which may not be usable on headless installations. See
authentication_methods
for a list of accepted methods.
authentication_methods¶
cancel_authentication¶
- class cancel_authentication[source]¶
Bases:
Cancel a call to
authenticate_with_credentials
orauthenticate_with_method
. Note those functions are blocking, so this must be called on a separate thread.
connect¶
deauthenticate¶
initialize¶
is_authenticated¶
is_connected¶
is_floating_license¶
is_initialized¶
- class is_initialized[source]¶
Bases:
Determine if the Enterprise Client has been initialized yet.
- Returns:
True if
initialize
has been called
is_license_still_activated¶
last_error¶
license_duration¶
license_expiration_time¶
release_license¶
- class release_license[source]¶
Bases:
Release the currently checked out license back to the Enterprise Server.
Note
You must authenticate with the Enterprise Server before calling this.
Note
This will deactivate the Binary Ninja Enterprise client. You must call
acquire_license
again to continue using Binary Ninja Enterprise in the current process.