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

  • 72e1ac8
  • /
  • bio.pl
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:70a97e79256e2433278160b5157a84238b61b5cd
directory badge Iframe embedding
swh:1:dir:72e1ac845e1e2c2c3aa79ef56db7ae5647a322dc
bio.pl
#!/usr/local/bin/perl

use ExtUtils::testlib;

use SSLeay;

$cmd=<<"EOF";
GET / HTTP/1.0

EOF

$conn="localhost:4433";
$conn=$ARGV[0] if $#ARGV >= 0;
$bio=SSLeay::BIO::new("connect");
#$bio->set_callback(sub {print STDERR SSLeay::BIO::number_read($_[0])."\n"; $_[$#_] });
#$bio->set_callback(sub {print STDERR "$#_:".$_[0].":$_[1]:$_[2]:$_[3]:$_[4]:\n"; $_[$#_] });
$bio->hostname($conn) || die $ssl->error();


(($ret=$bio->do_handshake()) > 0) || die $bio->error();

(($ret=$bio->syswrite($cmd)) > 0) || die $bio->error();

while (1)
	{
	$ret=$bio->sysread($buf,10240);
	last if ($ret <= 0);
	print $buf;
	}

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

back to top