Skip to content

Instantly share code, notes, and snippets.

@yudai
Created May 5, 2012 15:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save yudai/2603551 to your computer and use it in GitHub Desktop.
Save yudai/2603551 to your computer and use it in GitHub Desktop.
patch for wide_mkduid.pl to generate NGN-compatible DUIDs
--- wide_mkduid.pl.orig 2007-12-04 05:18:51.000000000 +0900
+++ wide_mkduid.pl 2012-05-06 00:56:25.207991279 +0900
@@ -79,8 +79,9 @@
# form the first two words of the DUID data: DUID type and link type.
# link-type is assumed to be ethernet(6)!
+# but for NGN, link-type is always 1!
-$duid_data = chr(0) . chr($duidtype) . chr(0) . chr(6);
+$duid_data = chr(0) . chr($duidtype) . chr(0) . chr(1);
if ( defined($opts{t}) ) {
# create string from byte values, host byte order
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment