mac2pwd(1)

πŸŽ€ mac2pwd(1) β€” Qualcomm Atheros Ethernet Device Password Generator πŸŽ€

okay so bestie, buckle up, because this one is a whole vibe: it's a password generator for Ethernet devices, and yes it's from the Qualcomm Atheros Open Powerline Toolkit. πŸ’–


🌸 NAME 🌸

mac2pwd β€” Qualcomm Atheros Ethernet Device Password Generator ✨


πŸ¦‹ SYNOPSIS πŸ¦‹

mac2pwd [options] file [file] [ ... ]

πŸ’… DESCRIPTION πŸ’…

So the whole thing is: you read Ethernet MAC addresses out of one or more files, and for every single address it prints a unique password. That's it, that's the job. 🫢

The output is literally built to be fed into the Qualcomm Atheros HomePlug AV Production Test System, or you can use it in your own custom production systems, no judgement. Input addresses can show up in any order and they do not need to be consecutive β€” the program does not care, it's not that kind of girl. The computed passwords are made of upper case letters and digits, with optional group separators if you're feeling fancy. And the output is address/password pairs, in text format.

This program is the one you want when you need to generate passwords for a large number of non-consecutive MAC addresses that occur in unspecified order. It's the complement to the program mac2pw, which generates passwords for consecutive MAC addresses over a given range β€” so they're like sisters, not twins. πŸ’• Options exist to modify the password algorithm, the password length, and the character bunching. Slay.

This program is part of the Qualcomm Atheros Powerline Toolkit. See the AMP man page for an overview and installation instructions. πŸ“š


⚠️ CAVEATS ⚠️

Atheros provides this program as a simple means of generating unique and apparently random device passwords for a large volume of Ethernet devices. Two different password algorithms are implemented β€” but neither one is required for HomePlug AV compliance. Vendors are free to use other methods to generate their own device passwords, and honestly they're encouraged to do so. Do your own thing, queen. πŸ‘‘

🎲 Random Method 🎲

Generate random passwords based on system entropy. A different set of passwords is generated for a given address range with each program execution. There is no correlation at all between addresses and passwords. This method is secure, but it requires care when programming and labelling devices at the factory β€” because if you lose the mapping, it's gone. 😭 It may be necessary to maintain a database if regular device maintenance and firmware upgrade are needed.

🏷️ Device Method 🏷️

Generate apparently random passwords based on device address. The same set of passwords will be generated for a given address range with each program execution β€” repeatable, consistent, iconic. This method may be appropriate on systems where regular maintenance and firmware updates are required.

⚠️ But bestie, listen: this method is not secure. Device addresses can be determined using a variety of network management programs. Anyone having access to this program, or the algorithm, could compute the device password and gain access to device features reserved for privileged users. 😱

This program does provide features to mitigate the risks of using this method. πŸ›‘οΈ


✨ OPTIONS ✨

  • -b bunch β€” The password bunching factor. Passwords consist of count uppercase letters and digits, optionally displayed in groups separated by hyphens. The bunching factor specifies the number of letters and digits in each group. When bunch is 0 or greater than count, bunching is suppressed. Separating hyphens increase overall password length. The minimum is 0 and the maximum is 255. The default is 0, which suppresses bunching. πŸŽ€
  • -e β€” Compute passwords based on host system entropy. Passwords consist of uppercase letters [A-Z], optionally grouped using option -b. This method produces a non-repeatable set of unique passwords over a given address range. This method is the default and is secure. πŸ’š
  • -l count β€” The number of letters in the password string. The default count is 16. Overall password length is the sum of count plus the number of delimiters implied by bunch. πŸ”’
  • -m β€” Compute passwords based on target device address. Passwords consist of uppercase letters [A-Z]. This method produces a repeatable set of unique passwords over a given address range. This method is not secure. 🚨
  • -q β€” Quiet mode. Exclude the MAC address on output. This option can be used in scripts to return the password associated with a given MAC address. 🀫
  • -v β€” Verbose mode. Prefix each line with a '0' column. The Atheros Production Test System (PTS) uses the first column of a password database file to indicate which addresses and passwords have already been used. βœ…
  • -?,--help β€” Print program help information on stdout. This option takes precedence over other options on the command line. πŸ†˜
  • -!,--version β€” Print program version information on stdout. This option takes precedence over other options on the command line. Use this option when sending screen dumps to Atheros Technical Support so that they know exactly which version of the Linux Toolkit you are using. πŸ“Έ

πŸ“‚ ARGUMENTS πŸ“‚

  • file β€” The name of a file that contains Ethernet address strings. Individual address strings consist of 12 consecutive hexadecimal digits. Addresses are seperated by whites space. This allows multiple addresses on a line. There is no line length limit. Punctuation is not permitted; however, a hash ('#') or semicolon (';') in any column starts comment text that continues to the end of that line. An error in any input file terminates the program with an error message. πŸ’€

🌈 EXAMPLES 🌈

An example input file, mac.txt, is shown below. Comment lines document the file. Blank lines are permitted and multiple addresses appear on one line. This file contains 5 MAC addresses. Punctuation is not permitted within a MAC address. 🚫

# =================================
# unused MAC addresses;
# ---------------------------------
00b052000004
00b052BABE33
00b052BABE34 00b052CAFE05
00b052CAFE01

Another example input file, mac2.txt, appears below. A hash ('#') and a semi-colon (';') are used to hide selected addresses. Hidden addresses are ignored because they are comments. This file contains 7 addresses but only 5 will be recognized. πŸ™ˆ

002b88ffff00
002b887fff00
# 002b88660066
002b88660067
002b88660063 ; 002b8800FFFF
002b88660066

The next example reads the two files shown above and prints 10 addresses, 5 from each file, with associated passwords. Output appears on the console but may be piped to a file or another process. πŸ”₯

# mac2pwd mac.txt more.mac
00B052000004 8C69GFCXATB8RA9SF52LK79UD
00B052BABE33 MMKGF5SP5DP23KHY27BSLRV2A
00B052BABE34 CVBG6QHJFQVVCYSACPAPBZT79
00B052CAFE05 MCXUABFPC33CPMXWFWYX5N2KC
00B052CAFE01 5GHUWD9YDEL8TCAGEZJ8ESRCC
002B88FFFF00 CJCW4VB2HZ37DAK2XE9CGCWZZ
002B887FFF00 W2W9AQU5TE8K4ZLH7R3K5C6X4
002B88660067 2LWQ5LGBUCDFDYSZYQ2XZSPJ2
002B88660063 62NKW6RM87UBZG34KH87AXXEY
002B88660066 KNQAGGFH9G9XQGR96GR4HK4SS

The next example does the the two files, as before, but shortens password length and groups password character. Overall password length includes password characters plus delimiters. Option -l sets password length to 16 characters. Option -b sets bunching to 4 characters. πŸ’…

# mac2pwd mac.txt more.mac -l 16 -b 4
00B052000004 R5YH-E6XG-TECA-24R8
00B052BABE33 WBQJ-77PC-VQTX-63Q5
00B052BABE34 4M2X-GVUY-6PYH-H5V7
00B052CAFE05 Z8JA-A2MV-49JF-WJZZ
00B052CAFE01 5L7Z-ZXZP-NUFS-RBKE
002B88FFFF00 3RAD-HQPN-92G2-HJKA
002B887FFF00 7YD7-9NJJ-39S7-8ZGF
002B88660067 HZ6K-SBG5-ZL8S-K2DK
002B88660063 MX5K-W7PF-T823-38MJ
002B88660066 PDXL-84QH-GKUN-KVEE

The next example is the same but prints output suitable for input to the Qualcomm Atheros PTS because option -v is specified. The output format is similar to that produced by the Qualcomm Atheros DB Builder Utility for Windows. πŸͺŸ

# mac2pwd -v mac.txt more.mac
0 00B052000004 ZZYBQP7EAZKBNWWCKKC4HX3AW
0 00B052BABE33 LG7XD97UPSBUHA6F7CU28P3WW
0 00B052BABE34 8BF288CZN4NTBUFSJAQLUYYNF
0 00B052CAFE05 RTK4XHMWKWWD654QRBQGW5UNH
0 00B052CAFE01 EE5YLRXD2EGKS6TSGZZK7ES74
0 002B88FFFF00 BRYJDWYGP79GFWZN8ZU8ZQ3GN
0 002B887FFF00 KEULLGC6PYFAM3FE89TYTSMP6
0 002B88660067 H4STMXB67QR22J39MAZQRHHA5
0 002B88660063 HKF32QX2GCZKGR3XYTMQCWTRB
0 002B88660066 STKF28Q2JXYEMAQZVQSFVTKFB

The next example omits the MAC address. This may used to generate random passwords for other purposes. 🎁

# mac2pwd -q mac.txt more.mac
W6QXL6KDY4SZLL538CAMWSH8N
PMYLFYMNA5TKYU2S6LBJS6QCR
B2P58XQ2L4JSNR6SXEZ6BSVSN
GYG6MS8NFEVH8EFBPD483WWCJ
44TQ6FYCVSGP9GLS6YSYRTWFQ
GUGPUJ6284X22ZU4RKXAX5T65
LGSV6L9Y9398DFY3Z2TUFBCAJ
H95A2FYV3LNT7BBFSLCLHXEH8
JXSY7TMKK6CP3LDWNE3M74G87
V4TEAG2ZX3J3NJHPAJMMQTQNT

πŸ“œ DISCLAIMER πŸ“œ

Qualcomm Atheros reserves the right to modify program names, functionality, input format or output format in future toolkit releases without any obligation to notify or compensate toolkit users. (Yes, they can just change things. Read the fine print, bestie. πŸ‘€)


πŸ‘€ SEE ALSO πŸ‘€

hpavkey(1), hpavkeys(1), keys(1), mac2pw(1), rkey(1)


🫢 CREDITS 🫢

  • Charles Maier
  • Pouyan Sepehrdad
  • Ning Shang

and that's the whole page, bestie, no cap. πŸ’– this little cutie lives in open-plc-utils-0.0.3, dated Feb 2015 β€” so go forth, generate those passwords, and stay secure out there. βœ¨πŸŽ€πŸ¦‹