ACL

Here is the acl interface definition in order to implement a new acl backend. It is composed by two classes.

class burpui.misc.acl.interface.BUIaclLoader(app=None)[source]

The burpui.misc.acl.interface.BUIaclLoader class is used to load the actual ACL backend

acl

Property to retrieve the backend

grants

Property to retrieve the list of grants

groups

Property to retrieve the list of groups with their members

init_app(app)[source]

Register the given app

reload()[source]

Reload the backend

class burpui.misc.acl.interface.BUIacl(app=None)[source]

The burpui.misc.acl.interface.BUIacl class represents the ACL engine.

init_app(app)[source]

Register the given app

is_admin(username=None)[source]

burpui.misc.acl.interface.BUIacl.is_admin() is used to know if a user has administrator rights.

Parameters:username (str) – Username to check
Returns:True if the user has admin rights, otherwise False
Return type:bool
is_client_allowed(username=None, client=None, server=None)[source]

burpui.misc.acl.interface.BUIacl.is_client_allowed() tells us if a given user has access to a given client on a given server.

Parameters:
  • username (str) – Username to check
  • client (str) – Client to check
  • server (str) – Server to check
Returns:

True if username is granted, otherwise False

Return type:

bool

is_client_rw(username=None, client=None, server=None)[source]

burpui.misc.acl.interface.BUIacl.is_client_rw() tells us if a given user has access to a given client on a given server in RW mode.

Parameters:
  • username (str) – Username to check
  • client (str) – Client to check
  • server (str) – Server to check
Returns:

True if username is granted, otherwise False

Return type:

bool

is_moderator(username=None)[source]

burpui.misc.acl.interface.BUIacl.is_moderator() is used to know if a user has moderator rights.

Parameters:username (str) – Username to check
Returns:True if the user has moderator rights, otherwise False
Return type:bool
is_server_allowed(username=None, server=None)[source]

burpui.misc.acl.interface.BUIacl.is_server_allowed() tells us if a given user has access to a given server.

Parameters:
  • username (str) – Username to check
  • server (str) – Server to check
Returns:

True if username is granted, otherwise False

Return type:

bool

is_server_rw(username=None, server=None)[source]

burpui.misc.acl.interface.BUIacl.is_server_rw() tells us if a given user has access to a given server in RW mode.

Parameters:
  • username (str) – Username to check
  • server (str) – Server to check
Returns:

True if username is granted, otherwise False

Return type:

bool

class burpui.misc.acl.meta.BUIgrantHandler(app=None)[source]

This class is here to handle grants in a generic way. It will automatically merge grants from various backends that register to it

changed(sid)[source]

detect a configuration change

grants

grants managed by our handler

groups

groups managed by our handler

id

current handler id, used to detect configuration changes

init_app(app)

Register the given app

is_admin(username)[source]

See burpui.misc.acl.interface.BUIacl.is_admin()

is_client_allowed(username=None, client=None, server=None)[source]

See burpui.misc.acl.interface.BUIacl.is_client_allowed()

is_client_rw(username=None, client=None, server=None)[source]

See burpui.misc.acl.interface.BUIacl.is_client_rw()

is_moderator(username)[source]

See burpui.misc.acl.interface.BUIacl.is_moderator()

is_server_allowed(username=None, server=None)[source]

See burpui.misc.acl.interface.BUIacl.is_server_allowed()

is_server_rw(username=None, server=None)[source]

See burpui.misc.acl.interface.BUIacl.is_server_rw()

opt(key, default=False)[source]

access a given option

options

options of our ACL engine

register_backend(name, backend)[source]

register a new ACL backend

Parameters:
reset(reset_from)[source]

a configuration change occurred, we reload our grants and groups

set_admin(admins)[source]

parse and set the admins

set_grant(name, grant)[source]

parse and set the given grants

set_group(name, members)[source]

parse and set the given group

set_moderator(moderators)[source]

parse and set the moderators

set_moderator_grants(grants)[source]

parse and set the moderators grants