Frontend

Blueprint that contains all of the frontend endpoints seen by the users of Bifrost.

class src.c2.views.frontend.AgentConfig(*args, **kwargs)
class src.c2.views.frontend.UserRegistration(*args, **kwargs)
src.c2.views.frontend.build_agent(ip: str = '127.0.0.1', sleeptime: str = '0') None

Builds the binary using the user provided config values

Parameters
  • ip (str) – The callback IP address, defaulted at localhost

  • sleeptime (str) – The amount of time the agent should wait to callback

Returns

none

Return type

None

src.c2.views.frontend.check_agents_statuses() None

Function that checks if an agent is still alive using its sleep time along with the last time it checked in

src.c2.views.frontend.config()

Endpoint that contains a form allowing the user to provide values for a custom config and generate a new agent binary

src.c2.views.frontend.display_agent(agent_id)

Endpoint that displays all the information regarding the agent with the specified ID, and includes an interactive shell.

Parameters

id (str) – The ID of the agent

src.c2.views.frontend.home()

Endpoint that displays a pwnboard that includes all of the active agents calling back to the server

src.c2.views.frontend.login()

Endpoint that allows a user to login and authenticate themselves with the server

src.c2.views.frontend.login_required(f)

Requires a user to login before they can access critical endpoints

Returns

redirects an unauthenticated user to /login

Return type

wrap

src.c2.views.frontend.logout()

Endpoint that allows a user to logout of their session

src.c2.views.frontend.signup()

Endpoint that allows a user to register an account