hackthebox.machine — HTB Machines
Machines
- class hackthebox.machine.Machine(data: dict, client: hackthebox.htb.HTBClient, summary: bool = False)[source]
The class representing Hack The Box machines
- name
The Machine name
- Type
str
- os
The name of the operating system
- Type
str
- points
The points awarded for completion
- Type
int
- release_date
The date the Machine was released
- Type
datetime.datetime
- user_owns
The number of user owns the Machine has
- root_owns
The number of root owns the Machine has
- Type
int
- free
Whether the Machine is available on free servers
- Type
bool
- user_owned
Whether the active User has owned the Machine’s user account
- Type
bool
- root_owned
Whether the active User has owned the Machine’s user account
- Type
bool
- reviewed
Whether the active User has reviewed the Machine
- Type
bool
- stars
The average star rating of the Machine
- Type
float
- avatar
The relative URL of the Machine avatar
- Type
str
- difficulty
The difficulty of the machine
- Type
str
- active
Whether the Machine is active
- Type
bool
- retired
Whether the Machine is retired
- Type
bool
- avg_difficulty
The average numeric difficulty of the Machine
- Type
int
- completed
Whether the active User has completed the Machine :noindex: user_own_time: How long the active User took to own user :noindex: root_own_time: How long the active User took to own root
- Type
bool
- user_blood
The Solve of the Machine’s first user blood
- root_blood
The Solve of the Machine’s first root blood
- user_own_time
How long the first User took to own user
- Type
datetime.timedelta
- root_own_time
How long the first User took to own root
- Type
datetime.timedelta
- difficulty_ratings
A dict of difficulty ratings given
- Type
dict
- property ip
The IP of an active machine.
- spawn(release_arena=False) hackthebox.machine.MachineInstance[source]
Spawn an instance of this machine.
- Parameters
release_arena – Whether to use Release Arena to spawn the machine
- Returns
The spawned MachineInstance
- start(release_arena=False) Optional[hackthebox.machine.MachineInstance][source]
Alias for Machine.spawn()
Machine Instances
- class hackthebox.machine.MachineInstance(ip: str, server: hackthebox.vpn.VPNServer, machine: hackthebox.machine.Machine, client: hackthebox.htb.HTBClient)[source]
Representation of an active machine instance
- ip
The IP the instance can be reached at
- Type
str
- server
The VPNServer that the machine is on
- machine
The Machine this is an instance of
- client
The passed-through API client