GoToolSharing / htb-cli

Interact with Hackthebox using your terminal - Be faster and more competitive !
https://github.com/GoToolSharing/htb-cli
GNU General Public License v3.0
87 stars 6 forks source link

[FEAT] ip saved in an "env" + adding to hosts file #102

Open suljov opened 9 months ago

suljov commented 9 months ago
  1. The idea i got was that the fact the tool right now shows you the ip. but it might be good if the tool will ask the user to save the ip as an ENV to make it easier to use for other scans. (examples belov)

  2. it would be also nice/cool if the tool has a feature that it also saves the vhost name(s) in a simple way. so if the user finds a vhost name it can simply use the tool and the tool will put it in the hosts file. so the user can use that feature later on if he/she find more vhost names connected to the ip/machine

for example:

┌──(suljov㉿suljov)-[~]
└─$ ping $ip
PING 127.0.0.1 (127.0.0.1) 56(84) bytes of data.
64 bytes from 127.0.0.1: icmp_seq=1 ttl=64 time=0.021 ms
64 bytes from 127.0.0.1: icmp_seq=2 ttl=64 time=0.051 ms
64 bytes from 127.0.0.1: icmp_seq=3 ttl=64 time=0.039 ms

this will be good to use for other tools like nmap, rustscan, gobuster/feroxbuster etc.

examples:

nmap -sV -A $ip
gobuster dir -u http://$ip -w /usr/share/wordlists/seclists/Discovery/Web-Content/common.txt

and so on.

QU35T-code commented 9 months ago

Good idea, I'll think about it !

QU35T-code commented 9 months ago

Hey @suljov,

The first part is in beta. the hosts command allows you to perform basic actions with the /etc/hosts file.

https://htb-cli-documentation.qu35t.pw/commands/hosts/