Skip to main content
  • Home
  • login
  • Browse the archive

    swh mirror partner logo
swh logo
SoftwareHeritage
Software
Heritage
Mirror
Features
  • Search

  • Downloads

  • Save code now

  • Add forge now

  • Help

  • 634118f
  • /
  • crypto
  • /
  • des
  • /
  • t
  • /
  • test
Raw File
Permalinks

To reference or cite the objects present in the Software Heritage archive, permalinks based on SoftWare Hash IDentifiers (SWHIDs) must be used.
Select below a type of object currently browsed in order to display its associated SWHID and permalink.

  • content
  • directory
content badge Iframe embedding
swh:1:cnt:97acd0552e43031d50d4ed3c25a3dd75d9c72add
directory badge Iframe embedding
swh:1:dir:0763f712dfa1a8d427dbed32d5044d8e36e45b7b
test
#!./perl

BEGIN { push(@INC, qw(../../../lib ../../lib ../lib lib)); }

use DES;

$key='00000000';
$ks=DES::set_key($key);
@a=split(//,$ks);
foreach (@a) { printf "%02x-",ord($_); }
print "\n";


$key=DES::random_key();
print "($_)\n";
@a=split(//,$key);
foreach (@a) { printf "%02x-",ord($_); }
print "\n";
$str="this is and again into the breach";
($k1,$k2)=DES::string_to_2keys($str);
@a=split(//,$k1);
foreach (@a) { printf "%02x-",ord($_); }
print "\n";
@a=split(//,$k2);
foreach (@a) { printf "%02x-",ord($_); }
print "\n";

ENEA — Copyright (C), ENEA. License: GNU AGPLv3+.
Legal notes  ::  JavaScript license information ::  Web API

back to top