mac2pw - Qualcomm Atheros Ethernet Device Password Generator
mac2pw [options] address [address] [...]
Print a range of consecutive Ethernet addresses and passwords on stdout such that each device has a unique password. Program output is suitable as input to the Qualcomm Atheros HomePlug AV Production Test System or may be used in custom production systems. A starting address and an address range are specified. Computed passwords consist of upper case letters and digits with optional group separators. Output consists of address/password pairs in text format.
This program is designed to generate passwords for a large number of consecutive device addresses. It complements program mac2pwd which generates passwords for non-consecutive device addresses occurring in unspecified order.
This program is part of the Qualcomm Atheros Powerline Toolkit. See the AMP man page for an overview and installation instructions.
provides this program as a simple means of generating unique
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 are encouraged to do so.
Generate 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 between addresses and passwords. This method is secure but requires care when programming and labelling devices at the factory. It may be necessary to maintain a database if regular device maintenance and firmware upgrade are needed.
Generate passwords based on device address. The same set of passwords will be generated for a given address range with each program execution. This method may be appropriate on system where regular maintenance and firmware updates are required. This method is not secure because 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.
The password bunching factor. Passwords consists 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.
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.
The number of letters in the password string. Overall password length is the sum of count plus the number of delimiters implied by bunch. The minimum is 12 and the maximum is 64. The default is 16.
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.
The number of consecutive addresses and passwords to compute and print. The minimum is 0 and the maximum is 1677215 or 0xFFFFFF. The default is 1. In addition, number cannot exceed the remaining available addresses in the vendor range. For example, given start address 00:B0:52:FF:FF:00, there are only 255 remaining addresses in the 00:B0:52 vendor range so it would be an error to request more than that number.
Quiet mode. Exclude the device address on output. This option can be used in scripts to return the password associated with a given device address.
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.
Print program help information on stdout. This option takes precedence over other options on the command line.
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.
The first Ethernet address expressed as 12 consecutive hexadecimal digits. Puncutation is not permitted. The final address of the range is computed by adding number to this address. This argument is required. There is no default address. If more than one device address is specified then an address/password series will be computed for each.
The following example prints the given device address and a random password string on stdout. The default password length is 25 characters long but the length can be changes using option -l.
Repeating the command will generate a new password string. This is the default behaviour and is the same as specifying option -e for "entropy".
This example ommits the device address. Repeating the command produces a new password string.
# mac2pw 00B052000001 -q
The next example shows how to generate passwords for three different devices with one command. The program generates a password for each device address specified on the command line.
00B052000001 00B05200BABE 00B05200DEAD
The next example prints 10 consecutive device addresses and random passwords on stdout. The starting device address is given and option -n specifies the number of addresses to print. Output can be piped to a file or another process.
00B052000001 -n 10
The following example prints 10 consecutive device addresses and passwords but inserts a 0 at the start of each line to indicate that the address and password have not been used. The Qualcomm Atheros Production Test System (PTS) will set the 0 to 1 after it programs a device. This format is simlar to PTS DBBuilder Utility output.
00B052000006 -n 10 -v
0 00B052000006 VZNKWJUHAV2687NV6EJYUVQ4D
0 00B052000007 RENKKWRNFLU4ZNZ3P6K4SZ4PG
0 00B052000008 NEL6LL2V2YZAL2Q27E2DJ25BG
0 00B052000009 MYX2T5HM68T5JCK7YYJNDWH2P
0 00B05200000A 6UY4MPYP43GXSD39VLTNZCJEZ
0 00B05200000B MD47KPFZLSNL9XRLJTN3MKJ5N
0 00B05200000C BKVTVYE47LE4DKMUNQPPXR7HL
0 00B05200000D RBJ8DA5DB48TZUTAQXZ9CPFTM
0 00B05200000E HSK6N9ZGZPGV4T5YXST4DH3W8
0 00B05200000F BLW8QQ4JMEVSQJYHRPBDGG5RS
The next example prints 10 consecutive device addresses and passwords, as before, but changes password length and character bunching. Option -l specifies 12 characters and option -b specifies a bunching factor of three.
00B052000001 -n 10 -l 12 -b 3
The next example prints 10 consecutive device addresses and passwords, as before, but starts from a different device address. We specified option -m so that passwords are generated based on the MAC address. This ensures that the same password is generated each time for a given device address. We also specified password length or 16 characters using option -l and bunching factor of 4 with option -b.
00B052000001 -m -l 16 -b 4 -n 10
The following example prints 10 consecutive device addresses and passwords, as before, but starts from a different device address. The address range here overlaps the range shown above but identical device addresses have identical passwords. Address based passwords may be of interest on large private networks requireing frequent firmware upgrades or device configuration.
00B052000006 -m -l 16 -b 4 -n 10
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.
hpavkey(1), hpavkeys(1), keys(1), mac2pwd(1), rkey(1)