diff options
author | Ralf S. Engelschall <rse@FreeBSD.org> | 2007-05-21 08:22:43 +0000 |
---|---|---|
committer | Ralf S. Engelschall <rse@FreeBSD.org> | 2007-05-21 08:22:43 +0000 |
commit | a8698e63bb3496c117bfccfbb3e1be5fd65fa001 (patch) | |
tree | 033e3802a4cc61149edf11b27facbd3385c5189b /etc/rc.d | |
parent | 9382f00b4657247a0dcc7fc49b87ca87cc520d77 (diff) | |
download | src-a8698e63bb3496c117bfccfbb3e1be5fd65fa001.tar.gz src-a8698e63bb3496c117bfccfbb3e1be5fd65fa001.zip |
The standardized textual representation of UUIDs according to RFC 4122
and ISO/IEC-9834-8:2005 is with LOWER-CASE hexadecimal characters only,
so translate the (usually upper-case and this way not conforming)
representation of the BIOS UUID when reading it. Also be more strict
about the valid characters in the textual representation by checking for
just the hexadecimal characters.
Notes
Notes:
svn path=/head/; revision=169818
Diffstat (limited to 'etc/rc.d')
-rw-r--r-- | etc/rc.d/hostid | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/etc/rc.d/hostid b/etc/rc.d/hostid index 2ba43982245f..6673aa012391 100644 --- a/etc/rc.d/hostid +++ b/etc/rc.d/hostid @@ -56,8 +56,8 @@ hostid_set() hostid_hardware() { - uuid=`kenv smbios.system.uuid 2>/dev/null` - x="[0-9a-zA-Z]" + uuid=`kenv smbios.system.uuid 2>/dev/null | tr '[:upper:]' '[:lower:]'` + x="[0-9a-f]" y=$x$x$x$x case "${uuid}" in $y$y-$y-$y-$y-$y$y$y) |