Monday, April 29, 2024
 Popular · Latest · Hot · Upcoming
3
rated 0 times [  3] [ 0]  / answers: 1 / hits: 5340  / 3 Years ago, sat, august 21, 2021, 1:24:56

How can I generate a new random wpa/wap2 key in the linux terminal? I tried pwgen but this is not generating hexadecimal values.


More From » wireless

 Answers
1

For instance, if you want a password with the maximum character length, i.e. 63, you can enter either of the following 2 commands:




  1. makepasswd --chars=63


  2. openssl rand -base64 63




UPDATE:



Here is a better command I've found for this purpose since I first wrote this answer:



dd if=/dev/urandom bs=48 count=1 status=none | base64 | tr +/ -_


Actually I use this zenity-powered script to generate such a password from time to time:



#!/bin/bash
RNDPWD="$(dd if=/dev/urandom bs=48 count=1 status=none | base64 | tr +/ -_)"
echo $RNDPWD | tr -d '
' | xclip -i -selection clipboard
zenity --question --title="Random Password" --text="<i>Password Copied to Clipboard:</i>

$RNDPWD

<b>Would you like to generate another one?</b>" --width=500 --height=150
if [ $? = 0 ]
then
"~/.bin/Password-Generator-GUI"
fi

[#33198] Saturday, August 21, 2021, 3 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
aradxalte

Total Points: 70
Total Questions: 116
Total Answers: 116

Location: Dominica
Member since Sat, Nov 5, 2022
2 Years ago
;