Security/Password: Difference between revisions

From Chorke Wiki
Jump to navigation Jump to search
Line 6: Line 6:
EXE
EXE
</syntaxhighlight>
</syntaxhighlight>
==Password » Random==
{|class='wikitable sortable' style='text-align:right'
!scope="col" rowspan='2' style='width:540px'|Access Key
!scope="col" colspan='4' style='width:240px'|Time (Seconds)
|-
!scope="col" style='width: 60px'|Real
!scope="col" style='width: 60px'|User
!scope="col" style='width: 60px'|System
!scope="col" style='width: 60px'|Status
|-
|style='text-align:left'| <code>time echo "$(cat /dev/urandom|tr -dc 'A-Za-z0-9'|head -c 20)"</code> || 0.007    || 0.001    || 0.012    ||style='text-align:center'| 🟢
|-
|style='text-align:left'| <code>time echo "$(openssl rand -base64 16|tr -d /=+|cut -c1-20)"</code>  || 0.009    || 0.002    || 0.012    ||style='text-align:center'| 🟡
|-
|style='text-align:left'| <code>time echo "$(openssl rand -hex 12|tr -d /=+|cut -c1-20)"</code>      || 0.008    || 0.003    || 0.009    ||style='text-align:center'| 🟡
|-
|style='text-align:left'| <code>time echo "$(makepasswd --chars 20)"</code>                          || 0.023    || 0.020    || 0.003    ||style='text-align:center'| 🔴
|}
----
{|class='wikitable sortable' style='text-align:right'
!scope="col" rowspan='2' style='width:540px'|Secret Key
!scope="col" colspan='4' style='width:240px'|Time (Seconds)
|-
!scope="col" style='width: 60px'|Real
!scope="col" style='width: 60px'|User
!scope="col" style='width: 60px'|System
!scope="col" style='width: 60px'|Status
|-
|style='text-align:left'| <code>time echo "$(cat /dev/urandom|tr -dc 'A-Za-z0-9'|head -c 40)"</code> || 0.006    || 0.003    || 0.007    ||style='text-align:center'| 🟢
|-
|style='text-align:left'| <code>time echo "$(openssl rand -base64 32|tr -d /=+|cut -c1-40)"</code>  || 0.007    || 0.003    || 0.009    ||style='text-align:center'| 🟡
|-
|style='text-align:left'| <code>time echo "$(openssl rand -hex 24|tr -d /=+|cut -c1-40)"</code>      || 0.009    || 0.003    || 0.011    ||style='text-align:center'| 🟡
|-
|style='text-align:left'| <code>time echo "$(makepasswd --chars 40)"</code>                          || 0.021    || 0.016    || 0.005    ||style='text-align:center'| 🔴
|}


==Playground==
==Playground==

Revision as of 18:01, 30 June 2025

cat <<'EXE'| sudo bash
apt-get update;echo
apt list -a --upgradable;echo
apt-get install -y makepasswd;echo;apt-get clean
EXE

Password » Random

Access Key Time (Seconds)
Real User System Status
time echo "$(cat /dev/urandom|tr -dc 'A-Za-z0-9'|head -c 20)" 0.007 0.001 0.012 🟢
time echo "$(openssl rand -base64 16|tr -d /=+|cut -c1-20)" 0.009 0.002 0.012 🟡
time echo "$(openssl rand -hex 12|tr -d /=+|cut -c1-20)" 0.008 0.003 0.009 🟡
time echo "$(makepasswd --chars 20)" 0.023 0.020 0.003 🔴

Secret Key Time (Seconds)
Real User System Status
time echo "$(cat /dev/urandom|tr -dc 'A-Za-z0-9'|head -c 40)" 0.006 0.003 0.007 🟢
time echo "$(openssl rand -base64 32|tr -d /=+|cut -c1-40)" 0.007 0.003 0.009 🟡
time echo "$(openssl rand -hex 24|tr -d /=+|cut -c1-40)" 0.009 0.003 0.011 🟡
time echo "$(makepasswd --chars 40)" 0.021 0.016 0.005 🔴

Playground

nmap vpn.shahed.biz --reason -Pn --top 20
nmap vpn.shahed.biz --reason -Pn -p25,465,587,993
sudo tail -n100 -f /var/log/auth.log
sudo tail -n100 -f /var/log/kern.log
sudo cat /etc/shadow|grep nobody
last

sudo apt-get install makepasswd
echo 'sadaqah!'|makepasswd --crypt-md5 --clearfrom=-
makepasswd --chars 12 --count 5 --crypt-md5
makepasswd --chars 12 --count 5 --crypt
makepasswd --chars 12 --count 5
makepasswd --chars 12

References