Skip to content

Instantly share code, notes, and snippets.

@geertweening
Created April 29, 2014 01:43
Show Gist options
  • Save geertweening/11388870 to your computer and use it in GitHub Desktop.
Save geertweening/11388870 to your computer and use it in GitHub Desktop.
var sjcl = require('sjcl');
function decodeDomain(domain) {
if (!domain) {
return 'no domain specified';
}
var domain = sjcl.codec.utf8String.fromBits(sjcl.codec.hex.toBits(domain));
return domain;
}
console.log(decodeDomain(process.argv[2]));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment