OpenSSL 1.1.1-pre2
This commit is contained in:
+56
-51
@@ -8,63 +8,68 @@
|
||||
|
||||
# This is just a quick script to scan for cases where the 'error'
|
||||
# function name in a XXXerr() macro is wrong.
|
||||
#
|
||||
#
|
||||
# Run in the top level by going
|
||||
# perl util/ck_errf.pl */*.c */*/*.c
|
||||
#
|
||||
|
||||
use strict;
|
||||
use warnings;
|
||||
|
||||
my $err_strict = 0;
|
||||
my $bad = 0;
|
||||
my $bad = 0;
|
||||
|
||||
foreach $file (@ARGV)
|
||||
{
|
||||
if ($file eq "-strict")
|
||||
{
|
||||
$err_strict = 1;
|
||||
next;
|
||||
}
|
||||
open(IN,"<$file") || die "unable to open $file\n";
|
||||
$func="";
|
||||
while (<IN>)
|
||||
{
|
||||
if (!/;$/ && /^\**([a-zA-Z_].*[\s*])?([A-Za-z_0-9]+)\(.*([),]|$)/)
|
||||
{
|
||||
/^([^()]*(\([^()]*\)[^()]*)*)\(/;
|
||||
$1 =~ /([A-Za-z_0-9]*)$/;
|
||||
$func = $1;
|
||||
$func =~ tr/A-Z/a-z/;
|
||||
}
|
||||
if (/([A-Z0-9]+)err\(([^,]+)/ && ! /ckerr_ignore/)
|
||||
{
|
||||
$errlib=$1;
|
||||
$n=$2;
|
||||
|
||||
if ($func eq "")
|
||||
{ print "$file:$.:???:$n\n"; $bad = 1; next; }
|
||||
|
||||
if ($n !~ /([^_]+)_F_(.+)$/)
|
||||
{
|
||||
# print "check -$file:$.:$func:$n\n";
|
||||
next;
|
||||
}
|
||||
$lib=$1;
|
||||
$n=$2;
|
||||
|
||||
if ($lib ne $errlib)
|
||||
{ print "$file:$.:$func:$n [${errlib}err]\n"; $bad = 1; next; }
|
||||
|
||||
$n =~ tr/A-Z/a-z/;
|
||||
if (($n ne $func) && ($errlib ne "SYS"))
|
||||
{ print "$file:$.:$func:$n\n"; $bad = 1; next; }
|
||||
# print "$func:$1\n";
|
||||
}
|
||||
}
|
||||
close(IN);
|
||||
foreach my $file (@ARGV) {
|
||||
if ( $file eq "-strict" ) {
|
||||
$err_strict = 1;
|
||||
next;
|
||||
}
|
||||
open( IN, "<$file" ) || die "Can't open $file, $!";
|
||||
my $func = "";
|
||||
while (<IN>) {
|
||||
if ( !/;$/ && /^\**([a-zA-Z_].*[\s*])?([A-Za-z_0-9]+)\(.*([),]|$)/ ) {
|
||||
/^([^()]*(\([^()]*\)[^()]*)*)\(/;
|
||||
$1 =~ /([A-Za-z_0-9]*)$/;
|
||||
$func = $1;
|
||||
$func =~ tr/A-Z/a-z/;
|
||||
}
|
||||
if ( /([A-Z0-9]+)err\(([^,]+)/ && !/ckerr_ignore/ ) {
|
||||
my $errlib = $1;
|
||||
my $n = $2;
|
||||
|
||||
if ($bad && $err_strict)
|
||||
{
|
||||
print STDERR "FATAL: error discrepancy\n";
|
||||
exit 1;
|
||||
}
|
||||
if ( $func eq "" ) {
|
||||
print "$file:$.:???:$n\n";
|
||||
$bad = 1;
|
||||
next;
|
||||
}
|
||||
|
||||
if ( $n !~ /([^_]+)_F_(.+)$/ ) {
|
||||
#print "check -$file:$.:$func:$n\n";
|
||||
next;
|
||||
}
|
||||
my $lib = $1;
|
||||
$n = $2;
|
||||
|
||||
if ( $lib ne $errlib ) {
|
||||
print "$file:$.:$func:$n [${errlib}err]\n";
|
||||
$bad = 1;
|
||||
next;
|
||||
}
|
||||
|
||||
$n =~ tr/A-Z/a-z/;
|
||||
if ( $n ne $func && $errlib ne "SYS" ) {
|
||||
print "$file:$.:$func:$n\n";
|
||||
$bad = 1;
|
||||
next;
|
||||
}
|
||||
|
||||
# print "$func:$1\n";
|
||||
}
|
||||
}
|
||||
close(IN);
|
||||
}
|
||||
|
||||
if ( $bad && $err_strict ) {
|
||||
print STDERR "FATAL: error discrepancy\n";
|
||||
exit 1;
|
||||
}
|
||||
+2
-2
@@ -41,7 +41,7 @@ if ($fnum <= 1)
|
||||
}
|
||||
|
||||
$dest = pop @filelist;
|
||||
|
||||
|
||||
if ($fnum > 2 && ! -d $dest)
|
||||
{
|
||||
die "Destination must be a directory";
|
||||
@@ -74,5 +74,5 @@ foreach (@filelist)
|
||||
close(OUT);
|
||||
print "Copying: $_ to $dfile\n";
|
||||
}
|
||||
|
||||
|
||||
|
||||
+5
-5
@@ -1,5 +1,5 @@
|
||||
#! /usr/bin/env perl
|
||||
# Copyright 2016-2018 The OpenSSL Project Authors. All Rights Reserved.
|
||||
# Copyright 2016 The OpenSSL Project Authors. All Rights Reserved.
|
||||
#
|
||||
# Licensed under the OpenSSL license (the "License"). You may not use
|
||||
# this file except in compliance with the License. You can obtain a copy
|
||||
@@ -92,21 +92,21 @@ package main;
|
||||
# Helper functions for the templates #################################
|
||||
|
||||
# It might be practical to quotify some strings and have them protected
|
||||
# from possible harm. These functions primarly quote things that might
|
||||
# from possible harm. These functions primarily quote things that might
|
||||
# be interpreted wrongly by a perl eval.
|
||||
|
||||
# quotify1 STRING
|
||||
# This adds quotes (") around the given string, and escapes any $, @, \,
|
||||
# " and ' by prepending a \ to them.
|
||||
sub quotify1 {
|
||||
my $s = my $orig = shift @_;
|
||||
my $s = shift @_;
|
||||
$s =~ s/([\$\@\\"'])/\\$1/g;
|
||||
$s ne $orig || $s =~ /\s/ ? '"'.$s.'"' : $s;
|
||||
'"'.$s.'"';
|
||||
}
|
||||
|
||||
# quotify_l LIST
|
||||
# For each defined element in LIST (i.e. elements that aren't undef), have
|
||||
# it quotified with 'quotofy1'
|
||||
# it quotified with 'quotify1'
|
||||
sub quotify_l {
|
||||
map {
|
||||
if (!defined($_)) {
|
||||
|
||||
+17
-21
@@ -1,5 +1,5 @@
|
||||
#! /usr/bin/env perl
|
||||
# Copyright 2002-2016 The OpenSSL Project Authors. All Rights Reserved.
|
||||
# Copyright 2002-2018 The OpenSSL Project Authors. All Rights Reserved.
|
||||
#
|
||||
# Licensed under the OpenSSL license (the "License"). You may not use
|
||||
# this file except in compliance with the License. You can obtain a copy
|
||||
@@ -24,7 +24,6 @@ our($opt_h);
|
||||
our($opt_l);
|
||||
our($opt_n);
|
||||
our($opt_p);
|
||||
our($opt_s);
|
||||
our($opt_u);
|
||||
our($opt_c);
|
||||
|
||||
@@ -35,7 +34,6 @@ Find small errors (nits) in documentation. Options:
|
||||
-d Detailed list of undocumented (implies -u)
|
||||
-l Print bogus links
|
||||
-n Print nits in POD pages
|
||||
-s Also print missing sections in POD pages (implies -n)
|
||||
-p Warn if non-public name documented (implies -n)
|
||||
-u List undocumented functions
|
||||
-h Print this help message
|
||||
@@ -154,14 +152,9 @@ sub check()
|
||||
|
||||
my $id = "${filename}:1:";
|
||||
|
||||
# Find what section this page is in; assume 3.
|
||||
my $section = 3;
|
||||
$section = 1 if $dirname eq 'apps';
|
||||
$section = $1 if ( $contents =~ /=for comment openssl_manual_section:(\d)/);
|
||||
|
||||
&name_synopsis($id, $filename, $contents)
|
||||
unless $contents =~ /=for comment generic/
|
||||
or $section != 3;
|
||||
or $filename =~ m@man[157]/@;
|
||||
|
||||
print "$id doesn't start with =pod\n"
|
||||
if $contents !~ /^=pod/;
|
||||
@@ -190,7 +183,7 @@ sub check()
|
||||
|
||||
if ( $contents !~ /=for comment multiple includes/ ) {
|
||||
# Look for multiple consecutive openssl #include lines
|
||||
# (non-consecutive lines are okay; see crypto/MD5.pod).
|
||||
# (non-consecutive lines are okay; see man3/MD5.pod).
|
||||
if ( $contents =~ /=head1 SYNOPSIS(.*)=head1 DESCRIPTION/ms ) {
|
||||
my $count = 0;
|
||||
foreach my $line ( split /\n+/, $1 ) {
|
||||
@@ -216,9 +209,12 @@ sub check()
|
||||
close $OUT;
|
||||
unlink $temp || warn "Can't remove $temp, $!";
|
||||
|
||||
# Find what section this page is in; assume 3.
|
||||
my $section = 3;
|
||||
$section = $1 if $dirname =~ /man([1-9])/;
|
||||
|
||||
foreach ((@{$mandatory_sections{'*'}}, @{$mandatory_sections{$section}})) {
|
||||
# Skip "return values" if not -s
|
||||
next if $_ eq 'RETURN VALUES' and not $opt_s;
|
||||
print "$id: missing $_ head1 section\n"
|
||||
if $contents !~ /^=head1\s+${_}\s*$/m;
|
||||
}
|
||||
@@ -375,7 +371,7 @@ sub collectnames {
|
||||
# then remove 'something'. Note that 'something'
|
||||
# may contain POD codes as well...
|
||||
(?:(?:[^\|]|<[^>]*>)*\|)?
|
||||
# we're only interested in referenses that have
|
||||
# we're only interested in references that have
|
||||
# a one digit section number
|
||||
([^\/>\(]+\(\d\))
|
||||
/gx;
|
||||
@@ -437,7 +433,7 @@ sub checkflags() {
|
||||
close CFH;
|
||||
|
||||
# Get the list of flags from the synopsis
|
||||
open CFH, "<doc/apps/$cmd.pod"
|
||||
open CFH, "<doc/man1/$cmd.pod"
|
||||
|| die "Can't open $cmd.pod, $!";
|
||||
while ( <CFH> ) {
|
||||
chop;
|
||||
@@ -455,7 +451,7 @@ sub checkflags() {
|
||||
if ( scalar @undocced > 0 ) {
|
||||
$ok = 0;
|
||||
foreach ( @undocced ) {
|
||||
print "doc/apps/$cmd.pod: Missing -$_\n";
|
||||
print "doc/man1/$cmd.pod: Missing -$_\n";
|
||||
}
|
||||
}
|
||||
|
||||
@@ -468,20 +464,20 @@ sub checkflags() {
|
||||
$ok = 0;
|
||||
foreach ( @unimpl ) {
|
||||
next if defined $skips{$_};
|
||||
print "doc/apps/$cmd.pod: Not implemented -$_\n";
|
||||
print "doc/man1/$cmd.pod: Not implemented -$_\n";
|
||||
}
|
||||
}
|
||||
|
||||
return $ok;
|
||||
}
|
||||
|
||||
getopts('cdlnsphu');
|
||||
getopts('cdlnphu');
|
||||
|
||||
&help() if $opt_h;
|
||||
$opt_n = 1 if $opt_s or $opt_p;
|
||||
$opt_n = 1 if $opt_p;
|
||||
$opt_u = 1 if $opt_d;
|
||||
|
||||
die "Need one of -[cdlnspu] flags.\n"
|
||||
die "Need one of -[cdlnpu] flags.\n"
|
||||
unless $opt_c or $opt_l or $opt_n or $opt_u;
|
||||
|
||||
if ( $opt_c ) {
|
||||
@@ -500,8 +496,8 @@ if ( $opt_c ) {
|
||||
# See if each has a manpage.
|
||||
foreach ( @commands ) {
|
||||
next if $_ eq 'help' || $_ eq 'exit';
|
||||
if ( ! -f "doc/apps/$_.pod" ) {
|
||||
print "doc/apps/$_.pod does not exist\n";
|
||||
if ( ! -f "doc/man1/$_.pod" ) {
|
||||
print "doc/man1/$_.pod does not exist\n";
|
||||
$ok = 0;
|
||||
} else {
|
||||
$ok = 0 if not &checkflags($_);
|
||||
@@ -537,7 +533,7 @@ if ( $opt_n ) {
|
||||
}
|
||||
|
||||
if ( $opt_u ) {
|
||||
my %temp = &getdocced('doc/crypto');
|
||||
my %temp = &getdocced('doc/man3');
|
||||
foreach ( keys %temp ) {
|
||||
$docced{$_} = $temp{$_};
|
||||
}
|
||||
|
||||
@@ -1,82 +0,0 @@
|
||||
#! /usr/bin/env perl
|
||||
# Copyright 2016 The OpenSSL Project Authors. All Rights Reserved.
|
||||
#
|
||||
# Licensed under the OpenSSL license (the "License"). You may not use
|
||||
# this file except in compliance with the License. You can obtain a copy
|
||||
# in the file LICENSE in the source distribution or at
|
||||
# https://www.openssl.org/source/license.html
|
||||
|
||||
use strict;
|
||||
use warnings;
|
||||
|
||||
use File::Spec::Functions;
|
||||
use File::Basename;
|
||||
#use File::Copy;
|
||||
#use File::Path;
|
||||
use lib catdir(dirname($0), "perl");
|
||||
use OpenSSL::Util::Pod;
|
||||
|
||||
my %dups;
|
||||
|
||||
sub parsenum()
|
||||
{
|
||||
my $file = shift;
|
||||
my @apis;
|
||||
|
||||
open my $IN, '<', $file
|
||||
or die "Can't open $file, $!, stopped";
|
||||
|
||||
while ( <$IN> ) {
|
||||
next if /\sNOEXIST/;
|
||||
next if /EXPORT_VAR_AS_FUNC/;
|
||||
push @apis, $1 if /([^\s]+).\s/;
|
||||
}
|
||||
|
||||
close $IN;
|
||||
|
||||
print "# Found ", scalar(@apis), " in $file\n";
|
||||
return sort @apis;
|
||||
}
|
||||
|
||||
sub getdocced()
|
||||
{
|
||||
my $dir = shift;
|
||||
my %return;
|
||||
|
||||
foreach my $pod ( glob("$dir/*.pod") ) {
|
||||
next if $pod eq 'doc/crypto/crypto.pod';
|
||||
next if $pod eq 'doc/ssl/ssl.pod';
|
||||
my %podinfo = extract_pod_info($pod);
|
||||
foreach my $n ( @{$podinfo{names}} ) {
|
||||
$return{$n} = $pod;
|
||||
print "# Duplicate $n in $pod and $dups{$n}\n"
|
||||
if defined $dups{$n};
|
||||
$dups{$n} = $pod;
|
||||
}
|
||||
}
|
||||
|
||||
return %return;
|
||||
}
|
||||
|
||||
sub printem()
|
||||
{
|
||||
my $docdir = shift;
|
||||
my $numfile = shift;
|
||||
my %docced = &getdocced($docdir);
|
||||
my $count = 0;
|
||||
|
||||
foreach my $func ( &parsenum($numfile) ) {
|
||||
next if $docced{$func};
|
||||
|
||||
# Skip ASN1 utilities
|
||||
next if $func =~ /^ASN1_/;
|
||||
|
||||
print $func, "\n";
|
||||
$count++;
|
||||
}
|
||||
print "# Found $count missing from $numfile\n\n";
|
||||
}
|
||||
|
||||
|
||||
&printem('doc/crypto', 'util/libcrypto.num');
|
||||
&printem('doc/ssl', 'util/libssl.num');
|
||||
+20
-1
@@ -13,8 +13,27 @@
|
||||
export X1=/tmp/f.1.$$
|
||||
export X2=/tmp/f.2.$$
|
||||
|
||||
case "$1" in
|
||||
-f)
|
||||
PAT='_F_'
|
||||
echo Functions only
|
||||
;;
|
||||
-[er])
|
||||
PAT='_R_'
|
||||
echo Reason codes only
|
||||
;;
|
||||
"")
|
||||
PAT='_[FR]_'
|
||||
echo Function and reasons
|
||||
;;
|
||||
*)
|
||||
echo "Usage error; one of -[efr] required."
|
||||
exit 1;
|
||||
;;
|
||||
esac
|
||||
|
||||
cd include/openssl || exit 1
|
||||
grep '_[RF]_' * | awk '{print $3;}' | sort -u >$X1
|
||||
grep "$PAT" * | grep -v ERR_FATAL_ERROR | awk '{print $3;}' | sort -u >$X1
|
||||
cd ../..
|
||||
|
||||
for F in `cat $X1` ; do
|
||||
|
||||
@@ -1,115 +0,0 @@
|
||||
#! /usr/bin/env perl
|
||||
# Copyright 2011-2016 The OpenSSL Project Authors. All Rights Reserved.
|
||||
#
|
||||
# Licensed under the OpenSSL license (the "License"). You may not use
|
||||
# this file except in compliance with the License. You can obtain a copy
|
||||
# in the file LICENSE in the source distribution or at
|
||||
# https://www.openssl.org/source/license.html
|
||||
|
||||
sub check_env
|
||||
{
|
||||
my @ret;
|
||||
foreach (@_)
|
||||
{
|
||||
die "Environment variable $_ not defined!\n" unless exists $ENV{$_};
|
||||
push @ret, $ENV{$_};
|
||||
}
|
||||
return @ret;
|
||||
}
|
||||
|
||||
|
||||
my ($fips_cc,$fips_cc_args, $fips_link,$fips_target, $fips_libdir, $sha1_exe)
|
||||
= check_env("FIPS_CC", "FIPS_CC_ARGS", "FIPS_LINK", "FIPS_TARGET",
|
||||
"FIPSLIB_D", "FIPS_SHA1_EXE");
|
||||
|
||||
|
||||
|
||||
if (exists $ENV{"PREMAIN_DSO_EXE"})
|
||||
{
|
||||
$fips_premain_dso = $ENV{"PREMAIN_DSO_EXE"};
|
||||
}
|
||||
else
|
||||
{
|
||||
$fips_premain_dso = "";
|
||||
}
|
||||
|
||||
check_hash($sha1_exe, "fips_premain.c");
|
||||
check_hash($sha1_exe, "fipscanister.lib");
|
||||
|
||||
|
||||
print "Integrity check OK\n";
|
||||
|
||||
if (is_premain_linked(@ARGV)) {
|
||||
print "$fips_cc $fips_cc_args $fips_libdir/fips_premain.c\n";
|
||||
system "$fips_cc $fips_cc_args $fips_libdir/fips_premain.c";
|
||||
die "First stage Compile failure" if $? != 0;
|
||||
} elsif (!defined($ENV{FIPS_SIG})) {
|
||||
die "no fips_premain.obj linked";
|
||||
}
|
||||
|
||||
print "$fips_link @ARGV\n";
|
||||
system "$fips_link @ARGV";
|
||||
die "First stage Link failure" if $? != 0;
|
||||
|
||||
if (defined($ENV{FIPS_SIG})) {
|
||||
print "$ENV{FIPS_SIG} $fips_target\n";
|
||||
system "$ENV{FIPS_SIG} $fips_target";
|
||||
die "$ENV{FIPS_SIG} $fips_target failed" if $? != 0;
|
||||
exit;
|
||||
}
|
||||
|
||||
print "$fips_premain_dso $fips_target\n";
|
||||
system("$fips_premain_dso $fips_target >$fips_target.sha1");
|
||||
die "Get hash failure" if $? != 0;
|
||||
open my $sha1_res, '<', $fips_target.".sha1" or die "Get hash failure";
|
||||
$fips_hash=<$sha1_res>;
|
||||
close $sha1_res;
|
||||
unlink $fips_target.".sha1";
|
||||
$fips_hash =~ s|\R$||; # Better chomp
|
||||
die "Get hash failure" if $? != 0;
|
||||
|
||||
|
||||
print "$fips_cc -DHMAC_SHA1_SIG=\\\"$fips_hash\\\" $fips_cc_args $fips_libdir/fips_premain.c\n";
|
||||
system "$fips_cc -DHMAC_SHA1_SIG=\\\"$fips_hash\\\" $fips_cc_args $fips_libdir/fips_premain.c";
|
||||
die "Second stage Compile failure" if $? != 0;
|
||||
|
||||
|
||||
print "$fips_link @ARGV\n";
|
||||
system "$fips_link @ARGV";
|
||||
die "Second stage Link failure" if $? != 0;
|
||||
|
||||
sub is_premain_linked
|
||||
{
|
||||
return 1 if (grep /fips_premain\.obj/,@_);
|
||||
foreach (@_)
|
||||
{
|
||||
if (/^@(.*)/ && -f $1)
|
||||
{
|
||||
open FD,$1 or die "can't open $1";
|
||||
my $ret = (grep /fips_premain\.obj/,<FD>)?1:0;
|
||||
close FD;
|
||||
return $ret;
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
sub check_hash
|
||||
{
|
||||
my ($sha1_exe, $filename) = @_;
|
||||
my ($hashfile, $hashval);
|
||||
|
||||
open(IN, "${fips_libdir}/${filename}.sha1") || die "Cannot open file hash file ${fips_libdir}/${filename}.sha1";
|
||||
$hashfile = <IN>;
|
||||
close IN;
|
||||
$hashval = `$sha1_exe ${fips_libdir}/$filename`;
|
||||
$hashfile =~ s|\R$||; # Better chomp
|
||||
$hashval =~ s|\R$||; # Better chomp
|
||||
$hashfile =~ s/^.*=\s+//;
|
||||
$hashval =~ s/^.*=\s+//;
|
||||
die "Invalid hash syntax in file" if (length($hashfile) != 40);
|
||||
die "Invalid hash received for file" if (length($hashval) != 40);
|
||||
die "***HASH VALUE MISMATCH FOR FILE $filename ***" if ($hashval ne $hashfile);
|
||||
}
|
||||
|
||||
|
||||
-454
@@ -1,454 +0,0 @@
|
||||
#! /usr/bin/env perl
|
||||
# Copyright 2011-2016 The OpenSSL Project Authors. All Rights Reserved.
|
||||
#
|
||||
# Licensed under the OpenSSL license (the "License"). You may not use
|
||||
# this file except in compliance with the License. You can obtain a copy
|
||||
# in the file LICENSE in the source distribution or at
|
||||
# https://www.openssl.org/source/license.html
|
||||
|
||||
# The script embeds fingerprint into ELF executable object, either
|
||||
# application binary or shared library.
|
||||
|
||||
######################################################################
|
||||
#
|
||||
# ELF symbol table parser by <appro@openssl.org>. The table entries
|
||||
# are extended with offset within executable file...
|
||||
#
|
||||
{ package ELF;
|
||||
use FileHandle;
|
||||
|
||||
sub dup { my %copy=map {$_} @_; return \%copy; }
|
||||
|
||||
sub Load {
|
||||
my $class = shift;
|
||||
my $self = {};
|
||||
my $FD = FileHandle->new(); # autoclose
|
||||
|
||||
bless $self,$class;
|
||||
|
||||
sysopen($FD,shift,0) or die "$!";
|
||||
binmode($FD);
|
||||
|
||||
#################################################
|
||||
# read and parse elf_ehdr.e_ident...
|
||||
#
|
||||
read($FD,my $elf,16) or die "$!";
|
||||
|
||||
my %e_ident;
|
||||
@e_ident{magic,class,data,version,osabi,abiver,pad}=
|
||||
unpack("a4C*",$elf);
|
||||
|
||||
$!=42; # signal fipsld to revert to two-step link
|
||||
die "not ELF file" if ($e_ident{magic} ne chr(0177)."ELF");
|
||||
|
||||
my $elf_bits = $e_ident{class}*32; # 32 or 64
|
||||
my $big_endian = $e_ident{data}-1; # 0 or 1
|
||||
|
||||
if ($elf_bits==64) {
|
||||
if (!(((1<<31)<<1) && $big_endian==(unpack("L",pack("N",1))==1))) {
|
||||
die "ELF64 is supported only natively";
|
||||
}
|
||||
}
|
||||
|
||||
#################################################
|
||||
# read and parse remainder of elf_ehdr...
|
||||
#
|
||||
read($FD,my $elfhdr,64) or die "$!";
|
||||
|
||||
my %elf_ehdr;
|
||||
@elf_ehdr{e_type,e_machine,e_version,
|
||||
e_entry,e_phoff,e_shoff,e_flags,e_ehsize,
|
||||
e_phentsize,e_phnum,e_shentsize,e_shnum,e_shstrndx} =
|
||||
$elf_bits==32 ?
|
||||
unpack($big_endian?"nnN5n6":"vvV5v6",$elfhdr)
|
||||
: unpack("SSLQ3LS6",$elfhdr);
|
||||
|
||||
# put aside e_machine in case one has to treat specific
|
||||
# platforms differently, see EM_ constants in elf.h for
|
||||
# assortment...
|
||||
$self->{e_machine} = $elf_ehdr{e_machine};
|
||||
|
||||
#################################################
|
||||
# read and parse elf_shdr table...
|
||||
#
|
||||
my ($i,$sz,$symtab_idx,$blob,$strings);
|
||||
|
||||
seek($FD,$elf_ehdr{e_shoff},0) or die "$!";
|
||||
read($FD,$blob,$elf_ehdr{e_shentsize}*$elf_ehdr{e_shnum}) or die "$!";
|
||||
|
||||
my @sections;
|
||||
my $elf_shdr_struct=($elf_bits==32?($big_endian?"N10":"V10"):"L2Q4L2Q2");
|
||||
for ($sz=$elf_ehdr{e_shentsize},$i=0;$i<length($blob);$i+=$sz) {
|
||||
my %elf_shdr;
|
||||
|
||||
@elf_shdr{sh_name,sh_type,sh_flags,
|
||||
sh_addr,sh_offset,sh_size,
|
||||
sh_link,sh_info,sh_addalign,sh_entsize} =
|
||||
unpack($elf_shdr_struct,substr($blob,$i,$sz));
|
||||
|
||||
push(@sections,dup(%elf_shdr));
|
||||
|
||||
# note SHT_SYMTAB or SHT_DYNSYM for future reference
|
||||
if ($elf_shdr{sh_type}==2 || $elf_shdr{sh_type}==11) {
|
||||
$symtab_idx = $#sections;
|
||||
}
|
||||
}
|
||||
|
||||
# read strings table and map section names...
|
||||
seek($FD,@sections[$elf_ehdr{e_shstrndx}]->{sh_offset},0) or die "$!";
|
||||
read($FD,$strings,@sections[$elf_ehdr{e_shstrndx}]->{sh_size}) or die "$!";
|
||||
for (@sections) {
|
||||
$_->{sh_name}=(split(chr(0),substr($strings,$_->{sh_name},64)))[0];
|
||||
}
|
||||
|
||||
#################################################
|
||||
# read symbol strings table...
|
||||
#
|
||||
$i=@sections[$symtab_idx]->{sh_link};
|
||||
seek($FD,@sections[$i]->{sh_offset},0) or die "$!";
|
||||
read($FD,$strings,@sections[$i]->{sh_size}) or die "$!";
|
||||
|
||||
#################################################
|
||||
# read and parse elf_sym table...
|
||||
#
|
||||
seek($FD,@sections[$symtab_idx]->{sh_offset},0) or die "$!";
|
||||
read($FD,my $blob,@sections[$symtab_idx]->{sh_size}) or die "$!";
|
||||
|
||||
for ($sz=@sections[$symtab_idx]->{sh_entsize},$i=0;$i<length($blob);$i+=$sz) {
|
||||
my %elf_sym;
|
||||
|
||||
if ($elf_bits==32) {
|
||||
@elf_sym{st_name,st_value,st_size,st_info,st_other,st_shndx} =
|
||||
unpack($big_endian?"N3CCn":"V3CCv",substr($blob,$i,$sz));
|
||||
} else {
|
||||
@elf_sym{st_name,st_info,st_other,st_shndx,st_value,st_size} =
|
||||
unpack("LCCSQQ",substr($blob,$i,$sz));
|
||||
}
|
||||
|
||||
my $st_type = $elf_sym{st_info}&0xf;
|
||||
my $st_bind = $elf_sym{st_info}>>4;
|
||||
my $st_secn = $elf_sym{st_shndx};
|
||||
my $name;
|
||||
# (STT_OBJECT || STT_FUNC)
|
||||
if ($st_bind<3 && ($st_type==1 || $st_type==2)
|
||||
&& $st_secn <= $#sections # sane st_shndx
|
||||
&& @sections[$st_secn]->{sh_type} # not SHN_UNDEF
|
||||
&& ($name=(split(chr(0),substr($strings,$elf_sym{st_name},128)))[0])
|
||||
) {
|
||||
# synthesize st_offset, ...
|
||||
$elf_sym{st_offset} = $elf_sym{st_value}
|
||||
- @sections[$st_secn]->{sh_addr}
|
||||
+ @sections[$st_secn]->{sh_offset};
|
||||
$elf_sym{st_name} = $name;
|
||||
$elf_sym{st_section} = @sections[$st_secn]->{sh_name};
|
||||
# ... and add to lookup table
|
||||
$self->{symbols}{$name} = dup(%elf_sym);
|
||||
}
|
||||
}
|
||||
|
||||
return $self;
|
||||
}
|
||||
|
||||
sub Lookup {
|
||||
my $self = shift;
|
||||
my $name = shift;
|
||||
return $self->{symbols}{$name};
|
||||
}
|
||||
|
||||
sub Traverse {
|
||||
my $self = shift;
|
||||
my $code = shift;
|
||||
|
||||
if (ref($code) eq 'CODE') {
|
||||
for (keys(%{$self->{symbols}})) { &$code($self->{symbols}{$_}); }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
######################################################################
|
||||
#
|
||||
# SHA1 and HMAC in Perl by <appro@openssl.org>.
|
||||
#
|
||||
{ package SHA1;
|
||||
use integer;
|
||||
|
||||
{
|
||||
################################### SHA1 block code generator
|
||||
my @V = ('$A','$B','$C','$D','$E');
|
||||
my $i;
|
||||
|
||||
sub XUpdate {
|
||||
my $ret;
|
||||
$ret="(\$T=\$W[($i-16)%16]^\$W[($i-14)%16]^\$W[($i-8)%16]^\$W[($i-3)%16],\n\t";
|
||||
if ((1<<31)<<1) {
|
||||
$ret.=" \$W[$i%16]=((\$T<<1)|(\$T>>31))&0xffffffff)\n\t ";
|
||||
} else {
|
||||
$ret.=" \$W[$i%16]=(\$T<<1)|((\$T>>31)&1))\n\t ";
|
||||
}
|
||||
}
|
||||
sub tail {
|
||||
my ($a,$b,$c,$d,$e)=@V;
|
||||
my $ret;
|
||||
if ((1<<31)<<1) {
|
||||
$ret.="(($a<<5)|($a>>27));\n\t";
|
||||
$ret.="$b=($b<<30)|($b>>2); $e&=0xffffffff; #$b&=0xffffffff;\n\t";
|
||||
} else {
|
||||
$ret.="(($a<<5)|($a>>27)&0x1f);\n\t";
|
||||
$ret.="$b=($b<<30)|($b>>2)&0x3fffffff;\n\t";
|
||||
}
|
||||
$ret;
|
||||
}
|
||||
sub BODY_00_15 {
|
||||
my ($a,$b,$c,$d,$e)=@V;
|
||||
"$e+=\$W[$i]+0x5a827999+((($c^$d)&$b)^$d)+".tail();
|
||||
}
|
||||
sub BODY_16_19 {
|
||||
my ($a,$b,$c,$d,$e)=@V;
|
||||
"$e+=".XUpdate()."+0x5a827999+((($c^$d)&$b)^$d)+".tail();
|
||||
}
|
||||
sub BODY_20_39 {
|
||||
my ($a,$b,$c,$d,$e)=@V;
|
||||
"$e+=".XUpdate()."+0x6ed9eba1+($b^$c^$d)+".tail();
|
||||
}
|
||||
sub BODY_40_59 {
|
||||
my ($a,$b,$c,$d,$e)=@V;
|
||||
"$e+=".XUpdate()."+0x8f1bbcdc+(($b&$c)|(($b|$c)&$d))+".tail();
|
||||
}
|
||||
sub BODY_60_79 {
|
||||
my ($a,$b,$c,$d,$e)=@V;
|
||||
"$e+=".XUpdate()."+0xca62c1d6+($b^$c^$d)+".tail();
|
||||
}
|
||||
|
||||
my $sha1_impl =
|
||||
'sub block {
|
||||
my $self = @_[0];
|
||||
my @W = unpack("N16",@_[1]);
|
||||
my ($A,$B,$C,$D,$E,$T) = @{$self->{H}};
|
||||
';
|
||||
|
||||
$sha1_impl.='
|
||||
$A &= 0xffffffff;
|
||||
$B &= 0xffffffff;
|
||||
' if ((1<<31)<<1);
|
||||
|
||||
for($i=0;$i<16;$i++){ $sha1_impl.=BODY_00_15(); unshift(@V,pop(@V)); }
|
||||
for(;$i<20;$i++) { $sha1_impl.=BODY_16_19(); unshift(@V,pop(@V)); }
|
||||
for(;$i<40;$i++) { $sha1_impl.=BODY_20_39(); unshift(@V,pop(@V)); }
|
||||
for(;$i<60;$i++) { $sha1_impl.=BODY_40_59(); unshift(@V,pop(@V)); }
|
||||
for(;$i<80;$i++) { $sha1_impl.=BODY_60_79(); unshift(@V,pop(@V)); }
|
||||
|
||||
$sha1_impl.='
|
||||
$self->{H}[0]+=$A; $self->{H}[1]+=$B; $self->{H}[2]+=$C;
|
||||
$self->{H}[3]+=$D; $self->{H}[4]+=$E; }';
|
||||
|
||||
#print $sha1_impl,"\n";
|
||||
eval($sha1_impl); # generate code
|
||||
}
|
||||
|
||||
sub Init {
|
||||
my $class = shift; # multiple instances...
|
||||
my $self = {};
|
||||
|
||||
bless $self,$class;
|
||||
$self->{H} = [0x67452301,0xefcdab89,0x98badcfe,0x10325476,0xc3d2e1f0];
|
||||
$self->{N} = 0;
|
||||
return $self;
|
||||
}
|
||||
|
||||
sub Update {
|
||||
my $self = shift;
|
||||
my $msg;
|
||||
|
||||
foreach $msg (@_) {
|
||||
my $len = length($msg);
|
||||
my $num = length($self->{buf});
|
||||
my $off = 0;
|
||||
|
||||
$self->{N} += $len;
|
||||
|
||||
if (($num+$len)<64)
|
||||
{ $self->{buf} .= $msg; next; }
|
||||
elsif ($num)
|
||||
{ $self->{buf} .= substr($msg,0,($off=64-$num));
|
||||
$self->block($self->{buf});
|
||||
}
|
||||
|
||||
while(($off+64) <= $len)
|
||||
{ $self->block(substr($msg,$off,64));
|
||||
$off += 64;
|
||||
}
|
||||
|
||||
$self->{buf} = substr($msg,$off);
|
||||
}
|
||||
return $self;
|
||||
}
|
||||
|
||||
sub Final {
|
||||
my $self = shift;
|
||||
my $num = length($self->{buf});
|
||||
|
||||
$self->{buf} .= chr(0x80); $num++;
|
||||
if ($num>56)
|
||||
{ $self->{buf} .= chr(0)x(64-$num);
|
||||
$self->block($self->{buf});
|
||||
$self->{buf}=undef;
|
||||
$num=0;
|
||||
}
|
||||
$self->{buf} .= chr(0)x(56-$num);
|
||||
$self->{buf} .= pack("N2",($self->{N}>>29)&0x7,$self->{N}<<3);
|
||||
$self->block($self->{buf});
|
||||
|
||||
return pack("N*",@{$self->{H}});
|
||||
}
|
||||
|
||||
sub Selftest {
|
||||
my $hash;
|
||||
|
||||
$hash=SHA1->Init()->Update('abc')->Final();
|
||||
die "SHA1 test#1" if (unpack("H*",$hash) ne 'a9993e364706816aba3e25717850c26c9cd0d89d');
|
||||
|
||||
$hash=SHA1->Init()->Update('abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq')->Final();
|
||||
die "SHA1 test#2" if (unpack("H*",$hash) ne '84983e441c3bd26ebaae4aa1f95129e5e54670f1');
|
||||
|
||||
#$hash=SHA1->Init()->Update('a'x1000000)->Final();
|
||||
#die "SHA1 test#3" if (unpack("H*",$hash) ne '34aa973cd4c4daa4f61eeb2bdbad27316534016f');
|
||||
}
|
||||
}
|
||||
|
||||
{ package HMAC;
|
||||
|
||||
sub Init {
|
||||
my $class = shift;
|
||||
my $key = shift;
|
||||
my $self = {};
|
||||
|
||||
bless $self,$class;
|
||||
|
||||
if (length($key)>64) {
|
||||
$key = SHA1->Init()->Update($key)->Final();
|
||||
}
|
||||
$key .= chr(0x00)x(64-length($key));
|
||||
|
||||
my @ikey = map($_^=0x36,unpack("C*",$key));
|
||||
($self->{hash} = SHA1->Init())->Update(pack("C*",@ikey));
|
||||
$self->{okey} = pack("C*",map($_^=0x36^0x5c,@ikey));
|
||||
|
||||
return $self;
|
||||
}
|
||||
|
||||
sub Update {
|
||||
my $self = shift;
|
||||
$self->{hash}->Update(@_);
|
||||
return $self;
|
||||
}
|
||||
|
||||
sub Final {
|
||||
my $self = shift;
|
||||
my $ihash = $self->{hash}->Final();
|
||||
return SHA1->Init()->Update($self->{okey},$ihash)->Final();
|
||||
}
|
||||
|
||||
sub Selftest {
|
||||
my $hmac;
|
||||
|
||||
$hmac = HMAC->Init('0123456789:;<=>?@ABC')->Update('Sample #2')->Final();
|
||||
die "HMAC test" if (unpack("H*",$hmac) ne '0922d3405faa3d194f82a45830737d5cc6c75d24');
|
||||
}
|
||||
}
|
||||
|
||||
######################################################################
|
||||
#
|
||||
# main()
|
||||
#
|
||||
my $legacy_mode;
|
||||
|
||||
if ($ARGV<0 || ($#ARGV>0 && !($legacy_mode=(@ARGV[0] =~ /^\-(dso|exe)$/)))) {
|
||||
print STDERR "usage: $0 [-dso|-exe] elfbinary\n";
|
||||
exit(1);
|
||||
}
|
||||
|
||||
$exe = ELF->Load(@ARGV[$#ARGV]);
|
||||
|
||||
$FIPS_text_start = $exe->Lookup("FIPS_text_start") or die;
|
||||
$FIPS_text_end = $exe->Lookup("FIPS_text_end") or die;
|
||||
$FIPS_rodata_start = $exe->Lookup("FIPS_rodata_start") or die;
|
||||
$FIPS_rodata_end = $exe->Lookup("FIPS_rodata_end") or die;
|
||||
$FIPS_signature = $exe->Lookup("FIPS_signature") or die;
|
||||
|
||||
# new cross-compile support
|
||||
$FIPS_text_startX = $exe->Lookup("FIPS_text_startX");
|
||||
$FIPS_text_endX = $exe->Lookup("FIPS_text_endX");
|
||||
|
||||
if (!$legacy_mode) {
|
||||
if (!$FIPS_text_startX || !$FIPS_text_endX) {
|
||||
print STDERR "@ARGV[$#ARGV] is not cross-compiler aware.\n";
|
||||
exit(42); # signal fipsld to revert to two-step link
|
||||
}
|
||||
|
||||
$FINGERPRINT_ascii_value
|
||||
= $exe->Lookup("FINGERPRINT_ascii_value");
|
||||
|
||||
}
|
||||
if ($FIPS_text_startX && $FIPS_text_endX) {
|
||||
$FIPS_text_start = $FIPS_text_startX;
|
||||
$FIPS_text_end = $FIPS_text_endX;
|
||||
}
|
||||
|
||||
sysopen(FD,@ARGV[$#ARGV],$legacy_mode?0:2) or die "$!"; # 2 is read/write
|
||||
binmode(FD);
|
||||
|
||||
sub HMAC_Update {
|
||||
my ($hmac,$off,$len) = @_;
|
||||
my $blob;
|
||||
|
||||
seek(FD,$off,0) or die "$!";
|
||||
read(FD,$blob,$len) or die "$!";
|
||||
$$hmac->Update($blob);
|
||||
}
|
||||
|
||||
# fips/fips.c:FIPS_incore_fingerprint's Perl twin
|
||||
#
|
||||
sub FIPS_incore_fingerprint {
|
||||
my $p1 = $FIPS_text_start->{st_offset};
|
||||
my $p2 = $FIPS_text_end->{st_offset};
|
||||
my $p3 = $FIPS_rodata_start->{st_offset};
|
||||
my $p4 = $FIPS_rodata_end->{st_offset};
|
||||
my $sig = $FIPS_signature->{st_offset};
|
||||
my $ctx = HMAC->Init("etaonrishdlcupfm");
|
||||
|
||||
# detect overlapping regions
|
||||
if ($p1<=$p3 && $p2>=$p3) {
|
||||
$p3 = $p1; $p4 = $p2>$p4?$p2:$p4; $p1 = 0; $p2 = 0;
|
||||
} elsif ($p3<=$p1 && $p4>=$p1) {
|
||||
$p3 = $p3; $p4 = $p2>$p4?$p2:$p4; $p1 = 0; $p2 = 0;
|
||||
}
|
||||
|
||||
if ($p1) {
|
||||
HMAC_Update (\$ctx,$p1,$p2-$p1);
|
||||
}
|
||||
|
||||
if ($sig>=$p3 && $sig<$p4) {
|
||||
# "punch" hole
|
||||
HMAC_Update(\$ctx,$p3,$sig-$p3);
|
||||
$p3 = $sig+20;
|
||||
HMAC_Update(\$ctx,$p3,$p4-$p3);
|
||||
} else {
|
||||
HMAC_Update(\$ctx,$p3,$p4-$p3);
|
||||
}
|
||||
|
||||
return $ctx->Final();
|
||||
}
|
||||
|
||||
$fingerprint = FIPS_incore_fingerprint();
|
||||
|
||||
if ($legacy_mode) {
|
||||
print unpack("H*",$fingerprint);
|
||||
} elsif (defined($FINGERPRINT_ascii_value)) {
|
||||
seek(FD,$FINGERPRINT_ascii_value->{st_offset},0) or die "$!";
|
||||
print FD unpack("H*",$fingerprint) or die "$!";
|
||||
} else {
|
||||
seek(FD,$FIPS_signature->{st_offset},0) or die "$!";
|
||||
print FD $fingerprint or die "$!";
|
||||
}
|
||||
|
||||
close (FD);
|
||||
+11
-45
@@ -48,8 +48,6 @@
|
||||
-T ASN1_BIT_STRING
|
||||
-T ASN1_BMPSTRING
|
||||
-T ASN1_BOOLEAN
|
||||
-T ASN1_COMPAT_FUNCS
|
||||
-T ASN1_CTX
|
||||
-T ASN1_ENCODING
|
||||
-T ASN1_ENUMERATED
|
||||
-T ASN1_EXTERN_FUNCS
|
||||
@@ -80,7 +78,6 @@
|
||||
-T ASN1_UTF8STRING
|
||||
-T ASN1_VALUE
|
||||
-T ASN1_VISIBLESTRING
|
||||
-T ASN1_const_CTX
|
||||
-T AUTHORITY_INFO_ACCESS
|
||||
-T AUTHORITY_KEYID
|
||||
-T BASIC_CONSTRAINTS
|
||||
@@ -167,14 +164,10 @@
|
||||
-T CONF_MODULE
|
||||
-T CONF_VALUE
|
||||
-T CRYPTO_EX_DATA
|
||||
-T CRYPTO_EX_DATA_FUNCS
|
||||
-T CRYPTO_EX_DATA_IMPL
|
||||
-T CRYPTO_EX_dup
|
||||
-T CRYPTO_EX_free
|
||||
-T CRYPTO_EX_new
|
||||
-T CRYPTO_MEM_LEAK_CB
|
||||
-T CRYPTO_THREADID
|
||||
-T CRYPTO_dynlock_value
|
||||
-T DB_ATTR
|
||||
-T DES_LONG
|
||||
-T DES_cblock
|
||||
@@ -184,7 +177,6 @@
|
||||
-T DH_PKEY_CTX
|
||||
-T DIST_POINT
|
||||
-T DIST_POINT_NAME
|
||||
-T DRBG_CTX
|
||||
-T DSA
|
||||
-T DSA_METHOD
|
||||
-T DSA_SIG
|
||||
@@ -198,14 +190,11 @@
|
||||
-T DTLS1_RECORD_DATA
|
||||
-T DTLS1_STATE
|
||||
-T Dl_info
|
||||
-T ECDH_DATA
|
||||
-T ECDH_METHOD
|
||||
-T ECDSA_DATA
|
||||
-T ECDSA_METHOD
|
||||
-T ECDSA_SIG
|
||||
-T ECPARAMETERS
|
||||
-T ECPKPARAMETERS
|
||||
-T EC_EXTRA_DATA
|
||||
-T EC_GROUP
|
||||
-T EC_KEY
|
||||
-T EC_METHOD
|
||||
@@ -234,8 +223,10 @@
|
||||
-T ERR_STATE
|
||||
-T ERR_STRING_DATA
|
||||
-T ESS_CERT_ID
|
||||
-T ESS_CERT_ID_V2
|
||||
-T ESS_ISSUER_SERIAL
|
||||
-T ESS_SIGNING_CERT
|
||||
-T ESS_SIGNING_CERT_V2
|
||||
-T EVP_AES_HMAC_SHA1
|
||||
-T EVP_AES_HMAC_SHA256
|
||||
-T EVP_CIPHER
|
||||
@@ -251,12 +242,7 @@
|
||||
-T EVP_PKEY_CTX
|
||||
-T EVP_PKEY_METHOD
|
||||
-T EVP_PKEY_gen_cb
|
||||
-T EX_CLASS_ITEM
|
||||
-T E_GMP_RSA_CTX
|
||||
-T E_RSAX_MOD_CTX
|
||||
-T FILE
|
||||
-T F_DIGITALSIGNATUREVERIFY
|
||||
-T F_PUBLICKEYEXTRACT
|
||||
-T GCM128_CONTEXT
|
||||
-T GENERAL_NAME
|
||||
-T GENERAL_NAMES
|
||||
@@ -265,7 +251,6 @@
|
||||
-T HASH_CTX
|
||||
-T HEAPENTRY32
|
||||
-T HEAPLIST32
|
||||
-T HEARTBEAT_TEST_FIXTURE
|
||||
-T HMAC_CTX
|
||||
-T IDEA_KEY_SCHEDULE
|
||||
-T IPAddrBlocks
|
||||
@@ -275,12 +260,8 @@
|
||||
-T ISSUING_DIST_POINT
|
||||
-T KEY_TABLE_TYPE
|
||||
-T LHASH
|
||||
-T LHASH_COMP_FN_TYPE
|
||||
-T LHASH_DOALL_ARG_FN_TYPE
|
||||
-T LHASH_DOALL_FN_TYPE
|
||||
-T LHASH_HASH_FN_TYPE
|
||||
-T LHASH_NODE
|
||||
-T LPDIR_CTX
|
||||
-T LPHEAPENTRY32
|
||||
-T LPHEAPLIST32
|
||||
-T LPMODULEENTRY32
|
||||
@@ -293,15 +274,12 @@
|
||||
-T MD4_CTX
|
||||
-T MD5_CTX
|
||||
-T MDC2_CTX
|
||||
-T MD_DATA
|
||||
-T MEM
|
||||
-T MEM_LEAK
|
||||
-T MEM_OBJECT_DATA
|
||||
-T MIME_HEADER
|
||||
-T MIME_PARAM
|
||||
-T MODULEENTRY32
|
||||
-T MODULEENTRY32W
|
||||
-T MS_FAR
|
||||
-T NAME_CONSTRAINTS
|
||||
-T NAME_FUNCS
|
||||
-T NBIO_TEST
|
||||
@@ -311,8 +289,6 @@
|
||||
-T NETSCAPE_PKEY
|
||||
-T NETSCAPE_SPKAC
|
||||
-T NETSCAPE_SPKI
|
||||
-T NETSCAPE_X509
|
||||
-T NET_API_FUNCTION
|
||||
-T NOTICEREF
|
||||
-T OBJ_NAME
|
||||
-T OCB128_CONTEXT
|
||||
@@ -337,7 +313,6 @@
|
||||
-T OPENSSL_BLOCK
|
||||
-T OPENSSL_CSTRING
|
||||
-T OPENSSL_DIR_CTX
|
||||
-T OPENSSL_ITEM
|
||||
-T OPENSSL_PSTRING
|
||||
-T OPENSSL_STRING
|
||||
-T OSSL_ASYNC_FD
|
||||
@@ -347,10 +322,6 @@
|
||||
-T PBE2PARAM
|
||||
-T PBEPARAM
|
||||
-T PBKDF2PARAM
|
||||
-T PCRYPTO_MEM_LEAK_CB
|
||||
-T PEM_CTX
|
||||
-T PEM_ENCODE_SEAL_CTX
|
||||
-T PEM_USER
|
||||
-T PHEAPENTRY32
|
||||
-T PHEAPLIST32
|
||||
-T PKCS12
|
||||
@@ -396,7 +367,6 @@
|
||||
-T RSA_PSS_PARAMS
|
||||
-T SCT
|
||||
-T SEED_KEY_SCHEDULE
|
||||
-T SESS_CERT
|
||||
-T SHA256_CTX
|
||||
-T SHA512_CTX
|
||||
-T SHA_CTX
|
||||
@@ -409,7 +379,6 @@
|
||||
-T SRP_user_pwd
|
||||
-T SRTP_PROTECTION_PROFILE
|
||||
-T SSL
|
||||
-T SSL2_STATE
|
||||
-T SSL3_BUFFER
|
||||
-T SSL3_COMP
|
||||
-T SSL3_ENC_METHOD
|
||||
@@ -450,7 +419,6 @@
|
||||
-T WCHAR
|
||||
-T WHIRLPOOL_CTX
|
||||
-T WINAPI
|
||||
-T WSAAPI
|
||||
-T X509
|
||||
-T X509V3_CONF_METHOD
|
||||
-T X509V3_CTX
|
||||
@@ -467,8 +435,6 @@
|
||||
-T X509_ALGOR
|
||||
-T X509_ATTRIBUTE
|
||||
-T X509_CERT_AUX
|
||||
-T X509_CERT_FILE_CTX
|
||||
-T X509_CERT_PAIR
|
||||
-T X509_CINF
|
||||
-T X509_CRL
|
||||
-T X509_CRL_INFO
|
||||
@@ -480,7 +446,6 @@
|
||||
-T X509_NAME
|
||||
-T X509_NAME_ENTRY
|
||||
-T X509_OBJECT
|
||||
-T X509_OBJECTS
|
||||
-T X509_PKEY
|
||||
-T X509_POLICY_CACHE
|
||||
-T X509_POLICY_DATA
|
||||
@@ -498,17 +463,14 @@
|
||||
-T X509_TRUST
|
||||
-T X509_VAL
|
||||
-T X509_VERIFY_PARAM
|
||||
-T X509_VERIFY_PARAM_ID
|
||||
-T X9_62_CHARACTERISTIC_TWO
|
||||
-T X9_62_CURVE
|
||||
-T X9_62_FIELDID
|
||||
-T X9_62_PENTANOMIAL
|
||||
-T XTS128_CONTEXT
|
||||
-T ZEN_MD_DATA
|
||||
-T _LHASH
|
||||
-T _STACK
|
||||
-T __int64
|
||||
-T _ossl_old_des_cblock
|
||||
-T asn1_ps_func
|
||||
-T bio_dgram_data
|
||||
-T bio_info_cb
|
||||
@@ -561,12 +523,12 @@
|
||||
-T STACK_OF_CONF_IMODULE_
|
||||
-T STACK_OF_CONF_MODULE_
|
||||
-T STACK_OF_CONF_VALUE_
|
||||
-T STACK_OF_CRYPTO_EX_DATA_FUNCS_
|
||||
-T STACK_OF_CRYPTO_dynlock_
|
||||
-T STACK_OF_DIST_POINT_
|
||||
-T STACK_OF_ENGINE_
|
||||
-T STACK_OF_ENGINE_CLEANUP_ITEM_
|
||||
-T STACK_OF_ESS_CERT_ID_
|
||||
-T STACK_OF_ESS_CERT_ID_V2_
|
||||
-T STACK_OF_EVP_PBE_CTL_
|
||||
-T STACK_OF_EVP_PKEY_ASN1_METHOD_
|
||||
-T STACK_OF_EVP_PKEY_METHOD_
|
||||
@@ -575,7 +537,6 @@
|
||||
-T STACK_OF_GENERAL_SUBTREE_
|
||||
-T STACK_OF_IPAddressFamily_
|
||||
-T STACK_OF_IPAddressOrRange_
|
||||
-T STACK_OF_MEM_OBJECT_DATA_
|
||||
-T STACK_OF_MIME_HEADER_
|
||||
-T STACK_OF_MIME_PARAM_
|
||||
-T STACK_OF_NAME_FUNCS_
|
||||
@@ -630,7 +591,6 @@
|
||||
-T LHASH_OF_ENGINE_PILE_
|
||||
-T LHASH_OF_ERR_STATE_
|
||||
-T LHASH_OF_ERR_STRING_DATA_
|
||||
-T LHASH_OF_EX_CLASS_ITEM_
|
||||
-T LHASH_OF_FUNCTION_
|
||||
-T LHASH_OF_MEM_
|
||||
-T LHASH_OF_OBJ_NAME_
|
||||
@@ -646,7 +606,6 @@
|
||||
-T ssl_st
|
||||
-T ssl_trace_tbl
|
||||
-T _stdcall
|
||||
-T tls12_lookup
|
||||
-T OPTIONS
|
||||
-T OPT_PAIR
|
||||
-T uint64_t
|
||||
@@ -663,10 +622,17 @@
|
||||
-T SH_LIST
|
||||
-T PACKET
|
||||
-T RECORD_LAYER
|
||||
-T ASYNC_FIBRE
|
||||
-T ASYNC_CTX
|
||||
-T ASYNC_JOB
|
||||
-T intmax_t
|
||||
-T uintmax_t
|
||||
-T pqueue
|
||||
-T danetls_record
|
||||
-T CTLOG_STORE
|
||||
-T OPENSSL_INIT_SETTINGS
|
||||
-T OSSL_HANDSHAKE_STATE
|
||||
-T OSSL_STATEM
|
||||
-T ossl_intmax_t
|
||||
-T ossl_intmax_t
|
||||
-T ossl_uintmax_t
|
||||
-T ossl_uintmax_t
|
||||
+348
-61
@@ -30,7 +30,7 @@ GENERAL_NAME_get0_otherName 29 1_1_0 EXIST::FUNCTION:
|
||||
ASN1_INTEGER_get_uint64 30 1_1_0 EXIST::FUNCTION:
|
||||
EVP_DigestInit_ex 31 1_1_0 EXIST::FUNCTION:
|
||||
CTLOG_new 32 1_1_0 EXIST::FUNCTION:CT
|
||||
UI_get_result_minsize 33 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_get_result_minsize 33 1_1_0 EXIST::FUNCTION:
|
||||
EVP_PBE_alg_add_type 34 1_1_0 EXIST::FUNCTION:
|
||||
EVP_cast5_ofb 35 1_1_0 EXIST::FUNCTION:CAST
|
||||
d2i_PUBKEY_fp 36 1_1_0 EXIST::FUNCTION:STDIO
|
||||
@@ -39,7 +39,7 @@ BF_decrypt 38 1_1_0 EXIST::FUNCTION:BF
|
||||
PEM_read_bio_PUBKEY 39 1_1_0 EXIST::FUNCTION:
|
||||
X509_NAME_delete_entry 40 1_1_0 EXIST::FUNCTION:
|
||||
EVP_PKEY_meth_set_verify_recover 41 1_1_0 EXIST::FUNCTION:
|
||||
UI_set_method 42 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_set_method 42 1_1_0 EXIST::FUNCTION:
|
||||
PKCS7_ISSUER_AND_SERIAL_it 43 1_1_0 EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:
|
||||
PKCS7_ISSUER_AND_SERIAL_it 43 1_1_0 EXIST:EXPORT_VAR_AS_FUNCTION:FUNCTION:
|
||||
EC_GROUP_method_of 44 1_1_0 EXIST::FUNCTION:EC
|
||||
@@ -77,7 +77,7 @@ ASN1_item_print 76 1_1_0 EXIST::FUNCTION:
|
||||
CONF_set_nconf 77 1_1_0 EXIST::FUNCTION:
|
||||
RAND_set_rand_method 78 1_1_0 EXIST::FUNCTION:
|
||||
BN_GF2m_mod_mul 79 1_1_0 EXIST::FUNCTION:EC2M
|
||||
UI_add_input_boolean 80 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_add_input_boolean 80 1_1_0 EXIST::FUNCTION:
|
||||
ASN1_TIME_adj 81 1_1_0 EXIST::FUNCTION:
|
||||
EVP_PKEY_asn1_get0_info 82 1_1_0 EXIST::FUNCTION:
|
||||
BN_add_word 83 1_1_0 EXIST::FUNCTION:
|
||||
@@ -85,7 +85,7 @@ EVP_des_ede 84 1_1_0 EXIST::FUNCTION:DES
|
||||
EVP_PKEY_add1_attr_by_OBJ 85 1_1_0 EXIST::FUNCTION:
|
||||
ASYNC_WAIT_CTX_get_all_fds 86 1_1_0 EXIST::FUNCTION:
|
||||
EVP_CIPHER_meth_set_do_cipher 87 1_1_0 EXIST::FUNCTION:
|
||||
EVP_set_pw_prompt 88 1_1_0 EXIST::FUNCTION:UI
|
||||
EVP_set_pw_prompt 88 1_1_0 EXIST::FUNCTION:
|
||||
d2i_OCSP_RESPBYTES 89 1_1_0 EXIST::FUNCTION:OCSP
|
||||
TS_REQ_get_ext_by_NID 90 1_1_0 EXIST::FUNCTION:TS
|
||||
ASN1_item_ndef_i2d 91 1_1_0 EXIST::FUNCTION:
|
||||
@@ -206,7 +206,7 @@ SCT_set_version 206 1_1_0 EXIST::FUNCTION:CT
|
||||
CMS_add1_ReceiptRequest 207 1_1_0 EXIST::FUNCTION:CMS
|
||||
d2i_CRL_DIST_POINTS 208 1_1_0 EXIST::FUNCTION:
|
||||
X509_CRL_INFO_free 209 1_1_0 EXIST::FUNCTION:
|
||||
ERR_load_UI_strings 210 1_1_0 EXIST::FUNCTION:UI
|
||||
ERR_load_UI_strings 210 1_1_0 EXIST::FUNCTION:
|
||||
ERR_load_strings 211 1_1_0 EXIST::FUNCTION:
|
||||
RSA_X931_hash_id 212 1_1_0 EXIST::FUNCTION:RSA
|
||||
EC_KEY_set_method 213 1_1_0 EXIST::FUNCTION:EC
|
||||
@@ -272,7 +272,7 @@ EVP_OpenInit 272 1_1_0 EXIST::FUNCTION:RSA
|
||||
OCSP_response_get1_basic 273 1_1_0 EXIST::FUNCTION:OCSP
|
||||
CRYPTO_gcm128_tag 274 1_1_0 EXIST::FUNCTION:
|
||||
OCSP_parse_url 275 1_1_0 EXIST::FUNCTION:OCSP
|
||||
UI_get0_test_string 276 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_get0_test_string 276 1_1_0 EXIST::FUNCTION:
|
||||
CRYPTO_secure_free 277 1_1_0 EXIST::FUNCTION:
|
||||
DSA_print_fp 278 1_1_0 EXIST::FUNCTION:DSA,STDIO
|
||||
X509_get_ext_d2i 279 1_1_0 EXIST::FUNCTION:
|
||||
@@ -314,7 +314,7 @@ EVP_CIPHER_CTX_set_flags 314 1_1_0 EXIST::FUNCTION:
|
||||
err_free_strings_int 315 1_1_0 EXIST::FUNCTION:
|
||||
PEM_write_bio_PKCS7_stream 316 1_1_0 EXIST::FUNCTION:
|
||||
d2i_X509_CERT_AUX 317 1_1_0 EXIST::FUNCTION:
|
||||
UI_process 318 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_process 318 1_1_0 EXIST::FUNCTION:
|
||||
X509_get_subject_name 319 1_1_0 EXIST::FUNCTION:
|
||||
DH_get_1024_160 320 1_1_0 EXIST::FUNCTION:DH
|
||||
i2d_ASN1_UNIVERSALSTRING 321 1_1_0 EXIST::FUNCTION:
|
||||
@@ -331,7 +331,7 @@ CRYPTO_ccm128_tag 331 1_1_0 EXIST::FUNCTION:
|
||||
BIO_new_dgram_sctp 332 1_1_0 EXIST::FUNCTION:DGRAM,SCTP
|
||||
d2i_RSAPrivateKey_fp 333 1_1_0 EXIST::FUNCTION:RSA,STDIO
|
||||
s2i_ASN1_IA5STRING 334 1_1_0 EXIST::FUNCTION:
|
||||
UI_get_ex_data 335 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_get_ex_data 335 1_1_0 EXIST::FUNCTION:
|
||||
EVP_EncryptUpdate 336 1_1_0 EXIST::FUNCTION:
|
||||
SRP_create_verifier 337 1_1_0 EXIST::FUNCTION:SRP
|
||||
TS_TST_INFO_print_bio 338 1_1_0 EXIST::FUNCTION:TS
|
||||
@@ -372,7 +372,7 @@ SEED_ecb_encrypt 370 1_1_0 EXIST::FUNCTION:SEED
|
||||
X509_PUBKEY_get0_param 371 1_1_0 EXIST::FUNCTION:
|
||||
ASN1_i2d_fp 372 1_1_0 EXIST::FUNCTION:STDIO
|
||||
BIO_new_mem_buf 373 1_1_0 EXIST::FUNCTION:
|
||||
UI_get_input_flags 374 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_get_input_flags 374 1_1_0 EXIST::FUNCTION:
|
||||
X509V3_EXT_REQ_add_nconf 375 1_1_0 EXIST::FUNCTION:
|
||||
X509v3_asid_subset 376 1_1_0 EXIST::FUNCTION:RFC3779
|
||||
RSA_check_key_ex 377 1_1_0 EXIST::FUNCTION:RSA
|
||||
@@ -492,7 +492,7 @@ BN_GF2m_mod_sqr_arr 492 1_1_0 EXIST::FUNCTION:EC2M
|
||||
ASN1_PRINTABLESTRING_it 493 1_1_0 EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:
|
||||
ASN1_PRINTABLESTRING_it 493 1_1_0 EXIST:EXPORT_VAR_AS_FUNCTION:FUNCTION:
|
||||
BIO_f_cipher 494 1_1_0 EXIST::FUNCTION:
|
||||
UI_destroy_method 495 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_destroy_method 495 1_1_0 EXIST::FUNCTION:
|
||||
BN_get_rfc3526_prime_3072 496 1_1_0 EXIST::FUNCTION:
|
||||
X509_INFO_new 497 1_1_0 EXIST::FUNCTION:
|
||||
OCSP_RESPDATA_it 498 1_1_0 EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:OCSP
|
||||
@@ -621,12 +621,12 @@ DES_ede3_ofb64_encrypt 620 1_1_0 EXIST::FUNCTION:DES
|
||||
EC_KEY_METHOD_get_compute_key 621 1_1_0 EXIST::FUNCTION:EC
|
||||
RC2_cfb64_encrypt 622 1_1_0 EXIST::FUNCTION:RC2
|
||||
EVP_EncryptFinal_ex 623 1_1_0 EXIST::FUNCTION:
|
||||
ERR_load_RSA_strings 624 1_1_0 EXIST::FUNCTION:RSA
|
||||
ERR_load_RSA_strings 624 1_1_0 EXIST::FUNCTION:
|
||||
CRYPTO_secure_malloc_done 625 1_1_0 EXIST::FUNCTION:
|
||||
RSA_OAEP_PARAMS_new 626 1_1_0 EXIST::FUNCTION:RSA
|
||||
X509_NAME_free 627 1_1_0 EXIST::FUNCTION:
|
||||
PKCS12_set_mac 628 1_1_0 EXIST::FUNCTION:
|
||||
UI_get0_result_string 629 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_get0_result_string 629 1_1_0 EXIST::FUNCTION:
|
||||
TS_RESP_CTX_add_policy 630 1_1_0 EXIST::FUNCTION:TS
|
||||
X509_REQ_dup 631 1_1_0 EXIST::FUNCTION:
|
||||
d2i_DSA_PUBKEY_fp 633 1_1_0 EXIST::FUNCTION:DSA,STDIO
|
||||
@@ -640,9 +640,9 @@ CRYPTO_THREAD_write_lock 639 1_1_0 EXIST::FUNCTION:
|
||||
X509V3_NAME_from_section 640 1_1_0 EXIST::FUNCTION:
|
||||
EC_POINT_set_compressed_coordinates_GFp 641 1_1_0 EXIST::FUNCTION:EC
|
||||
OCSP_SINGLERESP_get0_id 642 1_1_0 EXIST::FUNCTION:OCSP
|
||||
UI_add_info_string 643 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_add_info_string 643 1_1_0 EXIST::FUNCTION:
|
||||
OBJ_NAME_remove 644 1_1_0 EXIST::FUNCTION:
|
||||
UI_get_method 645 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_get_method 645 1_1_0 EXIST::FUNCTION:
|
||||
CONF_modules_unload 646 1_1_0 EXIST::FUNCTION:
|
||||
CRYPTO_ccm128_encrypt_ccm64 647 1_1_0 EXIST::FUNCTION:
|
||||
CRYPTO_secure_malloc_init 648 1_1_0 EXIST::FUNCTION:
|
||||
@@ -717,7 +717,7 @@ PKCS7_add_signature 716 1_1_0 EXIST::FUNCTION:
|
||||
OBJ_ln2nid 717 1_1_0 EXIST::FUNCTION:
|
||||
CRYPTO_128_unwrap 718 1_1_0 EXIST::FUNCTION:
|
||||
BIO_new_PKCS7 719 1_1_0 EXIST::FUNCTION:
|
||||
UI_get0_user_data 720 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_get0_user_data 720 1_1_0 EXIST::FUNCTION:
|
||||
TS_RESP_get_token 721 1_1_0 EXIST::FUNCTION:TS
|
||||
OCSP_RESPID_new 722 1_1_0 EXIST::FUNCTION:OCSP
|
||||
ASN1_SET_ANY_it 723 1_1_0 EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:
|
||||
@@ -760,7 +760,7 @@ X509_policy_node_get0_qualifiers 758 1_1_0 EXIST::FUNCTION:
|
||||
OCSP_cert_status_str 759 1_1_0 EXIST::FUNCTION:OCSP
|
||||
EVP_MD_meth_get_flags 760 1_1_0 EXIST::FUNCTION:
|
||||
ASN1_ENUMERATED_set 761 1_1_0 EXIST::FUNCTION:
|
||||
UI_UTIL_read_pw 762 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_UTIL_read_pw 762 1_1_0 EXIST::FUNCTION:
|
||||
PKCS7_ENC_CONTENT_free 763 1_1_0 EXIST::FUNCTION:
|
||||
CMS_RecipientInfo_type 764 1_1_0 EXIST::FUNCTION:CMS
|
||||
OCSP_BASICRESP_get_ext 765 1_1_0 EXIST::FUNCTION:OCSP
|
||||
@@ -772,7 +772,7 @@ ENGINE_init 770 1_1_0 EXIST::FUNCTION:ENGINE
|
||||
TS_RESP_CTX_add_flags 771 1_1_0 EXIST::FUNCTION:TS
|
||||
BIO_gethostbyname 772 1_1_0 EXIST::FUNCTION:DEPRECATEDIN_1_1_0,SOCK
|
||||
X509V3_EXT_add 773 1_1_0 EXIST::FUNCTION:
|
||||
UI_add_verify_string 774 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_add_verify_string 774 1_1_0 EXIST::FUNCTION:
|
||||
EVP_rc5_32_12_16_cfb64 775 1_1_0 EXIST::FUNCTION:RC5
|
||||
PKCS7_dataVerify 776 1_1_0 EXIST::FUNCTION:
|
||||
PKCS7_SIGNER_INFO_free 777 1_1_0 EXIST::FUNCTION:
|
||||
@@ -909,13 +909,13 @@ PKCS5_pbe2_set_iv 905 1_1_0 EXIST::FUNCTION:
|
||||
ASN1_add_stable_module 906 1_1_0 EXIST::FUNCTION:
|
||||
EVP_camellia_128_cbc 907 1_1_0 EXIST::FUNCTION:CAMELLIA
|
||||
COMP_zlib 908 1_1_0 EXIST::FUNCTION:COMP
|
||||
EVP_read_pw_string 909 1_1_0 EXIST::FUNCTION:UI
|
||||
EVP_read_pw_string 909 1_1_0 EXIST::FUNCTION:
|
||||
i2d_ASN1_NULL 910 1_1_0 EXIST::FUNCTION:
|
||||
DES_encrypt1 911 1_1_0 EXIST::FUNCTION:DES
|
||||
BN_mod_lshift1_quick 912 1_1_0 EXIST::FUNCTION:
|
||||
BN_get_rfc3526_prime_6144 913 1_1_0 EXIST::FUNCTION:
|
||||
OBJ_obj2txt 914 1_1_0 EXIST::FUNCTION:
|
||||
UI_set_result 915 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_set_result 915 1_1_0 EXIST::FUNCTION:
|
||||
EVP_EncodeUpdate 916 1_1_0 EXIST::FUNCTION:
|
||||
PEM_write_bio_X509_CRL 917 1_1_0 EXIST::FUNCTION:
|
||||
BN_cmp 918 1_1_0 EXIST::FUNCTION:
|
||||
@@ -1020,11 +1020,11 @@ ASN1_UTCTIME_it 1013 1_1_0 EXIST:EXPORT_VAR_AS_FUNCTION:
|
||||
i2d_DSA_PUBKEY_fp 1014 1_1_0 EXIST::FUNCTION:DSA,STDIO
|
||||
X509at_get_attr_by_OBJ 1015 1_1_0 EXIST::FUNCTION:
|
||||
EVP_MD_CTX_copy_ex 1016 1_1_0 EXIST::FUNCTION:
|
||||
UI_dup_error_string 1017 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_dup_error_string 1017 1_1_0 EXIST::FUNCTION:
|
||||
OPENSSL_LH_num_items 1018 1_1_0 EXIST::FUNCTION:
|
||||
ASN1_INTEGER_cmp 1020 1_1_0 EXIST::FUNCTION:
|
||||
X509_NAME_entry_count 1021 1_1_0 EXIST::FUNCTION:
|
||||
UI_method_set_closer 1022 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_method_set_closer 1022 1_1_0 EXIST::FUNCTION:
|
||||
OPENSSL_LH_get_down_load 1023 1_1_0 EXIST::FUNCTION:
|
||||
EVP_md4 1024 1_1_0 EXIST::FUNCTION:MD4
|
||||
X509_set_subject_name 1025 1_1_0 EXIST::FUNCTION:
|
||||
@@ -1100,7 +1100,7 @@ X509_print_ex_fp 1093 1_1_0 EXIST::FUNCTION:STDIO
|
||||
ERR_load_PEM_strings 1094 1_1_0 EXIST::FUNCTION:
|
||||
ENGINE_unregister_pkey_asn1_meths 1095 1_1_0 EXIST::FUNCTION:ENGINE
|
||||
IPAddressFamily_free 1096 1_1_0 EXIST::FUNCTION:RFC3779
|
||||
UI_method_get_prompt_constructor 1097 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_method_get_prompt_constructor 1097 1_1_0 EXIST::FUNCTION:
|
||||
ASN1_NULL_it 1098 1_1_0 EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:
|
||||
ASN1_NULL_it 1098 1_1_0 EXIST:EXPORT_VAR_AS_FUNCTION:FUNCTION:
|
||||
X509_REQ_get_pubkey 1099 1_1_0 EXIST::FUNCTION:
|
||||
@@ -1262,7 +1262,7 @@ OPENSSL_DIR_read 1250 1_1_0 EXIST::FUNCTION:
|
||||
CMS_add_smimecap 1251 1_1_0 EXIST::FUNCTION:CMS
|
||||
X509_check_email 1252 1_1_0 EXIST::FUNCTION:
|
||||
CRYPTO_cts128_decrypt_block 1253 1_1_0 EXIST::FUNCTION:
|
||||
UI_method_get_opener 1254 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_method_get_opener 1254 1_1_0 EXIST::FUNCTION:
|
||||
EVP_aes_192_gcm 1255 1_1_0 EXIST::FUNCTION:
|
||||
TS_CONF_set_tsa_name 1256 1_1_0 EXIST::FUNCTION:TS
|
||||
X509_email_free 1257 1_1_0 EXIST::FUNCTION:
|
||||
@@ -1292,7 +1292,7 @@ ASN1_TIME_free 1281 1_1_0 EXIST::FUNCTION:
|
||||
i2o_SCT_LIST 1282 1_1_0 EXIST::FUNCTION:CT
|
||||
AES_encrypt 1283 1_1_0 EXIST::FUNCTION:
|
||||
MD5_Init 1284 1_1_0 EXIST::FUNCTION:MD5
|
||||
UI_add_error_string 1285 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_add_error_string 1285 1_1_0 EXIST::FUNCTION:
|
||||
X509_TRUST_cleanup 1286 1_1_0 EXIST::FUNCTION:
|
||||
PEM_read_X509 1287 1_1_0 EXIST::FUNCTION:STDIO
|
||||
EC_KEY_new_method 1288 1_1_0 EXIST::FUNCTION:EC
|
||||
@@ -1315,11 +1315,11 @@ BN_rshift1 1303 1_1_0 EXIST::FUNCTION:
|
||||
i2d_PKCS7_ENVELOPE 1304 1_1_0 EXIST::FUNCTION:
|
||||
PBKDF2PARAM_it 1305 1_1_0 EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:
|
||||
PBKDF2PARAM_it 1305 1_1_0 EXIST:EXPORT_VAR_AS_FUNCTION:FUNCTION:
|
||||
UI_get_result_maxsize 1306 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_get_result_maxsize 1306 1_1_0 EXIST::FUNCTION:
|
||||
PBEPARAM_it 1307 1_1_0 EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:
|
||||
PBEPARAM_it 1307 1_1_0 EXIST:EXPORT_VAR_AS_FUNCTION:FUNCTION:
|
||||
TS_ACCURACY_set_seconds 1308 1_1_0 EXIST::FUNCTION:TS
|
||||
UI_get0_action_string 1309 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_get0_action_string 1309 1_1_0 EXIST::FUNCTION:
|
||||
RC2_decrypt 1310 1_1_0 EXIST::FUNCTION:RC2
|
||||
OPENSSL_atexit 1311 1_1_0 EXIST::FUNCTION:
|
||||
CMS_add_standard_smimecap 1312 1_1_0 EXIST::FUNCTION:CMS
|
||||
@@ -1391,7 +1391,7 @@ PROXY_CERT_INFO_EXTENSION_it 1377 1_1_0 EXIST:EXPORT_VAR_AS_FUNCTION:
|
||||
CT_POLICY_EVAL_CTX_set1_cert 1378 1_1_0 EXIST::FUNCTION:CT
|
||||
X509_NAME_hash 1379 1_1_0 EXIST::FUNCTION:
|
||||
SCT_set_timestamp 1380 1_1_0 EXIST::FUNCTION:CT
|
||||
UI_new 1381 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_new 1381 1_1_0 EXIST::FUNCTION:
|
||||
TS_REQ_get_msg_imprint 1382 1_1_0 EXIST::FUNCTION:TS
|
||||
i2d_PKCS12_BAGS 1383 1_1_0 EXIST::FUNCTION:
|
||||
CERTIFICATEPOLICIES_free 1385 1_1_0 EXIST::FUNCTION:
|
||||
@@ -1410,7 +1410,7 @@ PEM_read_bio_PrivateKey 1398 1_1_0 EXIST::FUNCTION:
|
||||
d2i_PKCS7_ENCRYPT 1399 1_1_0 EXIST::FUNCTION:
|
||||
EVP_PKEY_CTX_ctrl 1400 1_1_0 EXIST::FUNCTION:
|
||||
X509_REQ_set_pubkey 1401 1_1_0 EXIST::FUNCTION:
|
||||
UI_create_method 1402 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_create_method 1402 1_1_0 EXIST::FUNCTION:
|
||||
X509_REQ_add_extensions_nid 1403 1_1_0 EXIST::FUNCTION:
|
||||
PEM_X509_INFO_write_bio 1404 1_1_0 EXIST::FUNCTION:
|
||||
BIO_dump_cb 1405 1_1_0 EXIST::FUNCTION:
|
||||
@@ -1478,7 +1478,7 @@ BN_gcd 1465 1_1_0 EXIST::FUNCTION:
|
||||
CMS_dataInit 1466 1_1_0 EXIST::FUNCTION:CMS
|
||||
TS_CONF_get_tsa_section 1467 1_1_0 EXIST::FUNCTION:TS
|
||||
i2d_PKCS7_SIGNER_INFO 1468 1_1_0 EXIST::FUNCTION:
|
||||
EVP_get_pw_prompt 1469 1_1_0 EXIST::FUNCTION:UI
|
||||
EVP_get_pw_prompt 1469 1_1_0 EXIST::FUNCTION:
|
||||
BN_bn2bin 1470 1_1_0 EXIST::FUNCTION:
|
||||
d2i_ASN1_BIT_STRING 1471 1_1_0 EXIST::FUNCTION:
|
||||
OCSP_CERTSTATUS_new 1472 1_1_0 EXIST::FUNCTION:OCSP
|
||||
@@ -1491,7 +1491,7 @@ SHA384_Final 1478 1_1_0 EXIST::FUNCTION:
|
||||
TS_RESP_CTX_set_certs 1479 1_1_0 EXIST::FUNCTION:TS
|
||||
BN_MONT_CTX_free 1480 1_1_0 EXIST::FUNCTION:
|
||||
BN_GF2m_mod_solve_quad_arr 1481 1_1_0 EXIST::FUNCTION:EC2M
|
||||
UI_add_input_string 1482 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_add_input_string 1482 1_1_0 EXIST::FUNCTION:
|
||||
TS_TST_INFO_get_version 1483 1_1_0 EXIST::FUNCTION:TS
|
||||
BIO_accept_ex 1484 1_1_0 EXIST::FUNCTION:SOCK
|
||||
CRYPTO_get_mem_functions 1485 1_1_0 EXIST::FUNCTION:
|
||||
@@ -1600,7 +1600,7 @@ SRP_Verify_A_mod_N 1587 1_1_0 EXIST::FUNCTION:SRP
|
||||
SRP_VBASE_free 1588 1_1_0 EXIST::FUNCTION:SRP
|
||||
PKCS7_add0_attrib_signing_time 1589 1_1_0 EXIST::FUNCTION:
|
||||
X509_STORE_set_flags 1590 1_1_0 EXIST::FUNCTION:
|
||||
UI_get0_output_string 1591 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_get0_output_string 1591 1_1_0 EXIST::FUNCTION:
|
||||
ERR_get_error_line_data 1592 1_1_0 EXIST::FUNCTION:
|
||||
CTLOG_get0_name 1593 1_1_0 EXIST::FUNCTION:CT
|
||||
ASN1_TBOOLEAN_it 1594 1_1_0 EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:
|
||||
@@ -1699,7 +1699,7 @@ CMS_EncryptedData_set1_key 1686 1_1_0 EXIST::FUNCTION:CMS
|
||||
OBJ_find_sigid_by_algs 1687 1_1_0 EXIST::FUNCTION:
|
||||
ASN1_generate_nconf 1688 1_1_0 EXIST::FUNCTION:
|
||||
CMS_add0_recipient_password 1689 1_1_0 EXIST::FUNCTION:CMS
|
||||
UI_get_string_type 1690 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_get_string_type 1690 1_1_0 EXIST::FUNCTION:
|
||||
PEM_read_bio_ECPrivateKey 1691 1_1_0 EXIST::FUNCTION:EC
|
||||
EVP_PKEY_get_attr 1692 1_1_0 EXIST::FUNCTION:
|
||||
PEM_read_bio_ECPKParameters 1693 1_1_0 EXIST::FUNCTION:EC
|
||||
@@ -1720,7 +1720,7 @@ X509_policy_tree_get0_level 1706 1_1_0 EXIST::FUNCTION:
|
||||
ASN1_parse_dump 1708 1_1_0 EXIST::FUNCTION:
|
||||
BIO_vfree 1709 1_1_0 EXIST::FUNCTION:
|
||||
CRYPTO_cbc128_decrypt 1710 1_1_0 EXIST::FUNCTION:
|
||||
UI_dup_verify_string 1711 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_dup_verify_string 1711 1_1_0 EXIST::FUNCTION:
|
||||
d2i_PKCS7_bio 1712 1_1_0 EXIST::FUNCTION:
|
||||
ENGINE_set_default_digests 1713 1_1_0 EXIST::FUNCTION:ENGINE
|
||||
i2d_PublicKey 1714 1_1_0 EXIST::FUNCTION:
|
||||
@@ -1738,7 +1738,7 @@ BIO_nwrite0 1725 1_1_0 EXIST::FUNCTION:
|
||||
CAST_encrypt 1726 1_1_0 EXIST::FUNCTION:CAST
|
||||
a2d_ASN1_OBJECT 1727 1_1_0 EXIST::FUNCTION:
|
||||
OCSP_ONEREQ_delete_ext 1728 1_1_0 EXIST::FUNCTION:OCSP
|
||||
UI_method_get_reader 1729 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_method_get_reader 1729 1_1_0 EXIST::FUNCTION:
|
||||
CMS_unsigned_get_attr 1730 1_1_0 EXIST::FUNCTION:CMS
|
||||
EVP_aes_256_cbc 1731 1_1_0 EXIST::FUNCTION:
|
||||
X509_check_ip_asc 1732 1_1_0 EXIST::FUNCTION:
|
||||
@@ -1768,8 +1768,8 @@ ASYNC_init_thread 1755 1_1_0 EXIST::FUNCTION:
|
||||
OCSP_BASICRESP_get_ext_by_OBJ 1756 1_1_0 EXIST::FUNCTION:OCSP
|
||||
X509_reject_clear 1757 1_1_0 EXIST::FUNCTION:
|
||||
DH_security_bits 1758 1_1_0 EXIST::FUNCTION:DH
|
||||
LONG_it 1759 1_1_0 EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:
|
||||
LONG_it 1759 1_1_0 EXIST:EXPORT_VAR_AS_FUNCTION:FUNCTION:
|
||||
LONG_it 1759 1_1_0 EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:DEPRECATEDIN_1_2_0
|
||||
LONG_it 1759 1_1_0 EXIST:EXPORT_VAR_AS_FUNCTION:FUNCTION:DEPRECATEDIN_1_2_0
|
||||
ASN1_dup 1760 1_1_0 EXIST::FUNCTION:
|
||||
TS_RESP_new 1761 1_1_0 EXIST::FUNCTION:TS
|
||||
i2d_PKCS8PrivateKeyInfo_fp 1762 1_1_0 EXIST::FUNCTION:STDIO
|
||||
@@ -1834,8 +1834,8 @@ X509V3_EXT_add_list 1821 1_1_0 EXIST::FUNCTION:
|
||||
CMS_compress 1822 1_1_0 EXIST::FUNCTION:CMS
|
||||
X509_get_ext_by_critical 1823 1_1_0 EXIST::FUNCTION:
|
||||
ASYNC_WAIT_CTX_clear_fd 1824 1_1_0 EXIST::FUNCTION:
|
||||
ZLONG_it 1825 1_1_0 EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:
|
||||
ZLONG_it 1825 1_1_0 EXIST:EXPORT_VAR_AS_FUNCTION:FUNCTION:
|
||||
ZLONG_it 1825 1_1_0 EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:DEPRECATEDIN_1_2_0
|
||||
ZLONG_it 1825 1_1_0 EXIST:EXPORT_VAR_AS_FUNCTION:FUNCTION:DEPRECATEDIN_1_2_0
|
||||
OPENSSL_sk_find_ex 1826 1_1_0 EXIST::FUNCTION:
|
||||
ASN1_ENUMERATED_to_BN 1827 1_1_0 EXIST::FUNCTION:
|
||||
X509_CRL_get_ext_d2i 1828 1_1_0 EXIST::FUNCTION:
|
||||
@@ -1866,7 +1866,7 @@ TS_RESP_CTX_set_serial_cb 1851 1_1_0 EXIST::FUNCTION:TS
|
||||
POLICY_MAPPING_it 1852 1_1_0 EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:
|
||||
POLICY_MAPPING_it 1852 1_1_0 EXIST:EXPORT_VAR_AS_FUNCTION:FUNCTION:
|
||||
ERR_load_KDF_strings 1853 1_1_0 EXIST::FUNCTION:
|
||||
UI_method_set_reader 1854 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_method_set_reader 1854 1_1_0 EXIST::FUNCTION:
|
||||
BIO_next 1855 1_1_0 EXIST::FUNCTION:
|
||||
ASN1_STRING_set_default_mask_asc 1856 1_1_0 EXIST::FUNCTION:
|
||||
X509_CRL_new 1857 1_1_0 EXIST::FUNCTION:
|
||||
@@ -1913,7 +1913,7 @@ EVP_aes_192_cfb128 1896 1_1_0 EXIST::FUNCTION:
|
||||
OCSP_REQ_CTX_nbio 1897 1_1_0 EXIST::FUNCTION:OCSP
|
||||
EVP_CIPHER_CTX_copy 1898 1_1_0 EXIST::FUNCTION:
|
||||
CRYPTO_secure_allocated 1899 1_1_0 EXIST::FUNCTION:
|
||||
UI_UTIL_read_pw_string 1900 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_UTIL_read_pw_string 1900 1_1_0 EXIST::FUNCTION:
|
||||
NOTICEREF_free 1901 1_1_0 EXIST::FUNCTION:
|
||||
AES_cfb1_encrypt 1902 1_1_0 EXIST::FUNCTION:
|
||||
X509v3_get_ext 1903 1_1_0 EXIST::FUNCTION:
|
||||
@@ -1966,7 +1966,7 @@ PKCS12_unpack_p7data 1951 1_1_0 EXIST::FUNCTION:
|
||||
ECDSA_sign 1952 1_1_0 EXIST::FUNCTION:EC
|
||||
d2i_PKCS12_fp 1953 1_1_0 EXIST::FUNCTION:STDIO
|
||||
CMS_unsigned_get_attr_by_NID 1954 1_1_0 EXIST::FUNCTION:CMS
|
||||
UI_add_user_data 1955 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_add_user_data 1955 1_1_0 EXIST::FUNCTION:
|
||||
BN_bntest_rand 1956 1_1_0 EXIST::FUNCTION:
|
||||
X509_get_pubkey 1957 1_1_0 EXIST::FUNCTION:
|
||||
i2d_X509_NAME 1958 1_1_0 EXIST::FUNCTION:
|
||||
@@ -2032,7 +2032,7 @@ EC_POINT_point2hex 2013 1_1_0 EXIST::FUNCTION:EC
|
||||
ENGINE_get_default_DSA 2014 1_1_0 EXIST::FUNCTION:ENGINE
|
||||
ENGINE_register_all_complete 2015 1_1_0 EXIST::FUNCTION:ENGINE
|
||||
SRP_get_default_gN 2016 1_1_0 EXIST::FUNCTION:SRP
|
||||
UI_dup_input_boolean 2017 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_dup_input_boolean 2017 1_1_0 EXIST::FUNCTION:
|
||||
PKCS7_dup 2018 1_1_0 EXIST::FUNCTION:
|
||||
i2d_TS_REQ_fp 2019 1_1_0 EXIST::FUNCTION:STDIO,TS
|
||||
i2d_OTHERNAME 2020 1_1_0 EXIST::FUNCTION:
|
||||
@@ -2045,9 +2045,9 @@ ENGINE_get_pkey_asn1_meth_str 2026 1_1_0 EXIST::FUNCTION:ENGINE
|
||||
PKCS7_signatureVerify 2027 1_1_0 EXIST::FUNCTION:
|
||||
CRYPTO_ocb128_new 2028 1_1_0 EXIST::FUNCTION:OCB
|
||||
EC_curve_nist2nid 2029 1_1_0 EXIST::FUNCTION:EC
|
||||
UI_get0_result 2030 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_get0_result 2030 1_1_0 EXIST::FUNCTION:
|
||||
OCSP_request_add1_nonce 2031 1_1_0 EXIST::FUNCTION:OCSP
|
||||
UI_construct_prompt 2032 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_construct_prompt 2032 1_1_0 EXIST::FUNCTION:
|
||||
ENGINE_unregister_RSA 2033 1_1_0 EXIST::FUNCTION:ENGINE
|
||||
EC_GROUP_order_bits 2034 1_1_0 EXIST::FUNCTION:EC
|
||||
d2i_CMS_bio 2035 1_1_0 EXIST::FUNCTION:CMS
|
||||
@@ -2076,10 +2076,10 @@ EVP_CIPHER_CTX_original_iv 2054 1_1_0 EXIST::FUNCTION:
|
||||
PKCS7_SIGNED_free 2055 1_1_0 EXIST::FUNCTION:
|
||||
X509_TRUST_get0_name 2056 1_1_0 EXIST::FUNCTION:
|
||||
ENGINE_get_load_pubkey_function 2057 1_1_0 EXIST::FUNCTION:ENGINE
|
||||
UI_get_default_method 2058 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_get_default_method 2058 1_1_0 EXIST::FUNCTION:
|
||||
PKCS12_add_CSPName_asc 2059 1_1_0 EXIST::FUNCTION:
|
||||
PEM_write_PUBKEY 2060 1_1_0 EXIST::FUNCTION:STDIO
|
||||
UI_method_set_prompt_constructor 2061 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_method_set_prompt_constructor 2061 1_1_0 EXIST::FUNCTION:
|
||||
OBJ_length 2062 1_1_0 EXIST::FUNCTION:
|
||||
BN_GENCB_get_arg 2063 1_1_0 EXIST::FUNCTION:
|
||||
EVP_MD_CTX_clear_flags 2064 1_1_0 EXIST::FUNCTION:
|
||||
@@ -2107,7 +2107,7 @@ i2d_ASN1_GENERALSTRING 2085 1_1_0 EXIST::FUNCTION:
|
||||
POLICYQUALINFO_new 2086 1_1_0 EXIST::FUNCTION:
|
||||
PKCS7_RECIP_INFO_get0_alg 2087 1_1_0 EXIST::FUNCTION:
|
||||
EVP_PKEY_base_id 2088 1_1_0 EXIST::FUNCTION:
|
||||
UI_method_set_opener 2089 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_method_set_opener 2089 1_1_0 EXIST::FUNCTION:
|
||||
X509v3_get_ext_by_NID 2090 1_1_0 EXIST::FUNCTION:
|
||||
TS_CONF_set_policies 2091 1_1_0 EXIST::FUNCTION:TS
|
||||
CMS_SignerInfo_cert_cmp 2092 1_1_0 EXIST::FUNCTION:CMS
|
||||
@@ -2368,7 +2368,7 @@ ASN1_PRINTABLE_type 2338 1_1_0 EXIST::FUNCTION:
|
||||
TS_CONF_set_ess_cert_id_chain 2339 1_1_0 EXIST::FUNCTION:TS
|
||||
PEM_read_DSAPrivateKey 2340 1_1_0 EXIST::FUNCTION:DSA,STDIO
|
||||
DH_generate_parameters_ex 2341 1_1_0 EXIST::FUNCTION:DH
|
||||
UI_dup_input_string 2342 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_dup_input_string 2342 1_1_0 EXIST::FUNCTION:
|
||||
X509_keyid_set1 2343 1_1_0 EXIST::FUNCTION:
|
||||
X509_VERIFY_PARAM_set1 2344 1_1_0 EXIST::FUNCTION:
|
||||
EC_GROUP_get_asn1_flag 2345 1_1_0 EXIST::FUNCTION:EC
|
||||
@@ -2444,7 +2444,7 @@ ASN1_PCTX_set_nm_flags 2413 1_1_0 EXIST::FUNCTION:
|
||||
BIO_ctrl 2414 1_1_0 EXIST::FUNCTION:
|
||||
X509_CRL_set_default_method 2415 1_1_0 EXIST::FUNCTION:
|
||||
d2i_RSAPublicKey_fp 2417 1_1_0 EXIST::FUNCTION:RSA,STDIO
|
||||
UI_method_get_flusher 2418 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_method_get_flusher 2418 1_1_0 EXIST::FUNCTION:
|
||||
EC_POINT_dbl 2419 1_1_0 EXIST::FUNCTION:EC
|
||||
i2d_X509_CRL_INFO 2420 1_1_0 EXIST::FUNCTION:
|
||||
i2d_OCSP_CERTSTATUS 2421 1_1_0 EXIST::FUNCTION:OCSP
|
||||
@@ -2570,7 +2570,7 @@ X509_PURPOSE_add 2537 1_1_0 EXIST::FUNCTION:
|
||||
PKCS7_ENVELOPE_free 2538 1_1_0 EXIST::FUNCTION:
|
||||
PKCS12_key_gen_uni 2539 1_1_0 EXIST::FUNCTION:
|
||||
WHIRLPOOL 2540 1_1_0 EXIST::FUNCTION:WHIRLPOOL
|
||||
UI_set_default_method 2542 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_set_default_method 2542 1_1_0 EXIST::FUNCTION:
|
||||
EC_POINT_is_at_infinity 2543 1_1_0 EXIST::FUNCTION:EC
|
||||
i2d_NOTICEREF 2544 1_1_0 EXIST::FUNCTION:
|
||||
EC_KEY_new 2545 1_1_0 EXIST::FUNCTION:EC
|
||||
@@ -2795,8 +2795,8 @@ CT_POLICY_EVAL_CTX_new 2756 1_1_0 EXIST::FUNCTION:CT
|
||||
NETSCAPE_SPKI_it 2757 1_1_0 EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:
|
||||
NETSCAPE_SPKI_it 2757 1_1_0 EXIST:EXPORT_VAR_AS_FUNCTION:FUNCTION:
|
||||
CRYPTO_THREAD_unlock 2758 1_1_0 EXIST::FUNCTION:
|
||||
UI_method_set_writer 2759 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_dup_info_string 2760 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_method_set_writer 2759 1_1_0 EXIST::FUNCTION:
|
||||
UI_dup_info_string 2760 1_1_0 EXIST::FUNCTION:
|
||||
OPENSSL_init 2761 1_1_0 EXIST::FUNCTION:
|
||||
TS_RESP_get_tst_info 2762 1_1_0 EXIST::FUNCTION:TS
|
||||
X509_VERIFY_PARAM_get_depth 2763 1_1_0 EXIST::FUNCTION:
|
||||
@@ -3236,7 +3236,7 @@ RSAPrivateKey_dup 3188 1_1_0 EXIST::FUNCTION:RSA
|
||||
BN_mod_add 3189 1_1_0 EXIST::FUNCTION:
|
||||
EC_POINT_set_affine_coordinates_GFp 3190 1_1_0 EXIST::FUNCTION:EC
|
||||
X509_get_default_cert_file 3191 1_1_0 EXIST::FUNCTION:
|
||||
UI_method_set_flusher 3192 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_method_set_flusher 3192 1_1_0 EXIST::FUNCTION:
|
||||
RSA_new_method 3193 1_1_0 EXIST::FUNCTION:RSA
|
||||
OCSP_request_verify 3194 1_1_0 EXIST::FUNCTION:OCSP
|
||||
CRYPTO_THREAD_run_once 3195 1_1_0 EXIST::FUNCTION:
|
||||
@@ -3299,7 +3299,7 @@ CMS_set1_eContentType 3251 1_1_0 EXIST::FUNCTION:CMS
|
||||
EVP_des_ede3_wrap 3252 1_1_0 EXIST::FUNCTION:DES
|
||||
GENERAL_SUBTREE_it 3253 1_1_0 EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:
|
||||
GENERAL_SUBTREE_it 3253 1_1_0 EXIST:EXPORT_VAR_AS_FUNCTION:FUNCTION:
|
||||
EVP_read_pw_string_min 3254 1_1_0 EXIST::FUNCTION:UI
|
||||
EVP_read_pw_string_min 3254 1_1_0 EXIST::FUNCTION:
|
||||
X509_set1_notBefore 3255 1_1_0 EXIST::FUNCTION:
|
||||
MD4 3256 1_1_0 EXIST::FUNCTION:MD4
|
||||
EVP_PKEY_CTX_dup 3257 1_1_0 EXIST::FUNCTION:
|
||||
@@ -3466,7 +3466,7 @@ ASN1_mbstring_copy 3417 1_1_0 EXIST::FUNCTION:
|
||||
PKCS7_set_type 3418 1_1_0 EXIST::FUNCTION:
|
||||
BIO_gets 3419 1_1_0 EXIST::FUNCTION:
|
||||
RSA_padding_check_PKCS1_type_1 3420 1_1_0 EXIST::FUNCTION:RSA
|
||||
UI_ctrl 3421 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_ctrl 3421 1_1_0 EXIST::FUNCTION:
|
||||
i2d_X509_REQ_fp 3422 1_1_0 EXIST::FUNCTION:STDIO
|
||||
BN_BLINDING_convert_ex 3423 1_1_0 EXIST::FUNCTION:
|
||||
ASN1_GENERALIZEDTIME_print 3424 1_1_0 EXIST::FUNCTION:
|
||||
@@ -3479,7 +3479,7 @@ OCSP_SINGLERESP_get_ext_count 3430 1_1_0 EXIST::FUNCTION:OCSP
|
||||
EC_POINT_free 3431 1_1_0 EXIST::FUNCTION:EC
|
||||
EVP_OpenFinal 3432 1_1_0 EXIST::FUNCTION:RSA
|
||||
RAND_egd_bytes 3433 1_1_0 EXIST::FUNCTION:EGD
|
||||
UI_method_get_writer 3434 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_method_get_writer 3434 1_1_0 EXIST::FUNCTION:
|
||||
BN_secure_new 3435 1_1_0 EXIST::FUNCTION:
|
||||
SHA1_Update 3437 1_1_0 EXIST::FUNCTION:
|
||||
BIO_s_connect 3438 1_1_0 EXIST::FUNCTION:SOCK
|
||||
@@ -3642,7 +3642,7 @@ RAND_bytes 3596 1_1_0 EXIST::FUNCTION:
|
||||
PKCS7_free 3597 1_1_0 EXIST::FUNCTION:
|
||||
X509_NAME_ENTRY_create_by_txt 3598 1_1_0 EXIST::FUNCTION:
|
||||
DES_cbc_cksum 3599 1_1_0 EXIST::FUNCTION:DES
|
||||
UI_free 3600 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_free 3600 1_1_0 EXIST::FUNCTION:
|
||||
BN_is_prime 3601 1_1_0 EXIST::FUNCTION:DEPRECATEDIN_0_9_8
|
||||
CMS_get0_signers 3602 1_1_0 EXIST::FUNCTION:CMS
|
||||
i2d_PrivateKey_fp 3603 1_1_0 EXIST::FUNCTION:STDIO
|
||||
@@ -3665,7 +3665,7 @@ TS_CONF_set_signer_digest 3619 1_1_0 EXIST::FUNCTION:TS
|
||||
OBJ_new_nid 3620 1_1_0 EXIST::FUNCTION:
|
||||
CMS_ReceiptRequest_new 3621 1_1_0 EXIST::FUNCTION:CMS
|
||||
SRP_VBASE_get1_by_user 3622 1_1_0 EXIST::FUNCTION:SRP
|
||||
UI_method_get_closer 3623 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_method_get_closer 3623 1_1_0 EXIST::FUNCTION:
|
||||
ENGINE_get_ex_data 3624 1_1_0 EXIST::FUNCTION:ENGINE
|
||||
BN_print_fp 3625 1_1_0 EXIST::FUNCTION:STDIO
|
||||
MD2_Update 3626 1_1_0 EXIST::FUNCTION:MD2
|
||||
@@ -3759,7 +3759,7 @@ ENGINE_register_all_digests 3713 1_1_0 EXIST::FUNCTION:ENGINE
|
||||
X509_REQ_get_version 3714 1_1_0 EXIST::FUNCTION:
|
||||
i2d_ASN1_UTCTIME 3715 1_1_0 EXIST::FUNCTION:
|
||||
TS_STATUS_INFO_new 3716 1_1_0 EXIST::FUNCTION:TS
|
||||
UI_set_ex_data 3717 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_set_ex_data 3717 1_1_0 EXIST::FUNCTION:
|
||||
ASN1_TIME_set 3718 1_1_0 EXIST::FUNCTION:
|
||||
TS_RESP_verify_response 3719 1_1_0 EXIST::FUNCTION:TS
|
||||
X509_REVOKED_get0_serialNumber 3720 1_1_0 EXIST::FUNCTION:
|
||||
@@ -3796,7 +3796,7 @@ EVP_PKEY_meth_get_sign 3750 1_1_0 EXIST::FUNCTION:
|
||||
TS_REQ_get_nonce 3751 1_1_0 EXIST::FUNCTION:TS
|
||||
ENGINE_unregister_EC 3752 1_1_0 EXIST::FUNCTION:ENGINE
|
||||
X509v3_get_ext_count 3753 1_1_0 EXIST::FUNCTION:
|
||||
UI_OpenSSL 3754 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_OpenSSL 3754 1_1_0 EXIST::FUNCTION:UI_CONSOLE
|
||||
CRYPTO_ccm128_decrypt 3755 1_1_0 EXIST::FUNCTION:
|
||||
d2i_OCSP_RESPDATA 3756 1_1_0 EXIST::FUNCTION:OCSP
|
||||
BIO_set_callback 3757 1_1_0 EXIST::FUNCTION:
|
||||
@@ -3826,7 +3826,7 @@ RSA_PSS_PARAMS_it 3779 1_1_0 EXIST:EXPORT_VAR_AS_FUNCTION:
|
||||
X509_STORE_CTX_get_error_depth 3780 1_1_0 EXIST::FUNCTION:
|
||||
ASN1_GENERALIZEDTIME_set_string 3781 1_1_0 EXIST::FUNCTION:
|
||||
EC_GROUP_new_curve_GFp 3782 1_1_0 EXIST::FUNCTION:EC
|
||||
UI_new_method 3783 1_1_0 EXIST::FUNCTION:UI
|
||||
UI_new_method 3783 1_1_0 EXIST::FUNCTION:
|
||||
Camellia_ofb128_encrypt 3784 1_1_0 EXIST::FUNCTION:CAMELLIA
|
||||
X509_new 3785 1_1_0 EXIST::FUNCTION:
|
||||
EC_KEY_get_conv_form 3786 1_1_0 EXIST::FUNCTION:EC
|
||||
@@ -4206,14 +4206,54 @@ ECPARAMETERS_new 4156 1_1_0 EXIST::FUNCTION:EC
|
||||
OCSP_RESPID_set_by_name 4157 1_1_0a EXIST::FUNCTION:OCSP
|
||||
OCSP_RESPID_set_by_key 4158 1_1_0a EXIST::FUNCTION:OCSP
|
||||
OCSP_RESPID_match 4159 1_1_0a EXIST::FUNCTION:OCSP
|
||||
ASN1_ITEM_lookup 4160 1_1_1 EXIST::FUNCTION:
|
||||
ASN1_ITEM_get 4161 1_1_1 EXIST::FUNCTION:
|
||||
BIO_read_ex 4162 1_1_1 EXIST::FUNCTION:
|
||||
BIO_set_callback_ex 4163 1_1_1 EXIST::FUNCTION:
|
||||
BIO_get_callback_ex 4164 1_1_1 EXIST::FUNCTION:
|
||||
BIO_meth_set_read_ex 4165 1_1_1 EXIST::FUNCTION:
|
||||
BIO_meth_get_read_ex 4166 1_1_1 EXIST::FUNCTION:
|
||||
BIO_write_ex 4167 1_1_1 EXIST::FUNCTION:
|
||||
BIO_meth_get_write_ex 4168 1_1_1 EXIST::FUNCTION:
|
||||
BIO_meth_set_write_ex 4169 1_1_1 EXIST::FUNCTION:
|
||||
DSO_pathbyaddr 4170 1_1_0c EXIST::FUNCTION:
|
||||
DSO_dsobyaddr 4171 1_1_0c EXIST::FUNCTION:
|
||||
CT_POLICY_EVAL_CTX_get_time 4172 1_1_0d EXIST::FUNCTION:CT
|
||||
CT_POLICY_EVAL_CTX_set_time 4173 1_1_0d EXIST::FUNCTION:CT
|
||||
X509_VERIFY_PARAM_set_inh_flags 4174 1_1_0d EXIST::FUNCTION:
|
||||
X509_VERIFY_PARAM_get_inh_flags 4175 1_1_0d EXIST::FUNCTION:
|
||||
EVP_PKEY_CTX_md 4176 1_1_1 EXIST::FUNCTION:
|
||||
RSA_pkey_ctx_ctrl 4177 1_1_1 EXIST::FUNCTION:RSA
|
||||
UI_method_set_ex_data 4178 1_1_1 EXIST::FUNCTION:
|
||||
UI_method_get_ex_data 4179 1_1_1 EXIST::FUNCTION:
|
||||
UI_UTIL_wrap_read_pem_callback 4180 1_1_1 EXIST::FUNCTION:
|
||||
X509_VERIFY_PARAM_get_time 4181 1_1_0d EXIST::FUNCTION:
|
||||
EVP_PKEY_get0_poly1305 4182 1_1_1 EXIST::FUNCTION:POLY1305
|
||||
DH_check_params 4183 1_1_0d EXIST::FUNCTION:DH
|
||||
EVP_PKEY_get0_siphash 4184 1_1_1 EXIST::FUNCTION:SIPHASH
|
||||
EVP_aria_256_ofb 4185 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_256_cfb128 4186 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_128_cfb1 4187 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_128_ecb 4188 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_128_cfb128 4189 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_192_ecb 4190 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_128_cbc 4191 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_192_ofb 4192 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_192_cbc 4193 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_192_cfb1 4194 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_128_cfb8 4195 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_256_cfb1 4196 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_192_cfb8 4197 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_256_cfb8 4198 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_256_cbc 4199 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_128_ofb 4200 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_192_cfb128 4201 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_256_ecb 4202 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_256_ctr 4203 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_128_ctr 4204 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_192_ctr 4205 1_1_1 EXIST::FUNCTION:ARIA
|
||||
UI_null 4206 1_1_1 EXIST::FUNCTION:
|
||||
EC_KEY_get0_engine 4207 1_1_1 EXIST::FUNCTION:EC
|
||||
INT32_it 4208 1_1_0f EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:
|
||||
INT32_it 4208 1_1_0f EXIST:EXPORT_VAR_AS_FUNCTION:FUNCTION:
|
||||
UINT64_it 4209 1_1_0f EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:
|
||||
@@ -4230,7 +4270,254 @@ UINT32_it 4214 1_1_0f EXIST:!EXPORT_VAR_AS_FUNCTIO
|
||||
UINT32_it 4214 1_1_0f EXIST:EXPORT_VAR_AS_FUNCTION:FUNCTION:
|
||||
ZINT64_it 4215 1_1_0f EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:
|
||||
ZINT64_it 4215 1_1_0f EXIST:EXPORT_VAR_AS_FUNCTION:FUNCTION:
|
||||
CRYPTO_mem_leaks_cb 4216 1_1_1 EXIST::FUNCTION:CRYPTO_MDEBUG
|
||||
BIO_lookup_ex 4217 1_1_1 EXIST::FUNCTION:SOCK
|
||||
X509_CRL_print_ex 4218 1_1_1 EXIST::FUNCTION:
|
||||
X509_SIG_INFO_get 4219 1_1_1 EXIST::FUNCTION:
|
||||
X509_get_signature_info 4220 1_1_1 EXIST::FUNCTION:
|
||||
X509_SIG_INFO_set 4221 1_1_1 EXIST::FUNCTION:
|
||||
ESS_CERT_ID_V2_free 4222 1_1_1 EXIST::FUNCTION:TS
|
||||
ESS_SIGNING_CERT_V2_new 4223 1_1_1 EXIST::FUNCTION:TS
|
||||
d2i_ESS_SIGNING_CERT_V2 4224 1_1_1 EXIST::FUNCTION:TS
|
||||
i2d_ESS_CERT_ID_V2 4225 1_1_1 EXIST::FUNCTION:TS
|
||||
ESS_CERT_ID_V2_dup 4226 1_1_1 EXIST::FUNCTION:TS
|
||||
TS_RESP_CTX_set_ess_cert_id_digest 4227 1_1_1 EXIST::FUNCTION:TS
|
||||
d2i_ESS_CERT_ID_V2 4228 1_1_1 EXIST::FUNCTION:TS
|
||||
i2d_ESS_SIGNING_CERT_V2 4229 1_1_1 EXIST::FUNCTION:TS
|
||||
TS_CONF_set_ess_cert_id_digest 4230 1_1_1 EXIST::FUNCTION:TS
|
||||
ESS_SIGNING_CERT_V2_free 4231 1_1_1 EXIST::FUNCTION:TS
|
||||
ESS_SIGNING_CERT_V2_dup 4232 1_1_1 EXIST::FUNCTION:TS
|
||||
ESS_CERT_ID_V2_new 4233 1_1_1 EXIST::FUNCTION:TS
|
||||
PEM_read_bio_ex 4234 1_1_1 EXIST::FUNCTION:
|
||||
PEM_bytes_read_bio_secmem 4235 1_1_1 EXIST::FUNCTION:
|
||||
EVP_DigestSign 4236 1_1_1 EXIST::FUNCTION:
|
||||
EVP_DigestVerify 4237 1_1_1 EXIST::FUNCTION:
|
||||
UI_method_get_data_duplicator 4238 1_1_1 EXIST::FUNCTION:
|
||||
UI_method_set_data_duplicator 4239 1_1_1 EXIST::FUNCTION:
|
||||
UI_dup_user_data 4240 1_1_1 EXIST::FUNCTION:
|
||||
UI_method_get_data_destructor 4241 1_1_1 EXIST::FUNCTION:
|
||||
ERR_load_strings_const 4242 1_1_1 EXIST::FUNCTION:
|
||||
ASN1_TIME_to_tm 4243 1_1_1 EXIST::FUNCTION:
|
||||
ASN1_TIME_set_string_X509 4244 1_1_1 EXIST::FUNCTION:
|
||||
OCSP_resp_get1_id 4245 1_1_1 EXIST::FUNCTION:OCSP
|
||||
OSSL_STORE_register_loader 4246 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_LOADER_set_error 4247 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_INFO_get0_PKEY 4248 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_INFO_get_type 4249 1_1_1 EXIST::FUNCTION:
|
||||
ERR_load_OSSL_STORE_strings 4250 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_LOADER_free 4251 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_INFO_get1_PKEY 4252 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_INFO_free 4253 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_open_file 4254 1_1_1 NOEXIST::FUNCTION:
|
||||
OSSL_STORE_LOADER_set_eof 4255 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_LOADER_new 4256 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_INFO_get0_CERT 4257 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_LOADER_set_close 4258 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_INFO_new_PARAMS 4259 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_INFO_new_PKEY 4260 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_INFO_get1_PARAMS 4261 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_INFO_get1_CRL 4262 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_error 4263 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_INFO_get1_CERT 4264 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_INFO_get0_PARAMS 4265 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_INFO_type_string 4266 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_INFO_get1_NAME 4267 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_LOADER_set_load 4268 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_LOADER_get0_scheme 4269 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_open 4270 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_close 4271 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_INFO_new_CERT 4272 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_INFO_get0_CRL 4273 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_load 4274 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_INFO_get0_NAME 4275 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_unregister_loader 4276 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_INFO_new_CRL 4277 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_INFO_new_NAME 4278 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_eof 4279 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_LOADER_set_open 4280 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_LOADER_set_ctrl 4281 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_ctrl 4282 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_INFO_get0_NAME_description 4283 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_INFO_set0_NAME_description 4284 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_INFO_get1_NAME_description 4285 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_do_all_loaders 4286 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_LOADER_get0_engine 4287 1_1_1 EXIST::FUNCTION:
|
||||
OPENSSL_fork_prepare 4288 1_1_1 EXIST:UNIX:FUNCTION:
|
||||
OPENSSL_fork_parent 4289 1_1_1 EXIST:UNIX:FUNCTION:
|
||||
OPENSSL_fork_child 4290 1_1_1 EXIST:UNIX:FUNCTION:
|
||||
RAND_DRBG_instantiate 4292 1_1_1 EXIST::FUNCTION:
|
||||
RAND_DRBG_uninstantiate 4293 1_1_1 EXIST::FUNCTION:
|
||||
RAND_DRBG_set 4295 1_1_1 EXIST::FUNCTION:
|
||||
RAND_DRBG_set_callbacks 4296 1_1_1 EXIST::FUNCTION:
|
||||
RAND_DRBG_new 4297 1_1_1 EXIST::FUNCTION:
|
||||
RAND_DRBG_set_reseed_interval 4298 1_1_1 EXIST::FUNCTION:
|
||||
RAND_DRBG_free 4299 1_1_1 EXIST::FUNCTION:
|
||||
RAND_DRBG_generate 4300 1_1_1 EXIST::FUNCTION:
|
||||
RAND_DRBG_reseed 4301 1_1_1 EXIST::FUNCTION:
|
||||
RAND_DRBG_set_ex_data 4302 1_1_1 EXIST::FUNCTION:
|
||||
RAND_DRBG_get_ex_data 4303 1_1_1 EXIST::FUNCTION:
|
||||
EVP_sha3_224 4304 1_1_1 EXIST::FUNCTION:
|
||||
EVP_sha3_256 4305 1_1_1 EXIST::FUNCTION:
|
||||
EVP_sha3_384 4306 1_1_1 EXIST::FUNCTION:
|
||||
EVP_sha3_512 4307 1_1_1 EXIST::FUNCTION:
|
||||
EVP_shake128 4308 1_1_1 EXIST::FUNCTION:
|
||||
EVP_shake256 4309 1_1_1 EXIST::FUNCTION:
|
||||
SCRYPT_PARAMS_new 4310 1_1_1 EXIST::FUNCTION:SCRYPT
|
||||
SCRYPT_PARAMS_free 4311 1_1_1 EXIST::FUNCTION:SCRYPT
|
||||
i2d_SCRYPT_PARAMS 4312 1_1_1 EXIST::FUNCTION:SCRYPT
|
||||
d2i_SCRYPT_PARAMS 4313 1_1_1 EXIST::FUNCTION:SCRYPT
|
||||
SCRYPT_PARAMS_it 4314 1_1_1 EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:SCRYPT
|
||||
SCRYPT_PARAMS_it 4314 1_1_1 EXIST:EXPORT_VAR_AS_FUNCTION:FUNCTION:SCRYPT
|
||||
CRYPTO_secure_clear_free 4315 1_1_0g EXIST::FUNCTION:
|
||||
EVP_PKEY_meth_get0 4316 1_1_1 EXIST::FUNCTION:
|
||||
EVP_PKEY_meth_get_count 4317 1_1_1 EXIST::FUNCTION:
|
||||
RAND_DRBG_get0_public 4319 1_1_1 EXIST::FUNCTION:
|
||||
RAND_priv_bytes 4320 1_1_1 EXIST::FUNCTION:
|
||||
BN_priv_rand 4321 1_1_1 EXIST::FUNCTION:
|
||||
BN_priv_rand_range 4322 1_1_1 EXIST::FUNCTION:
|
||||
ASN1_TIME_normalize 4323 1_1_1 EXIST::FUNCTION:
|
||||
ASN1_TIME_cmp_time_t 4324 1_1_1 EXIST::FUNCTION:
|
||||
ASN1_TIME_compare 4325 1_1_1 EXIST::FUNCTION:
|
||||
EVP_PKEY_CTX_ctrl_uint64 4326 1_1_1 EXIST::FUNCTION:
|
||||
EVP_DigestFinalXOF 4327 1_1_1 EXIST::FUNCTION:
|
||||
ERR_clear_last_mark 4328 1_1_1 EXIST::FUNCTION:
|
||||
RAND_DRBG_get0_private 4329 1_1_1 EXIST::FUNCTION:
|
||||
EVP_aria_192_ccm 4330 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_256_gcm 4331 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_256_ccm 4332 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_128_gcm 4333 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_128_ccm 4334 1_1_1 EXIST::FUNCTION:ARIA
|
||||
EVP_aria_192_gcm 4335 1_1_1 EXIST::FUNCTION:ARIA
|
||||
UI_get_result_length 4337 1_1_1 EXIST::FUNCTION:
|
||||
UI_set_result_ex 4338 1_1_1 EXIST::FUNCTION:
|
||||
UI_get_result_string_length 4339 1_1_1 EXIST::FUNCTION:
|
||||
EVP_PKEY_check 4340 1_1_1 EXIST::FUNCTION:
|
||||
EVP_PKEY_meth_set_check 4341 1_1_1 EXIST::FUNCTION:
|
||||
EVP_PKEY_meth_get_check 4342 1_1_1 EXIST::FUNCTION:
|
||||
EVP_PKEY_meth_remove 4343 1_1_1 EXIST::FUNCTION:
|
||||
OPENSSL_sk_reserve 4344 1_1_1 EXIST::FUNCTION:
|
||||
CRYPTO_atomic_read 4345 1_1_1 EXIST::FUNCTION:
|
||||
CRYPTO_atomic_write 4346 1_1_1 EXIST::FUNCTION:
|
||||
EVP_PKEY_set1_engine 4347 1_1_0g EXIST::FUNCTION:ENGINE
|
||||
DH_new_by_nid 4348 1_1_1 EXIST::FUNCTION:DH
|
||||
DH_get_nid 4349 1_1_1 EXIST::FUNCTION:DH
|
||||
CRYPTO_get_alloc_counts 4350 1_1_1 EXIST::FUNCTION:CRYPTO_MDEBUG
|
||||
RAND_POOL_new 4351 1_1_1 EXIST::FUNCTION:
|
||||
RAND_POOL_free 4352 1_1_1 EXIST::FUNCTION:
|
||||
RAND_POOL_buffer 4353 1_1_1 EXIST::FUNCTION:
|
||||
RAND_POOL_detach 4354 1_1_1 EXIST::FUNCTION:
|
||||
RAND_POOL_entropy 4355 1_1_1 EXIST::FUNCTION:
|
||||
RAND_POOL_length 4356 1_1_1 EXIST::FUNCTION:
|
||||
RAND_POOL_entropy_available 4357 1_1_1 EXIST::FUNCTION:
|
||||
RAND_POOL_entropy_needed 4358 1_1_1 EXIST::FUNCTION:
|
||||
RAND_POOL_bytes_needed 4359 1_1_1 EXIST::FUNCTION:
|
||||
RAND_POOL_bytes_remaining 4360 1_1_1 EXIST::FUNCTION:
|
||||
RAND_POOL_add 4361 1_1_1 EXIST::FUNCTION:
|
||||
RAND_POOL_add_begin 4362 1_1_1 EXIST::FUNCTION:
|
||||
RAND_POOL_add_end 4363 1_1_1 EXIST::FUNCTION:
|
||||
RAND_POOL_acquire_entropy 4364 1_1_1 EXIST::FUNCTION:
|
||||
OPENSSL_sk_new_reserve 4365 1_1_1 EXIST::FUNCTION:
|
||||
EVP_PKEY_asn1_set_check 4366 1_1_1 EXIST::FUNCTION:
|
||||
EVP_PKEY_asn1_set_siginf 4367 1_1_1 EXIST::FUNCTION:
|
||||
EVP_sm4_ctr 4368 1_1_1 EXIST::FUNCTION:SM4
|
||||
EVP_sm4_cbc 4369 1_1_1 EXIST::FUNCTION:SM4
|
||||
EVP_sm4_ofb 4370 1_1_1 EXIST::FUNCTION:SM4
|
||||
EVP_sm4_ecb 4371 1_1_1 EXIST::FUNCTION:SM4
|
||||
EVP_sm4_cfb128 4372 1_1_1 EXIST::FUNCTION:SM4
|
||||
EVP_sm3 4373 1_1_1 EXIST::FUNCTION:SM3
|
||||
OCSP_resp_get0_signer 4374 1_1_0h EXIST::FUNCTION:OCSP
|
||||
EVP_PKEY_public_check 4375 1_1_1 EXIST::FUNCTION:
|
||||
EVP_PKEY_param_check 4376 1_1_1 EXIST::FUNCTION:
|
||||
EVP_PKEY_meth_set_public_check 4377 1_1_1 EXIST::FUNCTION:
|
||||
EVP_PKEY_meth_set_param_check 4378 1_1_1 EXIST::FUNCTION:
|
||||
EVP_PKEY_meth_get_public_check 4379 1_1_1 EXIST::FUNCTION:
|
||||
EVP_PKEY_meth_get_param_check 4380 1_1_1 EXIST::FUNCTION:
|
||||
EVP_PKEY_asn1_set_public_check 4381 1_1_1 EXIST::FUNCTION:
|
||||
EVP_PKEY_asn1_set_param_check 4382 1_1_1 EXIST::FUNCTION:
|
||||
DH_check_ex 4383 1_1_1 EXIST::FUNCTION:DH
|
||||
DH_check_pub_key_ex 4384 1_1_1 EXIST::FUNCTION:DH
|
||||
DH_check_params_ex 4385 1_1_1 EXIST::FUNCTION:DH
|
||||
RSA_generate_multi_prime_key 4386 1_1_1 EXIST::FUNCTION:RSA
|
||||
RSA_get_multi_prime_extra_count 4387 1_1_1 EXIST::FUNCTION:RSA
|
||||
RSA_get0_multi_prime_factors 4388 1_1_1 EXIST::FUNCTION:RSA
|
||||
RSA_get0_multi_prime_crt_params 4389 1_1_1 EXIST::FUNCTION:RSA
|
||||
RSA_set0_multi_prime_params 4390 1_1_1 EXIST::FUNCTION:RSA
|
||||
RSA_get_version 4391 1_1_1 EXIST::FUNCTION:RSA
|
||||
RSA_meth_get_multi_prime_keygen 4392 1_1_1 EXIST::FUNCTION:RSA
|
||||
RSA_meth_set_multi_prime_keygen 4393 1_1_1 EXIST::FUNCTION:RSA
|
||||
RAND_DRBG_get0_master 4394 1_1_1 EXIST::FUNCTION:
|
||||
RAND_DRBG_set_reseed_time_interval 4395 1_1_1 EXIST::FUNCTION:
|
||||
PROFESSION_INFO_get0_addProfessionInfo 4396 1_1_1 EXIST::FUNCTION:
|
||||
ADMISSION_SYNTAX_free 4397 1_1_1 EXIST::FUNCTION:
|
||||
d2i_ADMISSION_SYNTAX 4398 1_1_1 EXIST::FUNCTION:
|
||||
NAMING_AUTHORITY_set0_authorityId 4399 1_1_1 EXIST::FUNCTION:
|
||||
NAMING_AUTHORITY_set0_authorityURL 4400 1_1_1 EXIST::FUNCTION:
|
||||
d2i_PROFESSION_INFO 4401 1_1_1 EXIST::FUNCTION:
|
||||
NAMING_AUTHORITY_it 4402 1_1_1 EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:
|
||||
NAMING_AUTHORITY_it 4402 1_1_1 EXIST:EXPORT_VAR_AS_FUNCTION:FUNCTION:
|
||||
ADMISSION_SYNTAX_get0_contentsOfAdmissions 4403 1_1_1 EXIST::FUNCTION:
|
||||
PROFESSION_INFO_set0_professionItems 4404 1_1_1 EXIST::FUNCTION:
|
||||
NAMING_AUTHORITY_new 4405 1_1_1 EXIST::FUNCTION:
|
||||
NAMING_AUTHORITY_get0_authorityURL 4406 1_1_1 EXIST::FUNCTION:
|
||||
ADMISSION_SYNTAX_get0_admissionAuthority 4407 1_1_1 EXIST::FUNCTION:
|
||||
PROFESSION_INFO_new 4408 1_1_1 EXIST::FUNCTION:
|
||||
ADMISSIONS_new 4409 1_1_1 EXIST::FUNCTION:
|
||||
ADMISSION_SYNTAX_set0_admissionAuthority 4410 1_1_1 EXIST::FUNCTION:
|
||||
PROFESSION_INFO_get0_professionOIDs 4411 1_1_1 EXIST::FUNCTION:
|
||||
PROFESSION_INFO_it 4412 1_1_1 EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:
|
||||
PROFESSION_INFO_it 4412 1_1_1 EXIST:EXPORT_VAR_AS_FUNCTION:FUNCTION:
|
||||
i2d_PROFESSION_INFO 4413 1_1_1 EXIST::FUNCTION:
|
||||
ADMISSIONS_set0_professionInfos 4414 1_1_1 EXIST::FUNCTION:
|
||||
PROFESSION_INFO_get0_namingAuthority 4415 1_1_1 EXIST::FUNCTION:
|
||||
PROFESSION_INFO_free 4416 1_1_1 EXIST::FUNCTION:
|
||||
PROFESSION_INFO_set0_addProfessionInfo 4417 1_1_1 EXIST::FUNCTION:
|
||||
PROFESSION_INFO_set0_registrationNumber 4418 1_1_1 EXIST::FUNCTION:
|
||||
ADMISSION_SYNTAX_set0_contentsOfAdmissions 4419 1_1_1 EXIST::FUNCTION:
|
||||
NAMING_AUTHORITY_get0_authorityId 4420 1_1_1 EXIST::FUNCTION:
|
||||
ADMISSION_SYNTAX_it 4421 1_1_1 EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:
|
||||
ADMISSION_SYNTAX_it 4421 1_1_1 EXIST:EXPORT_VAR_AS_FUNCTION:FUNCTION:
|
||||
i2d_ADMISSION_SYNTAX 4422 1_1_1 EXIST::FUNCTION:
|
||||
NAMING_AUTHORITY_get0_authorityText 4423 1_1_1 EXIST::FUNCTION:
|
||||
PROFESSION_INFO_set0_namingAuthority 4424 1_1_1 EXIST::FUNCTION:
|
||||
i2d_NAMING_AUTHORITY 4425 1_1_1 EXIST::FUNCTION:
|
||||
NAMING_AUTHORITY_free 4426 1_1_1 EXIST::FUNCTION:
|
||||
ADMISSIONS_set0_admissionAuthority 4427 1_1_1 EXIST::FUNCTION:
|
||||
ADMISSIONS_free 4428 1_1_1 EXIST::FUNCTION:
|
||||
PROFESSION_INFO_get0_registrationNumber 4429 1_1_1 EXIST::FUNCTION:
|
||||
d2i_ADMISSIONS 4430 1_1_1 EXIST::FUNCTION:
|
||||
i2d_ADMISSIONS 4431 1_1_1 EXIST::FUNCTION:
|
||||
PROFESSION_INFO_get0_professionItems 4432 1_1_1 EXIST::FUNCTION:
|
||||
ADMISSIONS_get0_admissionAuthority 4433 1_1_1 EXIST::FUNCTION:
|
||||
PROFESSION_INFO_set0_professionOIDs 4434 1_1_1 EXIST::FUNCTION:
|
||||
d2i_NAMING_AUTHORITY 4435 1_1_1 EXIST::FUNCTION:
|
||||
ADMISSIONS_it 4436 1_1_1 EXIST:!EXPORT_VAR_AS_FUNCTION:VARIABLE:
|
||||
ADMISSIONS_it 4436 1_1_1 EXIST:EXPORT_VAR_AS_FUNCTION:FUNCTION:
|
||||
ADMISSIONS_get0_namingAuthority 4437 1_1_1 EXIST::FUNCTION:
|
||||
NAMING_AUTHORITY_set0_authorityText 4438 1_1_1 EXIST::FUNCTION:
|
||||
ADMISSIONS_set0_namingAuthority 4439 1_1_1 EXIST::FUNCTION:
|
||||
ADMISSIONS_get0_professionInfos 4440 1_1_1 EXIST::FUNCTION:
|
||||
ADMISSION_SYNTAX_new 4441 1_1_1 EXIST::FUNCTION:
|
||||
EVP_sha512_256 4442 1_1_1 EXIST::FUNCTION:
|
||||
EVP_sha512_224 4443 1_1_1 EXIST::FUNCTION:
|
||||
OCSP_basic_sign_ctx 4444 1_1_1 EXIST::FUNCTION:OCSP
|
||||
RAND_DRBG_bytes 4445 1_1_1 EXIST::FUNCTION:
|
||||
RAND_DRBG_secure_new 4446 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_vctrl 4447 1_1_1 EXIST::FUNCTION:
|
||||
X509_get0_authority_key_id 4448 1_1_0h EXIST::FUNCTION:
|
||||
BIO_bind 4449 1_1_1 EXIST::FUNCTION:SOCK
|
||||
OSSL_STORE_LOADER_set_expect 4450 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_expect 4451 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_SEARCH_by_key_fingerprint 4452 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_SEARCH_get0_serial 4453 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_SEARCH_by_name 4454 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_supports_search 4455 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_find 4456 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_SEARCH_get_type 4457 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_SEARCH_get0_bytes 4458 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_SEARCH_get0_string 4459 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_SEARCH_by_issuer_serial 4460 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_SEARCH_get0_name 4461 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_SEARCH_by_alias 4462 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_LOADER_set_find 4463 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_SEARCH_free 4464 1_1_1 EXIST::FUNCTION:
|
||||
OSSL_STORE_SEARCH_get0_digest 4465 1_1_1 EXIST::FUNCTION:
|
||||
+73
-1
@@ -86,7 +86,7 @@ SSL_CTX_set_cookie_verify_cb 86 1_1_0 EXIST::FUNCTION:
|
||||
SSL_get_shared_sigalgs 87 1_1_0 EXIST::FUNCTION:
|
||||
SSL_config 88 1_1_0 EXIST::FUNCTION:
|
||||
TLSv1_1_client_method 89 1_1_0 EXIST::FUNCTION:DEPRECATEDIN_1_1_0,TLS1_1_METHOD
|
||||
SSL_CIPHER_standard_name 90 1_1_0 EXIST::FUNCTION:SSL_TRACE
|
||||
SSL_CIPHER_standard_name 90 1_1_0 EXIST::FUNCTION:
|
||||
SSL_CTX_get_verify_mode 91 1_1_0 EXIST::FUNCTION:
|
||||
SSL_get_all_async_fds 92 1_1_0 EXIST::FUNCTION:
|
||||
SSL_CTX_check_private_key 93 1_1_0 EXIST::FUNCTION:
|
||||
@@ -403,5 +403,77 @@ SSL_dane_clear_flags 403 1_1_0 EXIST::FUNCTION:
|
||||
SSL_SESSION_get0_cipher 404 1_1_0 EXIST::FUNCTION:
|
||||
SSL_SESSION_get0_id_context 405 1_1_0 EXIST::FUNCTION:
|
||||
SSL_SESSION_set1_id 406 1_1_0 EXIST::FUNCTION:
|
||||
SSL_CTX_set1_cert_store 407 1_1_1 EXIST::FUNCTION:
|
||||
DTLS_get_data_mtu 408 1_1_1 EXIST::FUNCTION:
|
||||
SSL_read_ex 409 1_1_1 EXIST::FUNCTION:
|
||||
SSL_peek_ex 410 1_1_1 EXIST::FUNCTION:
|
||||
SSL_write_ex 411 1_1_1 EXIST::FUNCTION:
|
||||
SSL_COMP_get_id 412 1_1_0d EXIST::FUNCTION:
|
||||
SSL_COMP_get0_name 413 1_1_0d EXIST::FUNCTION:
|
||||
SSL_CTX_set_keylog_callback 414 1_1_1 EXIST::FUNCTION:
|
||||
SSL_CTX_get_keylog_callback 415 1_1_1 EXIST::FUNCTION:
|
||||
SSL_get_peer_signature_type_nid 416 1_1_1 EXIST::FUNCTION:
|
||||
SSL_key_update 417 1_1_1 EXIST::FUNCTION:
|
||||
SSL_get_key_update_type 418 1_1_1 EXIST::FUNCTION:
|
||||
SSL_bytes_to_cipher_list 419 1_1_1 EXIST::FUNCTION:
|
||||
SSL_client_hello_get0_compression_methods 420 1_1_1 EXIST::FUNCTION:
|
||||
SSL_client_hello_get0_ciphers 421 1_1_1 EXIST::FUNCTION:
|
||||
SSL_client_hello_get0_ext 422 1_1_1 EXIST::FUNCTION:
|
||||
SSL_client_hello_get0_session_id 423 1_1_1 EXIST::FUNCTION:
|
||||
SSL_client_hello_get0_random 424 1_1_1 EXIST::FUNCTION:
|
||||
SSL_CTX_set_client_hello_cb 425 1_1_1 EXIST::FUNCTION:
|
||||
SSL_client_hello_get0_legacy_version 426 1_1_1 EXIST::FUNCTION:
|
||||
SSL_client_hello_isv2 427 1_1_1 EXIST::FUNCTION:
|
||||
SSL_set_max_early_data 428 1_1_1 EXIST::FUNCTION:
|
||||
SSL_CTX_set_max_early_data 429 1_1_1 EXIST::FUNCTION:
|
||||
SSL_get_max_early_data 430 1_1_1 EXIST::FUNCTION:
|
||||
SSL_CTX_get_max_early_data 431 1_1_1 EXIST::FUNCTION:
|
||||
SSL_write_early_data 432 1_1_1 EXIST::FUNCTION:
|
||||
SSL_read_early_data 433 1_1_1 EXIST::FUNCTION:
|
||||
SSL_get_early_data_status 434 1_1_1 EXIST::FUNCTION:
|
||||
SSL_SESSION_get_max_early_data 435 1_1_1 EXIST::FUNCTION:
|
||||
SSL_add1_CA_list 436 1_1_1 EXIST::FUNCTION:
|
||||
SSL_set0_CA_list 437 1_1_1 EXIST::FUNCTION:
|
||||
SSL_CTX_set0_CA_list 438 1_1_1 EXIST::FUNCTION:
|
||||
SSL_get0_CA_list 439 1_1_1 EXIST::FUNCTION:
|
||||
SSL_get0_peer_CA_list 440 1_1_1 EXIST::FUNCTION:
|
||||
SSL_CTX_add1_CA_list 441 1_1_1 EXIST::FUNCTION:
|
||||
SSL_CTX_get0_CA_list 442 1_1_1 EXIST::FUNCTION:
|
||||
SSL_CTX_add_custom_ext 443 1_1_1 EXIST::FUNCTION:
|
||||
SSL_SESSION_is_resumable 444 1_1_1 EXIST::FUNCTION:
|
||||
SSL_CTX_set_record_padding_callback 445 1_1_1 EXIST::FUNCTION:
|
||||
SSL_set_record_padding_callback 446 1_1_1 EXIST::FUNCTION:
|
||||
SSL_CTX_set_block_padding 447 1_1_1 EXIST::FUNCTION:
|
||||
SSL_CTX_get_record_padding_callback_arg 448 1_1_1 EXIST::FUNCTION:
|
||||
SSL_get_record_padding_callback_arg 449 1_1_1 EXIST::FUNCTION:
|
||||
SSL_set_block_padding 450 1_1_1 EXIST::FUNCTION:
|
||||
SSL_set_record_padding_callback_arg 451 1_1_1 EXIST::FUNCTION:
|
||||
SSL_CTX_set_record_padding_callback_arg 452 1_1_1 EXIST::FUNCTION:
|
||||
SSL_CTX_use_serverinfo_ex 453 1_1_1 EXIST::FUNCTION:
|
||||
SSL_client_hello_get1_extensions_present 454 1_1_1 EXIST::FUNCTION:
|
||||
SSL_set_psk_find_session_callback 455 1_1_1 EXIST::FUNCTION:
|
||||
SSL_set_psk_use_session_callback 456 1_1_1 EXIST::FUNCTION:
|
||||
SSL_CTX_set_psk_use_session_callback 457 1_1_1 EXIST::FUNCTION:
|
||||
SSL_CTX_set_psk_find_session_callback 458 1_1_1 EXIST::FUNCTION:
|
||||
SSL_CIPHER_get_handshake_digest 459 1_1_1 EXIST::FUNCTION:
|
||||
SSL_SESSION_set1_master_key 460 1_1_1 EXIST::FUNCTION:
|
||||
SSL_SESSION_set_cipher 461 1_1_1 EXIST::FUNCTION:
|
||||
SSL_SESSION_set_protocol_version 462 1_1_1 EXIST::FUNCTION:
|
||||
OPENSSL_cipher_name 463 1_1_1 EXIST::FUNCTION:
|
||||
SSL_alloc_buffers 464 1_1_1 EXIST::FUNCTION:
|
||||
SSL_free_buffers 465 1_1_1 EXIST::FUNCTION:
|
||||
SSL_SESSION_dup 466 1_1_1 EXIST::FUNCTION:
|
||||
SSL_get_pending_cipher 467 1_1_1 EXIST::FUNCTION:
|
||||
SSL_CIPHER_get_protocol_id 468 1_1_1 EXIST::FUNCTION:
|
||||
SSL_SESSION_set_max_early_data 469 1_1_1 EXIST::FUNCTION:
|
||||
SSL_SESSION_set1_alpn_selected 470 1_1_1 EXIST::FUNCTION:
|
||||
SSL_SESSION_set1_hostname 471 1_1_1 EXIST::FUNCTION:
|
||||
SSL_SESSION_get0_alpn_selected 472 1_1_1 EXIST::FUNCTION:
|
||||
DTLS_set_timer_cb 473 1_1_1 EXIST::FUNCTION:
|
||||
SSL_CTX_set_tlsext_max_fragment_length 474 1_1_1 EXIST::FUNCTION:
|
||||
SSL_set_tlsext_max_fragment_length 475 1_1_1 EXIST::FUNCTION:
|
||||
SSL_SESSION_get_max_fragment_length 476 1_1_1 EXIST::FUNCTION:
|
||||
SSL_stateless 477 1_1_1 EXIST::FUNCTION:
|
||||
SSL_verify_client_post_handshake 478 1_1_1 EXIST::FUNCTION:
|
||||
SSL_force_post_handshake_auth 479 1_1_1 EXIST::FUNCTION:
|
||||
SSL_export_keying_material_early 480 1_1_1 EXIST::FUNCTION:
|
||||
+24
-9
@@ -1,26 +1,43 @@
|
||||
#! /usr/bin/env perl
|
||||
# Copyright 2014-2016 The OpenSSL Project Authors. All Rights Reserved.
|
||||
# Copyright 2014-2017 The OpenSSL Project Authors. All Rights Reserved.
|
||||
#
|
||||
# Licensed under the OpenSSL license (the "License"). You may not use
|
||||
# this file except in compliance with the License. You can obtain a copy
|
||||
# in the file LICENSE in the source distribution or at
|
||||
# https://www.openssl.org/source/license.html
|
||||
|
||||
use strict;
|
||||
use warnings;
|
||||
|
||||
my ($cflags, $platform) = @ARGV;
|
||||
|
||||
$cflags = "compiler: $cflags";
|
||||
$date = localtime();
|
||||
|
||||
my $date = gmtime($ENV{'SOURCE_DATE_EPOCH'} || time()) . " UTC";
|
||||
|
||||
print <<"END_OUTPUT";
|
||||
/* auto-generated by util/mkbuildinf.pl for crypto/cversion.c */
|
||||
#define CFLAGS cflags
|
||||
/*
|
||||
* Generate CFLAGS as an array of individual characters. This is a
|
||||
* WARNING: do not edit!
|
||||
* Generated by util/mkbuildinf.pl
|
||||
*
|
||||
* Copyright 2014-2017 The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the OpenSSL license (the "License"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
#define PLATFORM "platform: $platform"
|
||||
#define DATE "built on: $date"
|
||||
|
||||
/*
|
||||
* Generate compiler_flags as an array of individual characters. This is a
|
||||
* workaround for the situation where CFLAGS gets too long for a C90 string
|
||||
* literal
|
||||
*/
|
||||
static const char cflags[] = {
|
||||
static const char compiler_flags[] = {
|
||||
END_OUTPUT
|
||||
|
||||
my $ctr = 0;
|
||||
foreach my $c (split //, $cflags) {
|
||||
$c =~ s|([\\'])|\\$1|;
|
||||
@@ -36,6 +53,4 @@ foreach my $c (split //, $cflags) {
|
||||
print <<"END_OUTPUT";
|
||||
'\\0'
|
||||
};
|
||||
#define PLATFORM "platform: $platform"
|
||||
#define DATE "built on: $date"
|
||||
END_OUTPUT
|
||||
-220
@@ -1,220 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
# This script will re-make all the required certs.
|
||||
# cd apps
|
||||
# sh ../util/mkcerts.sh
|
||||
# mv ca-cert.pem pca-cert.pem ../certs
|
||||
# cd ..
|
||||
# cat certs/*.pem >>apps/server.pem
|
||||
# cat certs/*.pem >>apps/server2.pem
|
||||
# SSLEAY=`pwd`/apps/ssleay; export SSLEAY
|
||||
# sh tools/c_rehash certs
|
||||
#
|
||||
|
||||
CAbits=1024
|
||||
SSLEAY="../apps/openssl"
|
||||
CONF="-config ../apps/openssl.cnf"
|
||||
|
||||
# create pca request.
|
||||
echo creating $CAbits bit PCA cert request
|
||||
$SSLEAY req $CONF \
|
||||
-new -sha256 -newkey $CAbits \
|
||||
-keyout pca-key.pem \
|
||||
-out pca-req.pem -nodes >/dev/null <<EOF
|
||||
AU
|
||||
Queensland
|
||||
.
|
||||
CryptSoft Pty Ltd
|
||||
.
|
||||
Test PCA (1024 bit)
|
||||
|
||||
|
||||
|
||||
EOF
|
||||
|
||||
if [ $? != 0 ]; then
|
||||
echo problems generating PCA request
|
||||
exit 1
|
||||
fi
|
||||
|
||||
#sign it.
|
||||
echo
|
||||
echo self signing PCA
|
||||
$SSLEAY x509 -sha256 -days 36525 \
|
||||
-req -signkey pca-key.pem \
|
||||
-CAcreateserial -CAserial pca-cert.srl \
|
||||
-in pca-req.pem -out pca-cert.pem
|
||||
|
||||
if [ $? != 0 ]; then
|
||||
echo problems self signing PCA cert
|
||||
exit 1
|
||||
fi
|
||||
echo
|
||||
|
||||
# create ca request.
|
||||
echo creating $CAbits bit CA cert request
|
||||
$SSLEAY req $CONF \
|
||||
-new -sha256 -newkey $CAbits \
|
||||
-keyout ca-key.pem \
|
||||
-out ca-req.pem -nodes >/dev/null <<EOF
|
||||
AU
|
||||
Queensland
|
||||
.
|
||||
CryptSoft Pty Ltd
|
||||
.
|
||||
Test CA (1024 bit)
|
||||
|
||||
|
||||
|
||||
EOF
|
||||
|
||||
if [ $? != 0 ]; then
|
||||
echo problems generating CA request
|
||||
exit 1
|
||||
fi
|
||||
|
||||
#sign it.
|
||||
echo
|
||||
echo signing CA
|
||||
$SSLEAY x509 -sha256 -days 36525 \
|
||||
-req \
|
||||
-CAcreateserial -CAserial pca-cert.srl \
|
||||
-CA pca-cert.pem -CAkey pca-key.pem \
|
||||
-in ca-req.pem -out ca-cert.pem
|
||||
|
||||
if [ $? != 0 ]; then
|
||||
echo problems signing CA cert
|
||||
exit 1
|
||||
fi
|
||||
echo
|
||||
|
||||
# create server request.
|
||||
echo creating 512 bit server cert request
|
||||
$SSLEAY req $CONF \
|
||||
-new -sha256 -newkey 512 \
|
||||
-keyout s512-key.pem \
|
||||
-out s512-req.pem -nodes >/dev/null <<EOF
|
||||
AU
|
||||
Queensland
|
||||
.
|
||||
CryptSoft Pty Ltd
|
||||
.
|
||||
Server test cert (512 bit)
|
||||
|
||||
|
||||
|
||||
EOF
|
||||
|
||||
if [ $? != 0 ]; then
|
||||
echo problems generating 512 bit server cert request
|
||||
exit 1
|
||||
fi
|
||||
|
||||
#sign it.
|
||||
echo
|
||||
echo signing 512 bit server cert
|
||||
$SSLEAY x509 -sha256 -days 36525 \
|
||||
-req \
|
||||
-CAcreateserial -CAserial ca-cert.srl \
|
||||
-CA ca-cert.pem -CAkey ca-key.pem \
|
||||
-in s512-req.pem -out server.pem
|
||||
|
||||
if [ $? != 0 ]; then
|
||||
echo problems signing 512 bit server cert
|
||||
exit 1
|
||||
fi
|
||||
echo
|
||||
|
||||
# create 1024 bit server request.
|
||||
echo creating 1024 bit server cert request
|
||||
$SSLEAY req $CONF \
|
||||
-new -sha256 -newkey 1024 \
|
||||
-keyout s1024key.pem \
|
||||
-out s1024req.pem -nodes >/dev/null <<EOF
|
||||
AU
|
||||
Queensland
|
||||
.
|
||||
CryptSoft Pty Ltd
|
||||
.
|
||||
Server test cert (1024 bit)
|
||||
|
||||
|
||||
|
||||
EOF
|
||||
|
||||
if [ $? != 0 ]; then
|
||||
echo problems generating 1024 bit server cert request
|
||||
exit 1
|
||||
fi
|
||||
|
||||
#sign it.
|
||||
echo
|
||||
echo signing 1024 bit server cert
|
||||
$SSLEAY x509 -sha256 -days 36525 \
|
||||
-req \
|
||||
-CAcreateserial -CAserial ca-cert.srl \
|
||||
-CA ca-cert.pem -CAkey ca-key.pem \
|
||||
-in s1024req.pem -out server2.pem
|
||||
|
||||
if [ $? != 0 ]; then
|
||||
echo problems signing 1024 bit server cert
|
||||
exit 1
|
||||
fi
|
||||
echo
|
||||
|
||||
# create 512 bit client request.
|
||||
echo creating 512 bit client cert request
|
||||
$SSLEAY req $CONF \
|
||||
-new -sha256 -newkey 512 \
|
||||
-keyout c512-key.pem \
|
||||
-out c512-req.pem -nodes >/dev/null <<EOF
|
||||
AU
|
||||
Queensland
|
||||
.
|
||||
CryptSoft Pty Ltd
|
||||
.
|
||||
Client test cert (512 bit)
|
||||
|
||||
|
||||
|
||||
EOF
|
||||
|
||||
if [ $? != 0 ]; then
|
||||
echo problems generating 512 bit client cert request
|
||||
exit 1
|
||||
fi
|
||||
|
||||
#sign it.
|
||||
echo
|
||||
echo signing 512 bit client cert
|
||||
$SSLEAY x509 -sha256 -days 36525 \
|
||||
-req \
|
||||
-CAcreateserial -CAserial ca-cert.srl \
|
||||
-CA ca-cert.pem -CAkey ca-key.pem \
|
||||
-in c512-req.pem -out client.pem
|
||||
|
||||
if [ $? != 0 ]; then
|
||||
echo problems signing 512 bit client cert
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo cleanup
|
||||
|
||||
cat pca-key.pem >> pca-cert.pem
|
||||
cat ca-key.pem >> ca-cert.pem
|
||||
cat s512-key.pem >> server.pem
|
||||
cat s1024key.pem >> server2.pem
|
||||
cat c512-key.pem >> client.pem
|
||||
|
||||
for i in pca-cert.pem ca-cert.pem server.pem server2.pem client.pem
|
||||
do
|
||||
$SSLEAY x509 -issuer -subject -in $i -noout >$$
|
||||
cat $$
|
||||
/bin/cat $i >>$$
|
||||
/bin/mv $$ $i
|
||||
done
|
||||
|
||||
#/bin/rm -f *key.pem *req.pem *.srl
|
||||
|
||||
echo Finished
|
||||
|
||||
+76
-124
@@ -24,7 +24,7 @@
|
||||
# existence:platform:kind:algorithms
|
||||
#
|
||||
# - "existence" can be "EXIST" or "NOEXIST" depending on if the symbol is
|
||||
# found somewhere in the source,
|
||||
# found somewhere in the source,
|
||||
# - "platforms" is empty if it exists on all platforms, otherwise it contains
|
||||
# comma-separated list of the platform, just as they are if the symbol exists
|
||||
# for those platforms, or prepended with a "!" if not. This helps resolve
|
||||
@@ -36,7 +36,7 @@
|
||||
# The semantics for the platforms is that every item is checked against the
|
||||
# environment. For the negative items ("!FOO"), if any of them is false
|
||||
# (i.e. "FOO" is true) in the environment, the corresponding symbol can't be
|
||||
# used. For the positive itms, if all of them are false in the environment,
|
||||
# used. For the positive items, if all of them are false in the environment,
|
||||
# the corresponding symbol can't be used. Any combination of positive and
|
||||
# negative items are possible, and of course leave room for some redundancy.
|
||||
# - "kind" is "FUNCTION" or "VARIABLE". The meaning of that is obvious.
|
||||
@@ -144,12 +144,21 @@ my @known_algorithms = ( # These are algorithms we know are guarded in relevant
|
||||
"DEPRECATEDIN_0_9_8",
|
||||
"DEPRECATEDIN_1_0_0",
|
||||
"DEPRECATEDIN_1_1_0",
|
||||
"DEPRECATEDIN_1_2_0",
|
||||
);
|
||||
|
||||
# %disabled comes from configdata.pm
|
||||
my %disabled_algorithms =
|
||||
map { (my $x = uc $_) =~ s|-|_|g; $x => 1; } keys %disabled;
|
||||
|
||||
my $apiv = sprintf "%x%02x%02x", split(/\./, $config{api});
|
||||
foreach (@known_algorithms) {
|
||||
if (/^DEPRECATEDIN_(\d+)_(\d+)_(\d+)$/) {
|
||||
my $depv = sprintf "%x%02x%02x", $1, $2, $3;
|
||||
$disabled_algorithms{$_} = 1 if $apiv ge $depv;
|
||||
}
|
||||
}
|
||||
|
||||
my $zlib;
|
||||
|
||||
foreach (@ARGV, split(/ /, $config{options}))
|
||||
@@ -173,48 +182,19 @@ foreach (@ARGV, split(/ /, $config{options}))
|
||||
$zlib = 1;
|
||||
}
|
||||
|
||||
$do_ssl=1 if $_ eq "libssl";
|
||||
if ($_ eq "ssl") {
|
||||
$do_ssl=1;
|
||||
$libname=$_
|
||||
}
|
||||
$do_crypto=1 if $_ eq "libcrypto";
|
||||
if ($_ eq "crypto") {
|
||||
$do_crypto=1;
|
||||
$libname=$_;
|
||||
}
|
||||
$do_crypto=1 if $_ eq "libcrypto" || $_ eq "crypto";
|
||||
$do_ssl=1 if $_ eq "libssl" || $_ eq "ssl";
|
||||
|
||||
$do_update=1 if $_ eq "update";
|
||||
$do_rewrite=1 if $_ eq "rewrite";
|
||||
$do_ctest=1 if $_ eq "ctest";
|
||||
$do_ctestall=1 if $_ eq "ctestall";
|
||||
$do_checkexist=1 if $_ eq "exist";
|
||||
if (/^--api=(\d+)\.(\d+)\.(\d+)$/) {
|
||||
my $apiv = sprintf "%x%02x%02x", $1, $2, $3;
|
||||
foreach (@known_algorithms) {
|
||||
if (/^DEPRECATEDIN_(\d+)_(\d+)_(\d+)$/) {
|
||||
my $depv = sprintf "%x%02x%02x", $1, $2, $3;
|
||||
$disabled_algorithms{$_} = 1 if $apiv ge $depv;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (/^no-deprecated$/) {
|
||||
foreach (@known_algorithms) {
|
||||
if (/^DEPRECATEDIN_/) {
|
||||
$disabled_algorithms{$_} = 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
elsif (/^(enable|disable|no)-(.*)$/) {
|
||||
my $alg = uc $2;
|
||||
$alg =~ tr/-/_/;
|
||||
if (exists $disabled_algorithms{$alg}) {
|
||||
$disabled_algorithms{$alg} = $1 eq "enable" ? 0 : 1;
|
||||
}
|
||||
}
|
||||
$libname = $unified_info{sharednames}->{libcrypto} if $do_crypto;
|
||||
$libname = $unified_info{sharednames}->{libssl} if $do_ssl;
|
||||
|
||||
}
|
||||
|
||||
if (!$libname) {
|
||||
if (!$libname) {
|
||||
if ($do_ssl) {
|
||||
$libname="LIBSSL";
|
||||
}
|
||||
@@ -242,75 +222,30 @@ $max_ssl = $max_num;
|
||||
$max_crypto = $max_num;
|
||||
|
||||
my $ssl="include/openssl/ssl.h";
|
||||
$ssl.=" include/openssl/sslerr.h";
|
||||
$ssl.=" include/openssl/tls1.h";
|
||||
$ssl.=" include/openssl/srtp.h";
|
||||
|
||||
# When scanning include/openssl, skip all SSL files and some internal ones.
|
||||
my %skipthese;
|
||||
foreach my $f ( split(/\s+/, $ssl) ) {
|
||||
$skipthese{$f} = 1;
|
||||
}
|
||||
$skipthese{'include/openssl/conf_api.h'} = 1;
|
||||
$skipthese{'include/openssl/ebcdic.h'} = 1;
|
||||
$skipthese{'include/openssl/opensslconf.h'} = 1;
|
||||
|
||||
# We use headers found in include/openssl and include/internal only.
|
||||
# The latter is needed so libssl.so/.dll/.exe can link properly.
|
||||
my $crypto ="include/openssl/crypto.h";
|
||||
my $crypto ="include/internal/dso.h";
|
||||
$crypto.=" include/internal/o_dir.h";
|
||||
$crypto.=" include/internal/o_str.h";
|
||||
$crypto.=" include/internal/err.h";
|
||||
$crypto.=" include/internal/asn1t.h";
|
||||
$crypto.=" include/openssl/des.h" ; # unless $no_des;
|
||||
$crypto.=" include/openssl/idea.h" ; # unless $no_idea;
|
||||
$crypto.=" include/openssl/rc4.h" ; # unless $no_rc4;
|
||||
$crypto.=" include/openssl/rc5.h" ; # unless $no_rc5;
|
||||
$crypto.=" include/openssl/rc2.h" ; # unless $no_rc2;
|
||||
$crypto.=" include/openssl/blowfish.h" ; # unless $no_bf;
|
||||
$crypto.=" include/openssl/cast.h" ; # unless $no_cast;
|
||||
$crypto.=" include/openssl/whrlpool.h" ;
|
||||
$crypto.=" include/openssl/md2.h" ; # unless $no_md2;
|
||||
$crypto.=" include/openssl/md4.h" ; # unless $no_md4;
|
||||
$crypto.=" include/openssl/md5.h" ; # unless $no_md5;
|
||||
$crypto.=" include/openssl/mdc2.h" ; # unless $no_mdc2;
|
||||
$crypto.=" include/openssl/sha.h" ; # unless $no_sha;
|
||||
$crypto.=" include/openssl/ripemd.h" ; # unless $no_ripemd;
|
||||
$crypto.=" include/openssl/aes.h" ; # unless $no_aes;
|
||||
$crypto.=" include/openssl/camellia.h" ; # unless $no_camellia;
|
||||
$crypto.=" include/openssl/seed.h"; # unless $no_seed;
|
||||
|
||||
$crypto.=" include/openssl/bn.h";
|
||||
$crypto.=" include/openssl/rsa.h" ; # unless $no_rsa;
|
||||
$crypto.=" include/openssl/dsa.h" ; # unless $no_dsa;
|
||||
$crypto.=" include/openssl/dh.h" ; # unless $no_dh;
|
||||
$crypto.=" include/openssl/ec.h" ; # unless $no_ec;
|
||||
$crypto.=" include/openssl/hmac.h" ; # unless $no_hmac;
|
||||
$crypto.=" include/openssl/cmac.h" ;
|
||||
|
||||
$crypto.=" include/openssl/engine.h"; # unless $no_engine;
|
||||
$crypto.=" include/openssl/stack.h" ; # unless $no_stack;
|
||||
$crypto.=" include/openssl/buffer.h" ; # unless $no_buffer;
|
||||
$crypto.=" include/openssl/bio.h" ; # unless $no_bio;
|
||||
$crypto.=" include/internal/dso.h" ; # unless $no_dso;
|
||||
$crypto.=" include/openssl/lhash.h" ; # unless $no_lhash;
|
||||
$crypto.=" include/openssl/conf.h";
|
||||
$crypto.=" include/openssl/txt_db.h";
|
||||
|
||||
$crypto.=" include/openssl/evp.h" ; # unless $no_evp;
|
||||
$crypto.=" include/openssl/objects.h";
|
||||
$crypto.=" include/openssl/pem.h";
|
||||
#$crypto.=" include/openssl/meth.h";
|
||||
$crypto.=" include/openssl/asn1.h";
|
||||
$crypto.=" include/openssl/asn1t.h";
|
||||
$crypto.=" include/openssl/err.h" ; # unless $no_err;
|
||||
$crypto.=" include/openssl/pkcs7.h";
|
||||
$crypto.=" include/openssl/pkcs12.h";
|
||||
$crypto.=" include/openssl/x509.h";
|
||||
$crypto.=" include/openssl/x509_vfy.h";
|
||||
$crypto.=" include/openssl/x509v3.h";
|
||||
$crypto.=" include/openssl/ts.h";
|
||||
$crypto.=" include/openssl/rand.h";
|
||||
$crypto.=" include/openssl/comp.h" ; # unless $no_comp;
|
||||
$crypto.=" include/openssl/ocsp.h";
|
||||
$crypto.=" include/openssl/ui.h";
|
||||
#$crypto.=" include/openssl/store.h";
|
||||
$crypto.=" include/openssl/cms.h";
|
||||
$crypto.=" include/openssl/srp.h";
|
||||
$crypto.=" include/openssl/modes.h";
|
||||
$crypto.=" include/openssl/async.h";
|
||||
$crypto.=" include/openssl/ct.h";
|
||||
$crypto.=" include/openssl/kdf.h";
|
||||
$crypto.=" include/internal/rand.h";
|
||||
foreach my $f ( glob(catfile($config{sourcedir},'include/openssl/*.h')) ) {
|
||||
my $fn = "include/openssl/" . lc(basename($f));
|
||||
$crypto .= " $fn" if !defined $skipthese{$fn};
|
||||
}
|
||||
|
||||
my $symhacks="include/openssl/symhacks.h";
|
||||
|
||||
@@ -343,7 +278,7 @@ if($do_crypto == 1) {
|
||||
}
|
||||
&update_numbers(*OUT,"LIBCRYPTO",*crypto_list,$max_crypto,@crypto_symbols);
|
||||
close OUT;
|
||||
}
|
||||
}
|
||||
|
||||
} elsif ($do_checkexist) {
|
||||
&check_existing(*ssl_list, @ssl_symbols)
|
||||
@@ -399,14 +334,16 @@ sub do_defs
|
||||
foreach $file (split(/\s+/,$symhacksfile." ".$files))
|
||||
{
|
||||
my $fn = catfile($config{sourcedir},$file);
|
||||
print STDERR "DEBUG: starting on $fn:\n" if $debug;
|
||||
print STDERR "TRACE: start reading $fn\n" if $trace;
|
||||
open(IN,"<$fn") || die "unable to open $fn:$!\n";
|
||||
open(IN,"<$fn") || die "Can't open $fn, $!,";
|
||||
my $line = "", my $def= "";
|
||||
my %tag = (
|
||||
(map { $_ => 0 } @known_platforms),
|
||||
(map { "OPENSSL_SYS_".$_ => 0 } @known_ossl_platforms),
|
||||
(map { "OPENSSL_NO_".$_ => 0 } @known_algorithms),
|
||||
(map { "OPENSSL_USE_".$_ => 0 } @known_algorithms),
|
||||
(grep /^DEPRECATED_/, @known_algorithms),
|
||||
NOPROTO => 0,
|
||||
PERL5 => 0,
|
||||
_WINDLL => 0,
|
||||
@@ -498,7 +435,7 @@ sub do_defs
|
||||
}
|
||||
|
||||
if(/\/\*/) {
|
||||
if (not /\*\//) { # multiline comment...
|
||||
if (not /\*\//) { # multi-line comment...
|
||||
$line = $_; # ... just accumulate
|
||||
next;
|
||||
} else {
|
||||
@@ -519,7 +456,22 @@ sub do_defs
|
||||
s/{[^{}]*}//gs; # ignore {} blocks
|
||||
print STDERR "DEBUG: \$def=\"$def\"\n" if $debug && $def ne "";
|
||||
print STDERR "DEBUG: \$_=\"$_\"\n" if $debug;
|
||||
if (/^\#\s*ifndef\s+(.*)/) {
|
||||
if (/^\#\s*if\s+OPENSSL_API_COMPAT\s*(\S)\s*(0x[0-9a-fA-F]{8})L\s*$/) {
|
||||
my $op = $1;
|
||||
my $v = hex($2);
|
||||
if ($op ne '<' && $op ne '>=') {
|
||||
die "$file unacceptable operator $op: $_\n";
|
||||
}
|
||||
my ($one, $major, $minor) =
|
||||
( ($v >> 28) & 0xf,
|
||||
($v >> 20) & 0xff,
|
||||
($v >> 12) & 0xff );
|
||||
my $t = "DEPRECATEDIN_${one}_${major}_${minor}";
|
||||
push(@tag,"-");
|
||||
push(@tag,$t);
|
||||
$tag{$t}=($op eq '<' ? 1 : -1);
|
||||
print STDERR "DEBUG: $file: found tag $t = $tag{$t}\n" if $debug;
|
||||
} elsif (/^\#\s*ifndef\s+(.*)/) {
|
||||
push(@tag,"-");
|
||||
push(@tag,$1);
|
||||
$tag{$1}=-1;
|
||||
@@ -568,7 +520,7 @@ sub do_defs
|
||||
while($tag[$tag_i] ne "-") {
|
||||
if ($tag[$tag_i] eq "OPENSSL_NO_".$1) {
|
||||
$tag{$tag[$tag_i]}=2;
|
||||
print STDERR "DEBUG: $file: chaged tag $1 = 2\n" if $debug;
|
||||
print STDERR "DEBUG: $file: changed tag $1 = 2\n" if $debug;
|
||||
}
|
||||
$tag_i--;
|
||||
}
|
||||
@@ -651,6 +603,9 @@ sub do_defs
|
||||
, grep(!/^$/,
|
||||
map { $tag{"OPENSSL_USE_".$_} == 1 ? $_ : "" }
|
||||
@known_algorithms);
|
||||
push @current_algorithms,
|
||||
grep { /^DEPRECATEDIN_/ && $tag{$_} == 1 }
|
||||
@known_algorithms;
|
||||
$def .=
|
||||
"#INFO:"
|
||||
.join(',',@current_platforms).":"
|
||||
@@ -665,7 +620,7 @@ sub do_defs
|
||||
$def .= "int d2i_$3(void);";
|
||||
$def .= "int i2d_$3(void);";
|
||||
# Variant for platforms that do not
|
||||
# have to access globale variables
|
||||
# have to access global variables
|
||||
# in shared libraries through functions
|
||||
$def .=
|
||||
"#INFO:"
|
||||
@@ -677,7 +632,7 @@ sub do_defs
|
||||
.join(',',@current_platforms).":"
|
||||
.join(',',@current_algorithms).";";
|
||||
# Variant for platforms that have to
|
||||
# access globale variables in shared
|
||||
# access global variables in shared
|
||||
# libraries through functions
|
||||
&$make_variant("$2_it","$2_it",
|
||||
"EXPORT_VAR_AS_FUNCTION",
|
||||
@@ -689,7 +644,7 @@ sub do_defs
|
||||
$def .= "int $3_free(void);";
|
||||
$def .= "int $3_new(void);";
|
||||
# Variant for platforms that do not
|
||||
# have to access globale variables
|
||||
# have to access global variables
|
||||
# in shared libraries through functions
|
||||
$def .=
|
||||
"#INFO:"
|
||||
@@ -701,7 +656,7 @@ sub do_defs
|
||||
.join(',',@current_platforms).":"
|
||||
.join(',',@current_algorithms).";";
|
||||
# Variant for platforms that have to
|
||||
# access globale variables in shared
|
||||
# access global variables in shared
|
||||
# libraries through functions
|
||||
&$make_variant("$2_it","$2_it",
|
||||
"EXPORT_VAR_AS_FUNCTION",
|
||||
@@ -714,7 +669,7 @@ sub do_defs
|
||||
$def .= "int $1_free(void);";
|
||||
$def .= "int $1_new(void);";
|
||||
# Variant for platforms that do not
|
||||
# have to access globale variables
|
||||
# have to access global variables
|
||||
# in shared libraries through functions
|
||||
$def .=
|
||||
"#INFO:"
|
||||
@@ -726,7 +681,7 @@ sub do_defs
|
||||
.join(',',@current_platforms).":"
|
||||
.join(',',@current_algorithms).";";
|
||||
# Variant for platforms that have to
|
||||
# access globale variables in shared
|
||||
# access global variables in shared
|
||||
# libraries through functions
|
||||
&$make_variant("$1_it","$1_it",
|
||||
"EXPORT_VAR_AS_FUNCTION",
|
||||
@@ -736,7 +691,7 @@ sub do_defs
|
||||
$def .= "int d2i_$2(void);";
|
||||
$def .= "int i2d_$2(void);";
|
||||
# Variant for platforms that do not
|
||||
# have to access globale variables
|
||||
# have to access global variables
|
||||
# in shared libraries through functions
|
||||
$def .=
|
||||
"#INFO:"
|
||||
@@ -748,7 +703,7 @@ sub do_defs
|
||||
.join(',',@current_platforms).":"
|
||||
.join(',',@current_algorithms).";";
|
||||
# Variant for platforms that have to
|
||||
# access globale variables in shared
|
||||
# access global variables in shared
|
||||
# libraries through functions
|
||||
&$make_variant("$2_it","$2_it",
|
||||
"EXPORT_VAR_AS_FUNCTION",
|
||||
@@ -764,7 +719,7 @@ sub do_defs
|
||||
$def .= "int $2_free(void);";
|
||||
$def .= "int $2_new(void);";
|
||||
# Variant for platforms that do not
|
||||
# have to access globale variables
|
||||
# have to access global variables
|
||||
# in shared libraries through functions
|
||||
$def .=
|
||||
"#INFO:"
|
||||
@@ -776,7 +731,7 @@ sub do_defs
|
||||
.join(',',@current_platforms).":"
|
||||
.join(',',@current_algorithms).";";
|
||||
# Variant for platforms that have to
|
||||
# access globale variables in shared
|
||||
# access global variables in shared
|
||||
# libraries through functions
|
||||
&$make_variant("$2_it","$2_it",
|
||||
"EXPORT_VAR_AS_FUNCTION",
|
||||
@@ -784,7 +739,7 @@ sub do_defs
|
||||
next;
|
||||
} elsif (/^\s*DECLARE_ASN1_ITEM\s*\(\s*(\w*)\s*\)/) {
|
||||
# Variant for platforms that do not
|
||||
# have to access globale variables
|
||||
# have to access global variables
|
||||
# in shared libraries through functions
|
||||
$def .=
|
||||
"#INFO:"
|
||||
@@ -796,7 +751,7 @@ sub do_defs
|
||||
.join(',',@current_platforms).":"
|
||||
.join(',',@current_algorithms).";";
|
||||
# Variant for platforms that have to
|
||||
# access globale variables in shared
|
||||
# access global variables in shared
|
||||
# libraries through functions
|
||||
&$make_variant("$1_it","$1_it",
|
||||
"EXPORT_VAR_AS_FUNCTION",
|
||||
@@ -862,7 +817,7 @@ sub do_defs
|
||||
next;
|
||||
} elsif (/^OPENSSL_DECLARE_GLOBAL\s*\(\s*(\w*)\s*,\s*(\w*)\s*\)/) {
|
||||
# Variant for platforms that do not
|
||||
# have to access globale variables
|
||||
# have to access global variables
|
||||
# in shared libraries through functions
|
||||
$def .=
|
||||
"#INFO:"
|
||||
@@ -874,7 +829,7 @@ sub do_defs
|
||||
.join(',',@current_platforms).":"
|
||||
.join(',',@current_algorithms).";";
|
||||
# Variant for platforms that have to
|
||||
# access globale variables in shared
|
||||
# access global variables in shared
|
||||
# libraries through functions
|
||||
&$make_variant("_shadow_$2","_shadow_$2",
|
||||
"EXPORT_VAR_AS_FUNCTION",
|
||||
@@ -1125,7 +1080,7 @@ sub is_valid
|
||||
return 0;
|
||||
} else {
|
||||
# algorithms
|
||||
if ($disabled_algorithms{$keyword} == 1) { return 0;}
|
||||
if ($disabled_algorithms{$keyword}) { return 0;}
|
||||
|
||||
# Nothing recognise as true
|
||||
return 1;
|
||||
@@ -1200,9 +1155,6 @@ sub print_def_file
|
||||
my $prevnum = 0;
|
||||
my $symvtextcount = 0;
|
||||
|
||||
if ($W32)
|
||||
{ $libname.="32"; }
|
||||
|
||||
if ($W32)
|
||||
{
|
||||
print OUT <<"EOF";
|
||||
@@ -1219,6 +1171,7 @@ EOF
|
||||
elsif ($VMS)
|
||||
{
|
||||
print OUT <<"EOF";
|
||||
IDENTIFICATION=$version
|
||||
CASE_SENSITIVE=YES
|
||||
SYMBOL_VECTOR=(-
|
||||
EOF
|
||||
@@ -1621,8 +1574,7 @@ sub check_version_lte()
|
||||
if ($cvnums ne $tvnums) {
|
||||
die "Invalid version number: $testversion "
|
||||
."for current version $currversion\n"
|
||||
if (substr($cvnums, -1) < substr($tvnums, -1)
|
||||
|| substr($cvnums, 0, 4) ne substr($tvnums, 0, 4));
|
||||
if (substr($cvnums, 0, 4) ne substr($tvnums, 0, 4));
|
||||
return;
|
||||
}
|
||||
#If we get here then the base version (i.e. the numbers) are the same - they
|
||||
@@ -1675,7 +1627,7 @@ sub do_deprecated()
|
||||
{
|
||||
my ($decl, $plats, $algs) = @_;
|
||||
$decl =~ /^\s*(DEPRECATEDIN_\d+_\d+_\d+)\s*\((.*)\)\s*$/
|
||||
or die "Bad DEPRECTEDIN: $decl\n";
|
||||
or die "Bad DEPRECATEDIN: $decl\n";
|
||||
my $info1 .= "#INFO:";
|
||||
$info1 .= join(',', @{$plats}) . ":";
|
||||
my $info2 = $info1;
|
||||
|
||||
Regular → Executable
+619
-637
@@ -1,590 +1,562 @@
|
||||
#! /usr/bin/env perl
|
||||
# Copyright 1999-2016 The OpenSSL Project Authors. All Rights Reserved.
|
||||
# Copyright 1999-2018 The OpenSSL Project Authors. All Rights Reserved.
|
||||
#
|
||||
# Licensed under the OpenSSL license (the "License"). You may not use
|
||||
# this file except in compliance with the License. You can obtain a copy
|
||||
# in the file LICENSE in the source distribution or at
|
||||
# https://www.openssl.org/source/license.html
|
||||
|
||||
my $config = "crypto/err/openssl.ec";
|
||||
my $debug = 0;
|
||||
my $unref = 0;
|
||||
my $rebuild = 0;
|
||||
my $static = 1;
|
||||
my $recurse = 0;
|
||||
my $reindex = 0;
|
||||
my $dowrite = 0;
|
||||
my $staticloader = "";
|
||||
my @t = localtime();
|
||||
my $YEAR = @t[5] + 1900;
|
||||
use strict;
|
||||
use warnings;
|
||||
|
||||
my $pack_errcode;
|
||||
my $load_errcode;
|
||||
use lib ".";
|
||||
use configdata;
|
||||
|
||||
my $errcount;
|
||||
my $year = (localtime)[5] + 1900;
|
||||
my $config = "crypto/err/openssl.ec";
|
||||
my $debug = 0;
|
||||
my $internal = 0;
|
||||
my $nowrite = 0;
|
||||
my $rebuild = 0;
|
||||
my $reindex = 0;
|
||||
my $static = 0;
|
||||
my $unref = 0;
|
||||
my %modules = ();
|
||||
|
||||
while (@ARGV) {
|
||||
my $arg = $ARGV[0];
|
||||
if($arg eq "-conf") {
|
||||
shift @ARGV;
|
||||
$config = shift @ARGV;
|
||||
} elsif($arg eq "-hprefix") {
|
||||
shift @ARGV;
|
||||
$hprefix = shift @ARGV;
|
||||
} elsif($arg eq "-debug") {
|
||||
$debug = 1;
|
||||
$unref = 1;
|
||||
shift @ARGV;
|
||||
} elsif($arg eq "-rebuild") {
|
||||
$rebuild = 1;
|
||||
shift @ARGV;
|
||||
} elsif($arg eq "-recurse") {
|
||||
$recurse = 1;
|
||||
shift @ARGV;
|
||||
} elsif($arg eq "-reindex") {
|
||||
$reindex = 1;
|
||||
shift @ARGV;
|
||||
} elsif($arg eq "-nostatic") {
|
||||
$static = 0;
|
||||
shift @ARGV;
|
||||
} elsif($arg eq "-staticloader") {
|
||||
$staticloader = "static ";
|
||||
shift @ARGV;
|
||||
} elsif($arg eq "-unref") {
|
||||
$unref = 1;
|
||||
shift @ARGV;
|
||||
} elsif($arg eq "-write") {
|
||||
$dowrite = 1;
|
||||
shift @ARGV;
|
||||
} elsif($arg eq "-help" || $arg eq "-h" || $arg eq "-?" || $arg eq "--help") {
|
||||
print STDERR <<"EOF";
|
||||
mkerr.pl [options] ...
|
||||
my $errors = 0;
|
||||
my @t = localtime();
|
||||
my $YEAR = $t[5] + 1900;
|
||||
|
||||
sub phase
|
||||
{
|
||||
my $text = uc(shift);
|
||||
print STDERR "\n---\n$text\n" if $debug;
|
||||
}
|
||||
|
||||
sub help
|
||||
{
|
||||
print STDERR <<"EOF";
|
||||
mkerr.pl [options] [files...]
|
||||
|
||||
Options:
|
||||
|
||||
-conf F Use the config file F instead of the default one:
|
||||
crypto/err/openssl.ec
|
||||
-conf FILE Use the named config file FILE instead of the default.
|
||||
|
||||
-hprefix P Prepend the filenames in generated #include <header>
|
||||
statements with prefix P. Default: 'openssl/' (without
|
||||
the quotes, naturally)
|
||||
NOTE: not used any more because our include directory
|
||||
structure has changed.
|
||||
-debug Verbose output debugging on stderr.
|
||||
|
||||
-debug Turn on debugging verbose output on stderr.
|
||||
-internal Generate code that is to be built as part of OpenSSL itself.
|
||||
Also scans internal list of files.
|
||||
|
||||
-rebuild Rebuild all header and C source files, irrespective of the
|
||||
fact if any error or function codes have been added/removed.
|
||||
Default: only update files for libraries which saw change
|
||||
(of course, this requires '-write' as well, or no
|
||||
files will be touched!)
|
||||
-module M Only useful with -internal!
|
||||
Only write files for library module M. Whether files are
|
||||
actually written or not depends on other options, such as
|
||||
-rebuild.
|
||||
Note: this option is cumulative. If not given at all, all
|
||||
internal modules will be considered.
|
||||
|
||||
-recurse scan a preconfigured set of directories / files for error and
|
||||
function codes:
|
||||
(<crypto/*.c>, <crypto/*/*.c>, <ssl/*.c>, <apps/*.c>)
|
||||
When this option is NOT specified, the filelist is taken from
|
||||
the commandline instead. Here, wildcards may be embedded. (Be
|
||||
sure to escape those to prevent the shell from expanding them
|
||||
for you when you wish mkerr.pl to do so instead.)
|
||||
Default: take file list to scan from the command line.
|
||||
-nowrite Do not write the header/source files, even if changed.
|
||||
|
||||
-reindex Discard the numeric values previously assigned to the error
|
||||
and function codes as extracted from the scanned header files;
|
||||
instead renumber all of them starting from 100. (Note that
|
||||
the numbers assigned through 'R' records in the config file
|
||||
remain intact.)
|
||||
Default: keep previously assigned numbers. (You are warned
|
||||
when collisions are detected.)
|
||||
-rebuild Rebuild all header and C source files, even if there
|
||||
were no changes.
|
||||
|
||||
-nostatic Generates a different source code, where these additional
|
||||
functions are generated for each library specified in the
|
||||
config file:
|
||||
void ERR_load_<LIB>_strings(void);
|
||||
void ERR_unload_<LIB>_strings(void);
|
||||
void ERR_<LIB>_error(int f, int r, char *fn, int ln);
|
||||
#define <LIB>err(f,r) ERR_<LIB>_error(f,r,OPENSSL_FILE,OPENSSL_LINE)
|
||||
while the code facilitates the use of these in an environment
|
||||
where the error support routines are dynamically loaded at
|
||||
runtime.
|
||||
Default: 'static' code generation.
|
||||
-reindex Ignore previously assigned values (except for R records in
|
||||
the config file) and renumber everything starting at 100.
|
||||
|
||||
-staticloader Prefix generated functions with the 'static' scope modifier.
|
||||
Default: don't write any scope modifier prefix.
|
||||
-static Make the load/unload functions static.
|
||||
|
||||
-unref Print out unreferenced function and reason codes.
|
||||
-unref List all unreferenced function and reason codes on stderr;
|
||||
implies -nowrite.
|
||||
|
||||
-write Actually (over)write the generated code to the header and C
|
||||
source files as assigned to each library through the config
|
||||
file.
|
||||
Default: don't write.
|
||||
-help Show this help text.
|
||||
|
||||
-help / -h / -? / --help Show this help text.
|
||||
|
||||
... Additional arguments are added to the file list to scan,
|
||||
assuming '-recurse' was NOT specified on the command line.
|
||||
... Additional arguments are added to the file list to scan,
|
||||
if '-internal' was NOT specified on the command line.
|
||||
|
||||
EOF
|
||||
exit 1;
|
||||
} else {
|
||||
last;
|
||||
}
|
||||
}
|
||||
|
||||
if($recurse) {
|
||||
@source = ( <crypto/*.c>, <crypto/*/*.c>, <ssl/*.c>, <ssl/*/*.c> )
|
||||
while ( @ARGV ) {
|
||||
my $arg = $ARGV[0];
|
||||
last unless $arg =~ /-.*/;
|
||||
$arg = $1 if $arg =~ /-(-.*)/;
|
||||
if ( $arg eq "-conf" ) {
|
||||
$config = $ARGV[1];
|
||||
shift @ARGV;
|
||||
} elsif ( $arg eq "-debug" ) {
|
||||
$debug = 1;
|
||||
$unref = 1;
|
||||
} elsif ( $arg eq "-internal" ) {
|
||||
$internal = 1;
|
||||
} elsif ( $arg eq "-nowrite" ) {
|
||||
$nowrite = 1;
|
||||
} elsif ( $arg eq "-rebuild" ) {
|
||||
$rebuild = 1;
|
||||
} elsif ( $arg eq "-reindex" ) {
|
||||
$reindex = 1;
|
||||
} elsif ( $arg eq "-static" ) {
|
||||
$static = 1;
|
||||
} elsif ( $arg eq "-unref" ) {
|
||||
$unref = 1;
|
||||
$nowrite = 1;
|
||||
} elsif ( $arg eq "-module" ) {
|
||||
shift @ARGV;
|
||||
$modules{uc $ARGV[0]} = 1;
|
||||
} elsif ( $arg =~ /-*h(elp)?/ ) {
|
||||
&help();
|
||||
exit;
|
||||
} elsif ( $arg =~ /-.*/ ) {
|
||||
die "Unknown option $arg; use -h for help.\n";
|
||||
}
|
||||
shift @ARGV;
|
||||
}
|
||||
|
||||
my @source;
|
||||
if ( $internal ) {
|
||||
die "Cannot mix -internal and -static\n" if $static;
|
||||
die "Extra parameters given.\n" if @ARGV;
|
||||
@source = ( glob('crypto/*.c'), glob('crypto/*/*.c'),
|
||||
glob('ssl/*.c'), glob('ssl/*/*.c') );
|
||||
} else {
|
||||
@source = @ARGV;
|
||||
die "-module isn't useful without -internal\n" if scalar keys %modules > 0;
|
||||
@source = @ARGV;
|
||||
}
|
||||
|
||||
# Read in the config file
|
||||
# Data parsed out of the config and state files.
|
||||
my %hinc; # lib -> header
|
||||
my %libinc; # header -> lib
|
||||
my %cskip; # error_file -> lib
|
||||
my %errorfile; # lib -> error file name
|
||||
my %fmax; # lib -> max assigned function code
|
||||
my %rmax; # lib -> max assigned reason code
|
||||
my %fassigned; # lib -> colon-separated list of assigned function codes
|
||||
my %rassigned; # lib -> colon-separated list of assigned reason codes
|
||||
my %fnew; # lib -> count of new function codes
|
||||
my %rnew; # lib -> count of new reason codes
|
||||
my %rextra; # "extra" reason code -> lib
|
||||
my %rcodes; # reason-name -> value
|
||||
my %ftrans; # old name -> #define-friendly name (all caps)
|
||||
my %fcodes; # function-name -> value
|
||||
my $statefile; # state file with assigned reason and function codes
|
||||
my %strings; # define -> text
|
||||
|
||||
open(IN, "<$config") || die "Can't open config file $config";
|
||||
|
||||
# Parse config file
|
||||
|
||||
while(<IN>)
|
||||
{
|
||||
if(/^L\s+(\S+)\s+(\S+)\s+(\S+)/) {
|
||||
$hinc{$1} = $2;
|
||||
$libinc{$2} = $1;
|
||||
$cskip{$3} = $1;
|
||||
if($3 ne "NONE") {
|
||||
$csrc{$1} = $3;
|
||||
$fmax{$1} = 100;
|
||||
$rmax{$1} = 100;
|
||||
$fassigned{$1} = ":";
|
||||
$rassigned{$1} = ":";
|
||||
$fnew{$1} = 0;
|
||||
$rnew{$1} = 0;
|
||||
}
|
||||
} elsif (/^F\s+(\S+)/) {
|
||||
# Add extra function with $1
|
||||
} elsif (/^R\s+(\S+)\s+(\S+)/) {
|
||||
$rextra{$1} = $2;
|
||||
$rcodes{$1} = $2;
|
||||
}
|
||||
# Read and parse the config file
|
||||
open(IN, "$config") || die "Can't open config file $config, $!,";
|
||||
while ( <IN> ) {
|
||||
next if /^#/ || /^$/;
|
||||
if ( /^L\s+(\S+)\s+(\S+)\s+(\S+)/ ) {
|
||||
my $lib = $1;
|
||||
my $hdr = $2;
|
||||
my $err = $3;
|
||||
$hinc{$lib} = $hdr;
|
||||
$libinc{$hdr} = $lib;
|
||||
$cskip{$err} = $lib;
|
||||
next if $err eq 'NONE';
|
||||
$errorfile{$lib} = $err;
|
||||
$fmax{$lib} = 100;
|
||||
$rmax{$lib} = 100;
|
||||
$fassigned{$lib} = ":";
|
||||
$rassigned{$lib} = ":";
|
||||
$fnew{$lib} = 0;
|
||||
$rnew{$lib} = 0;
|
||||
} elsif ( /^R\s+(\S+)\s+(\S+)/ ) {
|
||||
$rextra{$1} = $2;
|
||||
$rcodes{$1} = $2;
|
||||
} elsif ( /^S\s+(\S+)/ ) {
|
||||
$statefile = $1;
|
||||
} else {
|
||||
die "Illegal config line $_\n";
|
||||
}
|
||||
}
|
||||
|
||||
close IN;
|
||||
|
||||
# Scan each header file in turn and make a list of error codes
|
||||
# and function names
|
||||
|
||||
while (($hdr, $lib) = each %libinc)
|
||||
{
|
||||
next if($hdr eq "NONE");
|
||||
print STDERR "Scanning header file $hdr\n" if $debug;
|
||||
my $line = "", $def= "", $linenr = 0, $gotfile = 0, $cpp = 0;
|
||||
if (open(IN, "<$hdr")) {
|
||||
$gotfile = 1;
|
||||
while(<IN>) {
|
||||
$linenr++;
|
||||
print STDERR "line: $linenr\r" if $debug;
|
||||
|
||||
last if(/BEGIN\s+ERROR\s+CODES/);
|
||||
if ($line ne '') {
|
||||
$_ = $line . $_;
|
||||
$line = '';
|
||||
}
|
||||
|
||||
if (/\\$/) {
|
||||
$line = $_;
|
||||
next;
|
||||
}
|
||||
|
||||
if(/\/\*/) {
|
||||
if (not /\*\//) { # multiline comment...
|
||||
$line = $_; # ... just accumulate
|
||||
next;
|
||||
} else {
|
||||
s/\/\*.*?\*\///gs; # wipe it
|
||||
}
|
||||
}
|
||||
|
||||
if ($cpp) {
|
||||
$cpp++ if /^#\s*if/;
|
||||
$cpp-- if /^#\s*endif/;
|
||||
next;
|
||||
}
|
||||
$cpp = 1 if /^#.*ifdef.*cplusplus/; # skip "C" declaration
|
||||
|
||||
next if (/^\#/); # skip preprocessor directives
|
||||
|
||||
s/{[^{}]*}//gs; # ignore {} blocks
|
||||
|
||||
if (/\{|\/\*/) { # Add a } so editor works...
|
||||
$line = $_;
|
||||
} else {
|
||||
$def .= $_;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
print STDERR " \r" if $debug;
|
||||
$defnr = 0;
|
||||
# Delete any DECLARE_ macros
|
||||
$def =~ s/DECLARE_\w+\([\w,\s]+\)//gs;
|
||||
foreach (split /;/, $def) {
|
||||
$defnr++;
|
||||
print STDERR "def: $defnr\r" if $debug;
|
||||
|
||||
# The goal is to collect function names from function declarations.
|
||||
|
||||
s/^[\n\s]*//g;
|
||||
s/[\n\s]*$//g;
|
||||
|
||||
# Skip over recognized non-function declarations
|
||||
next if(/typedef\W/ or /DECLARE_STACK_OF/ or /TYPEDEF_.*_OF/);
|
||||
|
||||
# Remove STACK_OF(foo)
|
||||
s/STACK_OF\(\w+\)/void/;
|
||||
|
||||
# Reduce argument lists to empty ()
|
||||
# fold round brackets recursively: (t(*v)(t),t) -> (t{}{},t) -> {}
|
||||
while(/\(.*\)/s) {
|
||||
s/\([^\(\)]+\)/\{\}/gs;
|
||||
s/\(\s*\*\s*(\w+)\s*\{\}\s*\)/$1/gs; #(*f{}) -> f
|
||||
}
|
||||
# pretend as we didn't use curly braces: {} -> ()
|
||||
s/\{\}/\(\)/gs;
|
||||
|
||||
if (/(\w+)\s*\(\).*/s) { # first token prior [first] () is
|
||||
my $name = $1; # a function name!
|
||||
$name =~ tr/[a-z]/[A-Z]/;
|
||||
$ftrans{$name} = $1;
|
||||
} elsif (/[\(\)]/ and not (/=/)) {
|
||||
print STDERR "Header $hdr: cannot parse: $_;\n";
|
||||
}
|
||||
}
|
||||
|
||||
print STDERR " \r" if $debug;
|
||||
|
||||
next if $reindex;
|
||||
|
||||
# Scan function and reason codes and store them: keep a note of the
|
||||
# maximum code used.
|
||||
|
||||
if ($gotfile) {
|
||||
while(<IN>) {
|
||||
if(/^\#\s*define\s+(\S+)\s+(\S+)/) {
|
||||
$name = $1;
|
||||
$code = $2;
|
||||
next if $name =~ /^${lib}err/;
|
||||
unless($name =~ /^${lib}_([RF])_(\w+)$/) {
|
||||
print STDERR "Invalid error code $name\n";
|
||||
next;
|
||||
}
|
||||
if($1 eq "R") {
|
||||
$rcodes{$name} = $code;
|
||||
if ($rassigned{$lib} =~ /:$code:/) {
|
||||
print STDERR "!! ERROR: $lib reason code $code assigned twice (collision at $name)\n";
|
||||
++$errcount;
|
||||
}
|
||||
$rassigned{$lib} .= "$code:";
|
||||
if(!(exists $rextra{$name}) &&
|
||||
($code > $rmax{$lib}) ) {
|
||||
$rmax{$lib} = $code;
|
||||
}
|
||||
} else {
|
||||
if ($fassigned{$lib} =~ /:$code:/) {
|
||||
print STDERR "!! ERROR: $lib function code $code assigned twice (collision at $name)\n";
|
||||
++$errcount;
|
||||
}
|
||||
$fassigned{$lib} .= "$code:";
|
||||
if($code > $fmax{$lib}) {
|
||||
$fmax{$lib} = $code;
|
||||
}
|
||||
$fcodes{$name} = $code;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if ($debug) {
|
||||
if (defined($fmax{$lib})) {
|
||||
print STDERR "Max function code fmax" . "{" . "$lib" . "} = $fmax{$lib}\n";
|
||||
$fassigned{$lib} =~ m/^:(.*):$/;
|
||||
@fassigned = sort {$a <=> $b} split(":", $1);
|
||||
print STDERR " @fassigned\n";
|
||||
}
|
||||
if (defined($rmax{$lib})) {
|
||||
print STDERR "Max reason code rmax" . "{" . "$lib" . "} = $rmax{$lib}\n";
|
||||
$rassigned{$lib} =~ m/^:(.*):$/;
|
||||
@rassigned = sort {$a <=> $b} split(":", $1);
|
||||
print STDERR " @rassigned\n";
|
||||
}
|
||||
}
|
||||
|
||||
if ($lib eq "SSL") {
|
||||
if ($rmax{$lib} >= 1000) {
|
||||
print STDERR "!! ERROR: SSL error codes 1000+ are reserved for alerts.\n";
|
||||
print STDERR "!! Any new alerts must be added to $config.\n";
|
||||
++$errcount;
|
||||
print STDERR "\n";
|
||||
}
|
||||
}
|
||||
close IN;
|
||||
if ( ! $statefile ) {
|
||||
$statefile = $config;
|
||||
$statefile =~ s/.ec/.txt/;
|
||||
}
|
||||
|
||||
# The statefile has all the previous assignments.
|
||||
&phase("Reading state");
|
||||
my $skippedstate = 0;
|
||||
if ( ! $reindex && $statefile ) {
|
||||
open(STATE, "<$statefile") || die "Can't open $statefile, $!";
|
||||
|
||||
# Scan function and reason codes and store them: keep a note of the
|
||||
# maximum code used.
|
||||
while ( <STATE> ) {
|
||||
next if /^#/ || /^$/;
|
||||
my $name;
|
||||
my $code;
|
||||
if ( /^(.+):(\d+):\\$/ ) {
|
||||
$name = $1;
|
||||
$code = $2;
|
||||
my $next = <STATE>;
|
||||
$next =~ s/^\s*(.*)\s*$/$1/;
|
||||
die "Duplicate define $name" if exists $strings{$name};
|
||||
$strings{$name} = $next;
|
||||
} elsif ( /^(\S+):(\d+):(.*)$/ ) {
|
||||
$name = $1;
|
||||
$code = $2;
|
||||
die "Duplicate define $name" if exists $strings{$name};
|
||||
$strings{$name} = $3;
|
||||
} else {
|
||||
die "Bad line in $statefile:\n$_\n";
|
||||
}
|
||||
my $lib = $name;
|
||||
$lib =~ s/^((?:OSSL_|OPENSSL_)?[^_]{2,}).*$/$1/;
|
||||
$lib = "SSL" if $lib =~ /TLS/;
|
||||
if ( !defined $errorfile{$lib} ) {
|
||||
print "Skipping $_";
|
||||
$skippedstate++;
|
||||
next;
|
||||
}
|
||||
if ( $name =~ /^(?:OSSL_|OPENSSL_)?[A-Z0-9]{2,}_R_/ ) {
|
||||
die "$lib reason code $code collision at $name\n"
|
||||
if $rassigned{$lib} =~ /:$code:/;
|
||||
$rassigned{$lib} .= "$code:";
|
||||
if ( !exists $rextra{$name} ) {
|
||||
$rmax{$lib} = $code if $code > $rmax{$lib};
|
||||
}
|
||||
$rcodes{$name} = $code;
|
||||
} elsif ( $name =~ /^(?:OSSL_|OPENSSL_)?[A-Z0-9]{2,}_F_/ ) {
|
||||
die "$lib function code $code collision at $name\n"
|
||||
if $fassigned{$lib} =~ /:$code:/;
|
||||
$fassigned{$lib} .= "$code:";
|
||||
$fmax{$lib} = $code if $code > $fmax{$lib};
|
||||
$fcodes{$name} = $code;
|
||||
} else {
|
||||
die "Bad line in $statefile:\n$_\n";
|
||||
}
|
||||
}
|
||||
close(STATE);
|
||||
|
||||
if ( $debug ) {
|
||||
foreach my $lib ( sort keys %rmax ) {
|
||||
print STDERR "Reason codes for ${lib}:\n";
|
||||
if ( $rassigned{$lib} =~ m/^:(.*):$/ ) {
|
||||
my @rassigned = sort { $a <=> $b } split( ":", $1 );
|
||||
print STDERR " ", join(' ', @rassigned), "\n";
|
||||
} else {
|
||||
print STDERR " --none--\n";
|
||||
}
|
||||
}
|
||||
print STDERR "\n";
|
||||
foreach my $lib ( sort keys %fmax ) {
|
||||
print STDERR "Function codes for ${lib}:\n";
|
||||
if ( $fassigned{$lib} =~ m/^:(.*):$/ ) {
|
||||
my @fassigned = sort { $a <=> $b } split( ":", $1 );
|
||||
print STDERR " ", join(' ', @fassigned), "\n";
|
||||
} else {
|
||||
print STDERR " --none--\n";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
# Scan each header file and make a list of error codes
|
||||
# and function names
|
||||
&phase("Scanning headers");
|
||||
while ( ( my $hdr, my $lib ) = each %libinc ) {
|
||||
next if $hdr eq "NONE";
|
||||
print STDERR " ." if $debug;
|
||||
my $line = "";
|
||||
my $def = "";
|
||||
my $linenr = 0;
|
||||
my $cpp = 0;
|
||||
|
||||
open(IN, "<$hdr") || die "Can't open $hdr, $!,";
|
||||
while ( <IN> ) {
|
||||
$linenr++;
|
||||
|
||||
if ( $line ne '' ) {
|
||||
$_ = $line . $_;
|
||||
$line = '';
|
||||
}
|
||||
|
||||
if ( /\\$/ ) {
|
||||
$line = $_;
|
||||
next;
|
||||
}
|
||||
|
||||
if ( /\/\*/ ) {
|
||||
if ( not /\*\// ) { # multiline comment...
|
||||
$line = $_; # ... just accumulate
|
||||
next;
|
||||
} else {
|
||||
s/\/\*.*?\*\///gs; # wipe it
|
||||
}
|
||||
}
|
||||
|
||||
if ( $cpp ) {
|
||||
$cpp++ if /^#\s*if/;
|
||||
$cpp-- if /^#\s*endif/;
|
||||
next;
|
||||
}
|
||||
$cpp = 1 if /^#.*ifdef.*cplusplus/; # skip "C" declaration
|
||||
|
||||
next if /^\#/; # skip preprocessor directives
|
||||
|
||||
s/{[^{}]*}//gs; # ignore {} blocks
|
||||
|
||||
if ( /\{|\/\*/ ) { # Add a so editor works...
|
||||
$line = $_;
|
||||
} else {
|
||||
$def .= $_;
|
||||
}
|
||||
}
|
||||
|
||||
# Delete any DECLARE_ macros
|
||||
my $defnr = 0;
|
||||
$def =~ s/DECLARE_\w+\([\w,\s]+\)//gs;
|
||||
foreach ( split /;/, $def ) {
|
||||
$defnr++;
|
||||
# The goal is to collect function names from function declarations.
|
||||
|
||||
s/^[\n\s]*//g;
|
||||
s/[\n\s]*$//g;
|
||||
|
||||
# Skip over recognized non-function declarations
|
||||
next if /typedef\W/ or /DECLARE_STACK_OF/ or /TYPEDEF_.*_OF/;
|
||||
|
||||
# Remove STACK_OF(foo)
|
||||
s/STACK_OF\(\w+\)/void/;
|
||||
|
||||
# Reduce argument lists to empty ()
|
||||
# fold round brackets recursively: (t(*v)(t),t) -> (t{}{},t) -> {}
|
||||
while ( /\(.*\)/s ) {
|
||||
s/\([^\(\)]+\)/\{\}/gs;
|
||||
s/\(\s*\*\s*(\w+)\s*\{\}\s*\)/$1/gs; #(*f{}) -> f
|
||||
}
|
||||
|
||||
# pretend as we didn't use curly braces: {} -> ()
|
||||
s/\{\}/\(\)/gs;
|
||||
|
||||
# Last token just before the first () is a function name.
|
||||
if ( /(\w+)\s*\(\).*/s ) {
|
||||
my $name = $1;
|
||||
$name =~ tr/[a-z]/[A-Z]/;
|
||||
$ftrans{$name} = $1;
|
||||
} elsif ( /[\(\)]/ and not(/=/) ) {
|
||||
print STDERR "Header $hdr: cannot parse: $_;\n";
|
||||
}
|
||||
}
|
||||
|
||||
next if $reindex;
|
||||
|
||||
if ( $lib eq "SSL" && $rmax{$lib} >= 1000 ) {
|
||||
print STDERR "SSL error codes 1000+ are reserved for alerts.\n";
|
||||
print STDERR "Any new alerts must be added to $config.\n";
|
||||
$errors++;
|
||||
}
|
||||
close IN;
|
||||
}
|
||||
print STDERR "\n" if $debug;
|
||||
|
||||
# Scan each C source file and look for function and reason codes
|
||||
# This is done by looking for strings that "look like" function or
|
||||
# reason codes: basically anything consisting of all upper case and
|
||||
# numerics which has _F_ or _R_ in it and which has the name of an
|
||||
# error library at the start. This seems to work fine except for the
|
||||
# error library at the start. This seems to work fine except for the
|
||||
# oddly named structure BIO_F_CTX which needs to be ignored.
|
||||
# If a code doesn't exist in list compiled from headers then mark it
|
||||
# with the value "X" as a place holder to give it a value later.
|
||||
# Store all function and reason codes found in %ufcodes and %urcodes
|
||||
# Store all function and reason codes found in %usedfuncs and %usedreasons
|
||||
# so all those unreferenced can be printed out.
|
||||
&phase("Scanning source");
|
||||
my %usedfuncs;
|
||||
my %usedreasons;
|
||||
foreach my $file ( @source ) {
|
||||
# Don't parse the error source file.
|
||||
next if exists $cskip{$file};
|
||||
open( IN, "<$file" ) || die "Can't open $file, $!,";
|
||||
my $func;
|
||||
my $linenr = 0;
|
||||
print STDERR "$file:\n" if $debug;
|
||||
while ( <IN> ) {
|
||||
|
||||
# skip obsoleted source files entirely!
|
||||
last if /^#error\s+obsolete/;
|
||||
$linenr++;
|
||||
if ( !/;$/ && /^\**([a-zA-Z_].*[\s*])?([A-Za-z_0-9]+)\(.*([),]|$)/ ) {
|
||||
/^([^()]*(\([^()]*\)[^()]*)*)\(/;
|
||||
$1 =~ /([A-Za-z_0-9]*)$/;
|
||||
$func = $1;
|
||||
}
|
||||
|
||||
foreach $file (@source) {
|
||||
# Don't parse the error source file.
|
||||
next if exists $cskip{$file};
|
||||
print STDERR "File loaded: ".$file."\r" if $debug;
|
||||
open(IN, "<$file") || die "Can't open source file $file\n";
|
||||
my $func;
|
||||
my $linenr = 0;
|
||||
while(<IN>) {
|
||||
# skip obsoleted source files entirely!
|
||||
last if(/^#error\s+obsolete/);
|
||||
$linenr++;
|
||||
if (!/;$/ && /^\**([a-zA-Z_].*[\s*])?([A-Za-z_0-9]+)\(.*([),]|$)/)
|
||||
{
|
||||
/^([^()]*(\([^()]*\)[^()]*)*)\(/;
|
||||
$1 =~ /([A-Za-z_0-9]*)$/;
|
||||
$func = $1;
|
||||
}
|
||||
|
||||
if(/(([A-Z0-9]+)_F_([A-Z0-9_]+))/) {
|
||||
next unless exists $csrc{$2};
|
||||
next if($1 eq "BIO_F_BUFFER_CTX");
|
||||
$ufcodes{$1} = 1;
|
||||
if(!exists $fcodes{$1}) {
|
||||
$fcodes{$1} = "X";
|
||||
$fnew{$2}++;
|
||||
}
|
||||
$ftrans{$3} = $func unless exists $ftrans{$3};
|
||||
if (uc $func ne $3) {
|
||||
print STDERR "ERROR: mismatch $file:$linenr $func:$3\n";
|
||||
$errcount++;
|
||||
if ( /(((?:OSSL_|OPENSSL_)?[A-Z0-9]{2,})_F_([A-Z0-9_]+))/ ) {
|
||||
next unless exists $errorfile{$2};
|
||||
next if $1 eq "BIO_F_BUFFER_CTX";
|
||||
$usedfuncs{$1} = 1;
|
||||
if ( !exists $fcodes{$1} ) {
|
||||
print STDERR " New function $1\n" if $debug;
|
||||
$fcodes{$1} = "X";
|
||||
$fnew{$2}++;
|
||||
}
|
||||
print STDERR "Function: $1\t= $fcodes{$1} (lib: $2, name: $3)\n" if $debug;
|
||||
}
|
||||
if(/(([A-Z0-9]+)_R_[A-Z0-9_]+)/) {
|
||||
next unless exists $csrc{$2};
|
||||
$urcodes{$1} = 1;
|
||||
if(!exists $rcodes{$1}) {
|
||||
$rcodes{$1} = "X";
|
||||
$rnew{$2}++;
|
||||
}
|
||||
print STDERR "Reason: $1\t= $rcodes{$1} (lib: $2)\n" if $debug;
|
||||
}
|
||||
}
|
||||
close IN;
|
||||
$ftrans{$3} = $func unless exists $ftrans{$3};
|
||||
if ( uc($func) ne $3 ) {
|
||||
print STDERR "ERROR: mismatch $file:$linenr $func:$3\n";
|
||||
$errors++;
|
||||
}
|
||||
print STDERR " Function $1 = $fcodes{$1}\n"
|
||||
if $debug;
|
||||
}
|
||||
if ( /(((?:OSSL_|OPENSSL_)?[A-Z0-9]{2,})_R_[A-Z0-9_]+)/ ) {
|
||||
next unless exists $errorfile{$2};
|
||||
$usedreasons{$1} = 1;
|
||||
if ( !exists $rcodes{$1} ) {
|
||||
print STDERR " New reason $1\n" if $debug;
|
||||
$rcodes{$1} = "X";
|
||||
$rnew{$2}++;
|
||||
}
|
||||
print STDERR " Reason $1 = $rcodes{$1}\n" if $debug;
|
||||
}
|
||||
}
|
||||
close IN;
|
||||
}
|
||||
print STDERR " \n" if $debug;
|
||||
print STDERR "\n" if $debug;
|
||||
|
||||
# Now process each library in turn.
|
||||
&phase("Writing files");
|
||||
my $newstate = 0;
|
||||
foreach my $lib ( keys %errorfile ) {
|
||||
if ( ! $fnew{$lib} && ! $rnew{$lib} ) {
|
||||
next unless $rebuild;
|
||||
}
|
||||
next if scalar keys %modules > 0 && !$modules{$lib};
|
||||
next if $nowrite;
|
||||
print STDERR "$lib: $fnew{$lib} new functions\n" if $fnew{$lib};
|
||||
print STDERR "$lib: $rnew{$lib} new reasons\n" if $rnew{$lib};
|
||||
$newstate = 1;
|
||||
|
||||
foreach $lib (keys %csrc)
|
||||
{
|
||||
my $hfile = $hinc{$lib};
|
||||
my $cfile = $csrc{$lib};
|
||||
if(!$fnew{$lib} && !$rnew{$lib}) {
|
||||
next unless $rebuild;
|
||||
} else {
|
||||
print STDERR "$lib:\t\t$fnew{$lib} New Functions,";
|
||||
print STDERR " $rnew{$lib} New Reasons.\n";
|
||||
next unless $dowrite;
|
||||
}
|
||||
# If we get here then we have some new error codes so we
|
||||
# need to rebuild the header file and C file.
|
||||
|
||||
# If we get here then we have some new error codes so we
|
||||
# need to rebuild the header file and C file.
|
||||
# Make a sorted list of error and reason codes for later use.
|
||||
my @function = sort grep( /^${lib}_/, keys %fcodes );
|
||||
my @reasons = sort grep( /^${lib}_/, keys %rcodes );
|
||||
|
||||
# Make a sorted list of error and reason codes for later use.
|
||||
# indent level for innermost preprocessor lines
|
||||
my $indent = " ";
|
||||
|
||||
my @function = sort grep(/^${lib}_/,keys %fcodes);
|
||||
my @reasons = sort grep(/^${lib}_/,keys %rcodes);
|
||||
# Rewrite the header file
|
||||
|
||||
# Rewrite the header file
|
||||
|
||||
$cpp = 0;
|
||||
$cplusplus = 0;
|
||||
if (open(IN, "<$hfile")) {
|
||||
# Copy across the old file
|
||||
while(<IN>) {
|
||||
$cplusplus = $cpp if /^#.*ifdef.*cplusplus/;
|
||||
$cpp++ if /^#\s*if/;
|
||||
$cpp-- if /^#\s*endif/;
|
||||
push @out, $_;
|
||||
last if (/BEGIN ERROR CODES/);
|
||||
}
|
||||
close IN;
|
||||
} else {
|
||||
$cpp = 1;
|
||||
$cplusplus = 1;
|
||||
push @out,
|
||||
"/*\n",
|
||||
" * Copyright 1995-$YEAR The OpenSSL Project Authors. All Rights Reserved.\n",
|
||||
" *\n",
|
||||
" * Licensed under the OpenSSL license (the \"License\"). You may not use\n",
|
||||
" * this file except in compliance with the License. You can obtain a copy\n",
|
||||
" * in the file LICENSE in the source distribution or at\n",
|
||||
" * https://www.openssl.org/source/license.html\n",
|
||||
" */\n",
|
||||
"\n",
|
||||
"#ifndef HEADER_${lib}_ERR_H\n",
|
||||
"# define HEADER_${lib}_ERR_H\n",
|
||||
"\n",
|
||||
"# ifdef __cplusplus\n",
|
||||
"extern \"C\" {\n",
|
||||
"# endif\n",
|
||||
"\n",
|
||||
"/* BEGIN ERROR CODES */\n";
|
||||
}
|
||||
open (OUT, ">$hfile") || die "Can't Open File $hfile for writing\n";
|
||||
|
||||
print OUT @out;
|
||||
undef @out;
|
||||
print OUT <<"EOF";
|
||||
my $hfile = $hinc{$lib};
|
||||
$hfile =~ s/.h$/err.h/ if $internal;
|
||||
open( OUT, ">$hfile" ) || die "Can't write to $hfile, $!,";
|
||||
print OUT <<"EOF";
|
||||
/*
|
||||
* The following lines are auto generated by the script mkerr.pl. Any changes
|
||||
* made after this point may be overwritten when the script is next run.
|
||||
* Generated by util/mkerr.pl DO NOT EDIT
|
||||
* Copyright 1995-$YEAR The OpenSSL Project Authors. All Rights Reserved.
|
||||
*
|
||||
* Licensed under the OpenSSL license (the \"License\"). You may not use
|
||||
* this file except in compliance with the License. You can obtain a copy
|
||||
* in the file LICENSE in the source distribution or at
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
EOF
|
||||
if($static) {
|
||||
print OUT <<"EOF";
|
||||
${staticloader}int ERR_load_${lib}_strings(void);
|
||||
#ifndef HEADER_${lib}ERR_H
|
||||
# define HEADER_${lib}ERR_H
|
||||
|
||||
EOF
|
||||
} else {
|
||||
print OUT <<"EOF";
|
||||
${staticloader}int ERR_load_${lib}_strings(void);
|
||||
${staticloader}void ERR_unload_${lib}_strings(void);
|
||||
${staticloader}void ERR_${lib}_error(int function, int reason, char *file, int line);
|
||||
# define ${lib}err(f,r) ERR_${lib}_error((f),(r),OPENSSL_FILE,OPENSSL_LINE)
|
||||
if ( $internal ) {
|
||||
# Declare the load function because the generate C file
|
||||
# includes "fooerr.h" not "foo.h"
|
||||
if ($lib ne "SSL" && $lib ne "ASYNC"
|
||||
&& grep { $lib eq uc $_ } @disablables) {
|
||||
print OUT <<"EOF";
|
||||
# include <openssl/opensslconf.h>
|
||||
|
||||
# ifndef OPENSSL_NO_${lib}
|
||||
|
||||
EOF
|
||||
}
|
||||
print OUT <<"EOF";
|
||||
/* Error codes for the $lib functions. */
|
||||
|
||||
/* Function codes. */
|
||||
$indent = " ";
|
||||
}
|
||||
print OUT <<"EOF";
|
||||
#${indent}ifdef __cplusplus
|
||||
extern \"C\"
|
||||
#${indent}endif
|
||||
int ERR_load_${lib}_strings(void);
|
||||
EOF
|
||||
|
||||
foreach $i (@function) {
|
||||
$z=48 - length($i);
|
||||
if($fcodes{$i} eq "X") {
|
||||
$fassigned{$lib} =~ m/^:([^:]*):/;
|
||||
$findcode = $1;
|
||||
if (!defined($findcode)) {
|
||||
$findcode = $fmax{$lib};
|
||||
}
|
||||
while ($fassigned{$lib} =~ m/:$findcode:/) {
|
||||
$findcode++;
|
||||
}
|
||||
$fcodes{$i} = $findcode;
|
||||
$fassigned{$lib} .= "$findcode:";
|
||||
print STDERR "New Function code $i\n" if $debug;
|
||||
}
|
||||
printf OUT "# define $i%s $fcodes{$i}\n"," " x $z;
|
||||
}
|
||||
|
||||
print OUT "\n/* Reason codes. */\n";
|
||||
|
||||
foreach $i (@reasons) {
|
||||
$z=48 - length($i);
|
||||
if($rcodes{$i} eq "X") {
|
||||
$rassigned{$lib} =~ m/^:([^:]*):/;
|
||||
$findcode = $1;
|
||||
if (!defined($findcode)) {
|
||||
$findcode = $rmax{$lib};
|
||||
}
|
||||
while ($rassigned{$lib} =~ m/:$findcode:/) {
|
||||
$findcode++;
|
||||
}
|
||||
$rcodes{$i} = $findcode;
|
||||
$rassigned{$lib} .= "$findcode:";
|
||||
print STDERR "New Reason code $i\n" if $debug;
|
||||
}
|
||||
printf OUT "# define $i%s $rcodes{$i}\n"," " x $z;
|
||||
}
|
||||
print OUT <<"EOF";
|
||||
} else {
|
||||
print OUT <<"EOF";
|
||||
# define ${lib}err(f, r) ERR_${lib}_error((f), (r), OPENSSL_FILE, OPENSSL_LINE)
|
||||
|
||||
EOF
|
||||
do {
|
||||
if ($cplusplus == $cpp) {
|
||||
print OUT "#", " "x$cpp, "ifdef __cplusplus\n";
|
||||
print OUT "}\n";
|
||||
print OUT "#", " "x$cpp, "endif\n";
|
||||
}
|
||||
if ($cpp-- > 0) {
|
||||
print OUT "#", " "x$cpp, "endif\n";
|
||||
}
|
||||
} while ($cpp);
|
||||
close OUT;
|
||||
if ( ! $static ) {
|
||||
print OUT <<"EOF";
|
||||
|
||||
# Rewrite the C source file containing the error details.
|
||||
# ifdef __cplusplus
|
||||
extern \"C\" {
|
||||
# endif
|
||||
int ERR_load_${lib}_strings(void);
|
||||
void ERR_unload_${lib}_strings(void);
|
||||
void ERR_${lib}_error(int function, int reason, char *file, int line);
|
||||
# ifdef __cplusplus
|
||||
}
|
||||
# endif
|
||||
EOF
|
||||
}
|
||||
}
|
||||
|
||||
# First, read any existing reason string definitions:
|
||||
my %err_reason_strings;
|
||||
if (open(IN,"<$cfile")) {
|
||||
my $line = "";
|
||||
while (<IN>) {
|
||||
s|\R$||; # Better chomp
|
||||
$_ = $line . $_;
|
||||
$line = "";
|
||||
if (/{ERR_(FUNC|REASON)\(/) {
|
||||
if (/\b(${lib}_R_\w*)\b.*\"(.*)\"/) {
|
||||
$err_reason_strings{$1} = $2;
|
||||
} elsif (/\b${lib}_F_(\w*)\b.*\"(.*)\"/) {
|
||||
if (!exists $ftrans{$1} && ($1 ne $2)) {
|
||||
print STDERR "WARNING: Mismatched function string $2\n";
|
||||
$ftrans{$1} = $2;
|
||||
}
|
||||
} else {
|
||||
$line = $_;
|
||||
}
|
||||
}
|
||||
}
|
||||
close(IN);
|
||||
}
|
||||
print OUT "\n/*\n * $lib function codes.\n */\n";
|
||||
foreach my $i ( @function ) {
|
||||
my $z = 48 - length($i);
|
||||
$z = 0 if $z < 0;
|
||||
if ( $fcodes{$i} eq "X" ) {
|
||||
$fassigned{$lib} =~ m/^:([^:]*):/;
|
||||
my $findcode = $1;
|
||||
$findcode = $fmax{$lib} if !defined $findcode;
|
||||
while ( $fassigned{$lib} =~ m/:$findcode:/ ) {
|
||||
$findcode++;
|
||||
}
|
||||
$fcodes{$i} = $findcode;
|
||||
$fassigned{$lib} .= "$findcode:";
|
||||
print STDERR "New Function code $i\n" if $debug;
|
||||
}
|
||||
printf OUT "#${indent}define $i%s $fcodes{$i}\n", " " x $z;
|
||||
}
|
||||
|
||||
print OUT "\n/*\n * $lib reason codes.\n */\n";
|
||||
foreach my $i ( @reasons ) {
|
||||
my $z = 48 - length($i);
|
||||
$z = 0 if $z < 0;
|
||||
if ( $rcodes{$i} eq "X" ) {
|
||||
$rassigned{$lib} =~ m/^:([^:]*):/;
|
||||
my $findcode = $1;
|
||||
$findcode = $rmax{$lib} if !defined $findcode;
|
||||
while ( $rassigned{$lib} =~ m/:$findcode:/ ) {
|
||||
$findcode++;
|
||||
}
|
||||
$rcodes{$i} = $findcode;
|
||||
$rassigned{$lib} .= "$findcode:";
|
||||
print STDERR "New Reason code $i\n" if $debug;
|
||||
}
|
||||
printf OUT "#${indent}define $i%s $rcodes{$i}\n", " " x $z;
|
||||
}
|
||||
print OUT "\n";
|
||||
|
||||
my $hincf;
|
||||
if($static) {
|
||||
$hincf = $hfile;
|
||||
$hincf =~ s|.*include/||;
|
||||
if ($hincf =~ m|^openssl/|) {
|
||||
$hincf = "<${hincf}>";
|
||||
} else {
|
||||
$hincf = "\"${hincf}\"";
|
||||
}
|
||||
} else {
|
||||
$hincf = "\"$hfile\"";
|
||||
}
|
||||
while (length($indent) > 0) {
|
||||
$indent = substr $indent, 0, -1;
|
||||
print OUT "#${indent}endif\n";
|
||||
}
|
||||
|
||||
# If static we know the error code at compile time so use it
|
||||
# in error definitions.
|
||||
# Rewrite the C source file containing the error details.
|
||||
|
||||
if ($static)
|
||||
{
|
||||
$pack_errcode = "ERR_LIB_${lib}";
|
||||
$load_errcode = "0";
|
||||
}
|
||||
else
|
||||
{
|
||||
$pack_errcode = "0";
|
||||
$load_errcode = "ERR_LIB_${lib}";
|
||||
}
|
||||
# First, read any existing reason string definitions:
|
||||
my $cfile = $errorfile{$lib};
|
||||
my $pack_lib = $internal ? "ERR_LIB_${lib}" : "0";
|
||||
my $hincf = $hfile;
|
||||
$hincf =~ s|.*include/||;
|
||||
if ( $hincf =~ m|^openssl/| ) {
|
||||
$hincf = "<${hincf}>";
|
||||
} else {
|
||||
$hincf = "\"${hincf}\"";
|
||||
}
|
||||
|
||||
open( OUT, ">$cfile" )
|
||||
|| die "Can't open $cfile for writing, $!, stopped";
|
||||
|
||||
open (OUT,">$cfile") || die "Can't open $cfile for writing";
|
||||
my $const = $internal ? 'const ' : '';
|
||||
|
||||
print OUT <<"EOF";
|
||||
print OUT <<"EOF";
|
||||
/*
|
||||
* Generated by util/mkerr.pl DO NOT EDIT
|
||||
* Copyright 1995-$YEAR The OpenSSL Project Authors. All Rights Reserved.
|
||||
@@ -595,177 +567,187 @@ EOF
|
||||
* https://www.openssl.org/source/license.html
|
||||
*/
|
||||
|
||||
#include <stdio.h>
|
||||
#include <openssl/err.h>
|
||||
#include $hincf
|
||||
|
||||
/* BEGIN ERROR CODES */
|
||||
#ifndef OPENSSL_NO_ERR
|
||||
|
||||
# define ERR_FUNC(func) ERR_PACK($pack_errcode,func,0)
|
||||
# define ERR_REASON(reason) ERR_PACK($pack_errcode,0,reason)
|
||||
|
||||
static ERR_STRING_DATA ${lib}_str_functs[] = {
|
||||
static ${const}ERR_STRING_DATA ${lib}_str_functs[] = {
|
||||
EOF
|
||||
# Add each function code: if a function name is found then use it.
|
||||
foreach $i (@function) {
|
||||
my $fn;
|
||||
$i =~ /^${lib}_F_(\S+)$/;
|
||||
$fn = $1;
|
||||
if(exists $ftrans{$fn}) {
|
||||
$fn = $ftrans{$fn};
|
||||
}
|
||||
# print OUT "{ERR_PACK($pack_errcode,$i,0),\t\"$fn\"},\n";
|
||||
if(length($i) + length($fn) > 57) {
|
||||
print OUT " {ERR_FUNC($i),\n \"$fn\"},\n";
|
||||
} else {
|
||||
print OUT " {ERR_FUNC($i), \"$fn\"},\n";
|
||||
}
|
||||
}
|
||||
print OUT <<"EOF";
|
||||
|
||||
# Add each function code: if a function name is found then use it.
|
||||
foreach my $i ( @function ) {
|
||||
my $fn;
|
||||
if ( exists $strings{$i} and $strings{$i} ne '' ) {
|
||||
$fn = $strings{$i};
|
||||
$fn = "" if $fn eq '*';
|
||||
} else {
|
||||
$i =~ /^${lib}_F_(\S+)$/;
|
||||
$fn = $1;
|
||||
$fn = $ftrans{$fn} if exists $ftrans{$fn};
|
||||
$strings{$i} = $fn;
|
||||
}
|
||||
my $short = " {ERR_PACK($pack_lib, $i, 0), \"$fn\"},";
|
||||
if ( length($short) <= 80 ) {
|
||||
print OUT "$short\n";
|
||||
} else {
|
||||
print OUT " {ERR_PACK($pack_lib, $i, 0),\n \"$fn\"},\n";
|
||||
}
|
||||
}
|
||||
print OUT <<"EOF";
|
||||
{0, NULL}
|
||||
};
|
||||
|
||||
static ERR_STRING_DATA ${lib}_str_reasons[] = {
|
||||
static ${const}ERR_STRING_DATA ${lib}_str_reasons[] = {
|
||||
EOF
|
||||
# Add each reason code.
|
||||
foreach $i (@reasons) {
|
||||
my $rn;
|
||||
my $rstr = "ERR_REASON($i)";
|
||||
if (exists $err_reason_strings{$i}) {
|
||||
$rn = $err_reason_strings{$i};
|
||||
} else {
|
||||
$i =~ /^${lib}_R_(\S+)$/;
|
||||
$rn = $1;
|
||||
$rn =~ tr/_[A-Z]/ [a-z]/;
|
||||
}
|
||||
if(length($i) + length($rn) > 55) {
|
||||
print OUT " {${rstr},\n \"$rn\"},\n";
|
||||
} else {
|
||||
print OUT " {${rstr}, \"$rn\"},\n";
|
||||
}
|
||||
}
|
||||
if($static) {
|
||||
print OUT <<"EOF";
|
||||
|
||||
# Add each reason code.
|
||||
foreach my $i ( @reasons ) {
|
||||
my $rn;
|
||||
if ( exists $strings{$i} ) {
|
||||
$rn = $strings{$i};
|
||||
$rn = "" if $rn eq '*';
|
||||
} else {
|
||||
$i =~ /^${lib}_R_(\S+)$/;
|
||||
$rn = $1;
|
||||
$rn =~ tr/_[A-Z]/ [a-z]/;
|
||||
$strings{$i} = $rn;
|
||||
}
|
||||
my $short = " {ERR_PACK($pack_lib, 0, $i), \"$rn\"},";
|
||||
if ( length($short) <= 80 ) {
|
||||
print OUT "$short\n";
|
||||
} else {
|
||||
print OUT " {ERR_PACK($pack_lib, 0, $i),\n \"$rn\"},\n";
|
||||
}
|
||||
}
|
||||
print OUT <<"EOF";
|
||||
{0, NULL}
|
||||
};
|
||||
|
||||
#endif
|
||||
EOF
|
||||
if ( $internal ) {
|
||||
print OUT <<"EOF";
|
||||
|
||||
${staticloader}int ERR_load_${lib}_strings(void)
|
||||
int ERR_load_${lib}_strings(void)
|
||||
{
|
||||
#ifndef OPENSSL_NO_ERR
|
||||
|
||||
if (ERR_func_error_string(${lib}_str_functs[0].error) == NULL) {
|
||||
ERR_load_strings($load_errcode, ${lib}_str_functs);
|
||||
ERR_load_strings($load_errcode, ${lib}_str_reasons);
|
||||
ERR_load_strings_const(${lib}_str_functs);
|
||||
ERR_load_strings_const(${lib}_str_reasons);
|
||||
}
|
||||
#endif
|
||||
return 1;
|
||||
}
|
||||
EOF
|
||||
} else {
|
||||
print OUT <<"EOF";
|
||||
{0, NULL}
|
||||
};
|
||||
} else {
|
||||
my $st = $static ? "static " : "";
|
||||
print OUT <<"EOF";
|
||||
|
||||
#endif
|
||||
static int lib_code = 0;
|
||||
static int error_loaded = 0;
|
||||
|
||||
#ifdef ${lib}_LIB_NAME
|
||||
static ERR_STRING_DATA ${lib}_lib_name[] = {
|
||||
{0, ${lib}_LIB_NAME},
|
||||
{0, NULL}
|
||||
};
|
||||
#endif
|
||||
|
||||
static int ${lib}_lib_error_code = 0;
|
||||
static int ${lib}_error_init = 1;
|
||||
|
||||
${staticloader}int ERR_load_${lib}_strings(void)
|
||||
${st}int ERR_load_${lib}_strings(void)
|
||||
{
|
||||
if (${lib}_lib_error_code == 0)
|
||||
${lib}_lib_error_code = ERR_get_next_error_library();
|
||||
if (lib_code == 0)
|
||||
lib_code = ERR_get_next_error_library();
|
||||
|
||||
if (${lib}_error_init) {
|
||||
${lib}_error_init = 0;
|
||||
if (!error_loaded) {
|
||||
#ifndef OPENSSL_NO_ERR
|
||||
ERR_load_strings(${lib}_lib_error_code, ${lib}_str_functs);
|
||||
ERR_load_strings(${lib}_lib_error_code, ${lib}_str_reasons);
|
||||
#endif
|
||||
|
||||
#ifdef ${lib}_LIB_NAME
|
||||
${lib}_lib_name->error = ERR_PACK(${lib}_lib_error_code, 0, 0);
|
||||
ERR_load_strings(0, ${lib}_lib_name);
|
||||
ERR_load_strings(lib_code, ${lib}_str_functs);
|
||||
ERR_load_strings(lib_code, ${lib}_str_reasons);
|
||||
#endif
|
||||
error_loaded = 1;
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
|
||||
${staticloader}void ERR_unload_${lib}_strings(void)
|
||||
${st}void ERR_unload_${lib}_strings(void)
|
||||
{
|
||||
if (${lib}_error_init == 0) {
|
||||
if (error_loaded) {
|
||||
#ifndef OPENSSL_NO_ERR
|
||||
ERR_unload_strings(${lib}_lib_error_code, ${lib}_str_functs);
|
||||
ERR_unload_strings(${lib}_lib_error_code, ${lib}_str_reasons);
|
||||
ERR_unload_strings(lib_code, ${lib}_str_functs);
|
||||
ERR_unload_strings(lib_code, ${lib}_str_reasons);
|
||||
#endif
|
||||
|
||||
#ifdef ${lib}_LIB_NAME
|
||||
ERR_unload_strings(0, ${lib}_lib_name);
|
||||
#endif
|
||||
${lib}_error_init = 1;
|
||||
error_loaded = 0;
|
||||
}
|
||||
}
|
||||
|
||||
${staticloader}void ERR_${lib}_error(int function, int reason, char *file, int line)
|
||||
${st}void ERR_${lib}_error(int function, int reason, char *file, int line)
|
||||
{
|
||||
if (${lib}_lib_error_code == 0)
|
||||
${lib}_lib_error_code = ERR_get_next_error_library();
|
||||
ERR_PUT_error(${lib}_lib_error_code, function, reason, file, line);
|
||||
if (lib_code == 0)
|
||||
lib_code = ERR_get_next_error_library();
|
||||
ERR_PUT_error(lib_code, function, reason, file, line);
|
||||
}
|
||||
EOF
|
||||
|
||||
}
|
||||
|
||||
close OUT;
|
||||
}
|
||||
|
||||
close OUT;
|
||||
undef %err_reason_strings;
|
||||
}
|
||||
|
||||
if($debug && %notrans) {
|
||||
print STDERR "The following function codes were not translated:\n";
|
||||
foreach(sort keys %notrans)
|
||||
{
|
||||
print STDERR "$_\n";
|
||||
}
|
||||
}
|
||||
|
||||
&phase("Ending");
|
||||
# Make a list of unreferenced function and reason codes
|
||||
|
||||
foreach (keys %fcodes) {
|
||||
push (@funref, $_) unless exists $ufcodes{$_};
|
||||
if ( $unref ) {
|
||||
my @funref;
|
||||
foreach ( keys %fcodes ) {
|
||||
push( @funref, $_ ) unless exists $usedfuncs{$_};
|
||||
}
|
||||
my @runref;
|
||||
foreach ( keys %rcodes ) {
|
||||
push( @runref, $_ ) unless exists $usedreasons{$_};
|
||||
}
|
||||
if ( @funref ) {
|
||||
print STDERR "The following function codes were not referenced:\n";
|
||||
foreach ( sort @funref ) {
|
||||
print STDERR " $_\n";
|
||||
}
|
||||
}
|
||||
if ( @runref ) {
|
||||
print STDERR "The following reason codes were not referenced:\n";
|
||||
foreach ( sort @runref ) {
|
||||
print STDERR " $_\n";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
foreach (keys %rcodes) {
|
||||
push (@runref, $_) unless exists $urcodes{$_};
|
||||
}
|
||||
|
||||
if($unref && @funref) {
|
||||
print STDERR "The following function codes were not referenced:\n";
|
||||
foreach(sort @funref)
|
||||
{
|
||||
print STDERR "$_\n";
|
||||
}
|
||||
}
|
||||
|
||||
if($unref && @runref) {
|
||||
print STDERR "The following reason codes were not referenced:\n";
|
||||
foreach(sort @runref)
|
||||
{
|
||||
print STDERR "$_\n";
|
||||
}
|
||||
}
|
||||
|
||||
if($errcount) {
|
||||
print STDERR "There were errors, failing...\n\n";
|
||||
exit $errcount;
|
||||
die "Found $errors errors, quitting" if $errors;
|
||||
|
||||
# Update the state file
|
||||
if ( $newstate ) {
|
||||
open(OUT, ">$statefile.new")
|
||||
|| die "Can't write $statefile.new, $!";
|
||||
print OUT <<"EOF";
|
||||
# Copyright 1999-$YEAR The OpenSSL Project Authors. All Rights Reserved.
|
||||
#
|
||||
# Licensed under the OpenSSL license (the "License"). You may not use
|
||||
# this file except in compliance with the License. You can obtain a copy
|
||||
# in the file LICENSE in the source distribution or at
|
||||
# https://www.openssl.org/source/license.html
|
||||
EOF
|
||||
print OUT "\n# Function codes\n";
|
||||
foreach my $i ( sort keys %fcodes ) {
|
||||
my $short = "$i:$fcodes{$i}:";
|
||||
my $t = exists $strings{$i} ? $strings{$i} : "";
|
||||
$t = "\\\n\t" . $t if length($short) + length($t) > 80;
|
||||
print OUT "$short$t\n";
|
||||
}
|
||||
print OUT "\n#Reason codes\n";
|
||||
foreach my $i ( sort keys %rcodes ) {
|
||||
my $short = "$i:$rcodes{$i}:";
|
||||
my $t = exists $strings{$i} ? "$strings{$i}" : "";
|
||||
$t = "\\\n\t" . $t if length($short) + length($t) > 80;
|
||||
print OUT "$short$t\n" if !exists $rextra{$i};
|
||||
}
|
||||
close(OUT);
|
||||
if ( $skippedstate ) {
|
||||
print "Skipped state, leaving update in $statefile.new";
|
||||
} else {
|
||||
rename "$statefile", "$statefile.old"
|
||||
|| die "Can't backup $statefile to $statefile.old, $!";
|
||||
rename "$statefile.new", "$statefile"
|
||||
|| die "Can't rename $statefile to $statefile.new, $!";
|
||||
}
|
||||
}
|
||||
|
||||
exit;
|
||||
+27
-18
@@ -6,36 +6,45 @@
|
||||
# in the file LICENSE in the source distribution or at
|
||||
# https://www.openssl.org/source/license.html
|
||||
|
||||
use strict;
|
||||
use warnings;
|
||||
use lib ".";
|
||||
use configdata;
|
||||
use File::Spec::Functions;
|
||||
|
||||
my $versionfile = catfile($config{sourcedir},"include/openssl/opensslv.h");
|
||||
my $versionfile = catfile( $config{sourcedir}, "include/openssl/opensslv.h" );
|
||||
|
||||
my ( $ver, $v1, $v2, $v3, $v4, $beta, $version );
|
||||
|
||||
open FD, $versionfile or die "Couldn't open include/openssl/opensslv.h: $!\n";
|
||||
while(<FD>) {
|
||||
while (<FD>) {
|
||||
if (/OPENSSL_VERSION_NUMBER\s+(0x[0-9a-f]+)/i) {
|
||||
$ver = hex($1);
|
||||
$v1 = ($ver>>28);
|
||||
$v2 = ($ver>>20)&0xff;
|
||||
$v3 = ($ver>>12)&0xff;
|
||||
$v4 = ($ver>> 4)&0xff;
|
||||
$beta = $ver&0xf;
|
||||
$version = "$v1.$v2.$v3";
|
||||
if ($beta==0xf) { $version .= chr(ord('a')+$v4-1) if ($v4); }
|
||||
elsif ($beta==0){ $version .= "-dev"; }
|
||||
else { $version .= "-beta$beta"; }
|
||||
last;
|
||||
$ver = hex($1);
|
||||
$v1 = ( $ver >> 28 );
|
||||
$v2 = ( $ver >> 20 ) & 0xff;
|
||||
$v3 = ( $ver >> 12 ) & 0xff;
|
||||
$v4 = ( $ver >> 4 ) & 0xff;
|
||||
$beta = $ver & 0xf;
|
||||
$version = "$v1.$v2.$v3";
|
||||
if ( $beta == 0xf ) {
|
||||
$version .= chr( ord('a') + $v4 - 1 ) if ($v4);
|
||||
} elsif ( $beta == 0 ) {
|
||||
$version .= "-dev";
|
||||
} else {
|
||||
$version .= "-beta$beta";
|
||||
}
|
||||
last;
|
||||
}
|
||||
}
|
||||
close(FD);
|
||||
|
||||
$filename = $ARGV[0]; $filename =~ /(.*)\.([^.]+)$/;
|
||||
$basename = $1;
|
||||
$extname = $2;
|
||||
my $filename = $ARGV[0];
|
||||
$filename =~ /(.*)\.([^.]+)$/;
|
||||
my $basename = $1;
|
||||
my $extname = $2;
|
||||
|
||||
if ($extname =~ /dll/i) { $description = "OpenSSL shared library"; }
|
||||
else { $description = "OpenSSL application"; }
|
||||
my $description = "OpenSSL application";
|
||||
$description = "OpenSSL shared library" if $extname =~ /dll/i;
|
||||
|
||||
print <<___;
|
||||
#include <winver.h>
|
||||
|
||||
@@ -111,7 +111,7 @@ do
|
||||
# the process-comments options and then undo that marking, and then
|
||||
# finally re-run indent without process-comments so the marked-to-
|
||||
# be-ignored comments we did automatically end up getting moved
|
||||
# into the right possition within the code as indent leaves marked
|
||||
# into the right position within the code as indent leaves marked
|
||||
# comments entirely untouched - we appear to have no way to avoid
|
||||
# the double processing and get the desired output
|
||||
cat "$j" | \
|
||||
|
||||
Executable
+63
@@ -0,0 +1,63 @@
|
||||
#!/usr/bin/env bash
|
||||
#
|
||||
# Copyright 2018 The OpenSSL Project Authors. All Rights Reserved.
|
||||
#
|
||||
# Licensed under the OpenSSL license (the "License"). You may not use
|
||||
# this file except in compliance with the License. You can obtain a copy
|
||||
# in the file LICENSE in the source distribution or at
|
||||
# https://www.openssl.org/source/license.html
|
||||
|
||||
|
||||
myname="$(basename $0)"
|
||||
|
||||
this_year="$(date '+%Y')"
|
||||
some_year="[12][0-9][0-9][0-9]"
|
||||
year_range="(${some_year})(-${some_year})?"
|
||||
|
||||
copyright_owner="The OpenSSL Project"
|
||||
copyright="Copyright .*${year_range} .*${copyright_owner}"
|
||||
|
||||
# sed_script:
|
||||
# for all lines that contain ${copyright} : {
|
||||
# replace years yyyy-zzzz (or year yyyy) by yyyy-${this_year}
|
||||
# replace repeated years yyyy-yyyy by yyyy
|
||||
# }
|
||||
sed_script="/${copyright}/{ s/${year_range}/\1-${this_year}/ ; s/(${some_year})-\1/\1/ }"
|
||||
|
||||
function usage() {
|
||||
cat >&2 <<EOF
|
||||
usage: $myname [-h|--help] [file|directory] ...
|
||||
|
||||
Updates the year ranges of all OpenSSL copyright statements in the given
|
||||
files or directories. (Directories are traversed recursively.)
|
||||
EOF
|
||||
}
|
||||
|
||||
if [ $# -eq 0 ]; then
|
||||
usage
|
||||
exit 0
|
||||
fi
|
||||
|
||||
|
||||
for arg in "$@"; do
|
||||
case $arg in
|
||||
-h|--help)
|
||||
usage
|
||||
exit 0
|
||||
;;
|
||||
-*)
|
||||
echo -e "illegal option: $arg\n" >& 2
|
||||
usage
|
||||
exit 1
|
||||
;;
|
||||
*)
|
||||
if [ -f "$arg" ]; then
|
||||
sed -E -i "${sed_script}" "$arg"
|
||||
elif [ -d "$arg" ]; then
|
||||
find "$arg" -name '.[a-z]*' -prune -o -type f -exec sed -E -i "${sed_script}" {} +
|
||||
else
|
||||
echo "$arg: no such file or directory" >&2
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
done
|
||||
+260
-145
@@ -16,8 +16,8 @@ use Exporter;
|
||||
use vars qw($VERSION @ISA @EXPORT @EXPORT_OK %EXPORT_TAGS);
|
||||
$VERSION = "0.8";
|
||||
@ISA = qw(Exporter);
|
||||
@EXPORT = (@Test::More::EXPORT, qw(setup indir app fuzz perlapp test perltest
|
||||
run));
|
||||
@EXPORT = (@Test::More::EXPORT, qw(setup run indir cmd app fuzz test
|
||||
perlapp perltest subtest));
|
||||
@EXPORT_OK = (@Test::More::EXPORT_OK, qw(bldtop_dir bldtop_file
|
||||
srctop_dir srctop_file
|
||||
data_file
|
||||
@@ -65,6 +65,7 @@ use File::Spec::Functions qw/file_name_is_absolute curdir canonpath splitdir
|
||||
use File::Path 2.00 qw/rmtree mkpath/;
|
||||
use File::Basename;
|
||||
|
||||
my $level = 0;
|
||||
|
||||
# The name of the test. This is set by setup() and is used in the other
|
||||
# functions to verify that setup() has been used.
|
||||
@@ -91,9 +92,9 @@ my %hooks = (
|
||||
|
||||
# exit_checker is used by run() directly after completion of a command.
|
||||
# it receives the exit code from that command and is expected to return
|
||||
# 1 (for success) or 0 (for failure). This is the value that will be
|
||||
# returned by run().
|
||||
# NOTE: When run() gets the option 'capture => 1', this hook is ignored.
|
||||
# 1 (for success) or 0 (for failure). This is the status value that run()
|
||||
# will give back (through the |statusvar| reference and as returned value
|
||||
# when capture => 1 doesn't apply).
|
||||
exit_checker => sub { return shift == 0 ? 1 : 0 },
|
||||
|
||||
);
|
||||
@@ -101,21 +102,6 @@ my %hooks = (
|
||||
# Debug flag, to be set manually when needed
|
||||
my $debug = 0;
|
||||
|
||||
# Declare some utility functions that are defined at the end
|
||||
sub bldtop_file;
|
||||
sub bldtop_dir;
|
||||
sub srctop_file;
|
||||
sub srctop_dir;
|
||||
sub quotify;
|
||||
|
||||
# Declare some private functions that are defined at the end
|
||||
sub __env;
|
||||
sub __cwd;
|
||||
sub __apps_file;
|
||||
sub __results_file;
|
||||
sub __fixup_cmd;
|
||||
sub __build_cmd;
|
||||
|
||||
=head2 Main functions
|
||||
|
||||
The following functions are exported by default when using C<OpenSSL::Test>.
|
||||
@@ -225,25 +211,18 @@ sub indir {
|
||||
|
||||
=over 4
|
||||
|
||||
=item B<app ARRAYREF, OPTS>
|
||||
=item B<cmd ARRAYREF, OPTS>
|
||||
|
||||
=item B<test ARRAYREF, OPTS>
|
||||
This functions build up a platform dependent command based on the
|
||||
input. It takes a reference to a list that is the executable or
|
||||
script and its arguments, and some additional options (described
|
||||
further on). Where necessary, the command will be wrapped in a
|
||||
suitable environment to make sure the correct shared libraries are
|
||||
used (currently only on Unix).
|
||||
|
||||
Both of these functions take a reference to a list that is a command and
|
||||
its arguments, and some additional options (described further on).
|
||||
It returns a CODEREF to be used by C<run>, C<pipe> or C<cmdstr>.
|
||||
|
||||
C<app> expects to find the given command (the first item in the given list
|
||||
reference) as an executable in C<$BIN_D> (if defined, otherwise C<$TOP/apps>
|
||||
or C<$BLDTOP/apps>).
|
||||
|
||||
C<test> expects to find the given command (the first item in the given list
|
||||
reference) as an executable in C<$TEST_D> (if defined, otherwise C<$TOP/test>
|
||||
or C<$BLDTOP/test>).
|
||||
|
||||
Both return a CODEREF to be used by C<run>, C<pipe> or C<cmdstr>.
|
||||
|
||||
The options that both C<app> and C<test> can take are in the form of hash
|
||||
values:
|
||||
The options that C<cmd> can take are in the form of hash values:
|
||||
|
||||
=over 4
|
||||
|
||||
@@ -259,21 +238,42 @@ string PATH, I<or>, if the value is C<undef>, C</dev/null> or similar.
|
||||
|
||||
=back
|
||||
|
||||
=item B<app ARRAYREF, OPTS>
|
||||
|
||||
=item B<test ARRAYREF, OPTS>
|
||||
|
||||
Both of these are specific applications of C<cmd>, with just a couple
|
||||
of small difference:
|
||||
|
||||
C<app> expects to find the given command (the first item in the given list
|
||||
reference) as an executable in C<$BIN_D> (if defined, otherwise C<$TOP/apps>
|
||||
or C<$BLDTOP/apps>).
|
||||
|
||||
C<test> expects to find the given command (the first item in the given list
|
||||
reference) as an executable in C<$TEST_D> (if defined, otherwise C<$TOP/test>
|
||||
or C<$BLDTOP/test>).
|
||||
|
||||
Also, for both C<app> and C<test>, the command may be prefixed with
|
||||
the content of the environment variable C<$EXE_SHELL>, which is useful
|
||||
in case OpenSSL has been cross compiled.
|
||||
|
||||
=item B<perlapp ARRAYREF, OPTS>
|
||||
|
||||
=item B<perltest ARRAYREF, OPTS>
|
||||
|
||||
Both these functions function the same way as B<app> and B<test>, except
|
||||
that they expect the command to be a perl script. Also, they support one
|
||||
more option:
|
||||
These are also specific applications of C<cmd>, where the interpreter
|
||||
is predefined to be C<perl>, and they expect the script to be
|
||||
interpreted to reside in the same location as C<app> and C<test>.
|
||||
|
||||
C<perlapp> and C<perltest> will also take the following option:
|
||||
|
||||
=over 4
|
||||
|
||||
=item B<interpreter_args =E<gt> ARRAYref>
|
||||
|
||||
The array reference is a set of arguments for perl rather than the script.
|
||||
Take care so that none of them can be seen as a script! Flags and their
|
||||
eventual arguments only!
|
||||
The array reference is a set of arguments for the interpreter rather
|
||||
than the script. Take care so that none of them can be seen as a
|
||||
script! Flags and their eventual arguments only!
|
||||
|
||||
=back
|
||||
|
||||
@@ -284,54 +284,114 @@ An example:
|
||||
|
||||
=back
|
||||
|
||||
=begin comment
|
||||
|
||||
One might wonder over the complexity of C<apps>, C<fuzz>, C<test>, ...
|
||||
with all the lazy evaluations and all that. The reason for this is that
|
||||
we want to make sure the directory in which those programs are found are
|
||||
correct at the time these commands are used. Consider the following code
|
||||
snippet:
|
||||
|
||||
my $cmd = app(["openssl", ...]);
|
||||
|
||||
indir "foo", sub {
|
||||
ok(run($cmd), "Testing foo")
|
||||
};
|
||||
|
||||
If there wasn't this lazy evaluation, the directory where C<openssl> is
|
||||
found would be incorrect at the time C<run> is called, because it was
|
||||
calculated before we moved into the directory "foo".
|
||||
|
||||
=end comment
|
||||
|
||||
=cut
|
||||
|
||||
sub cmd {
|
||||
my $cmd = shift;
|
||||
my %opts = @_;
|
||||
return sub {
|
||||
my $num = shift;
|
||||
# Make a copy to not destroy the caller's array
|
||||
my @cmdargs = ( @$cmd );
|
||||
my @prog = __wrap_cmd(shift @cmdargs, $opts{exe_shell} // ());
|
||||
|
||||
return __decorate_cmd($num, [ @prog, quotify(@cmdargs) ],
|
||||
%opts);
|
||||
}
|
||||
}
|
||||
|
||||
sub app {
|
||||
my $cmd = shift;
|
||||
my %opts = @_;
|
||||
return sub { my $num = shift;
|
||||
return __build_cmd($num, \&__apps_file, $cmd, %opts); }
|
||||
return sub {
|
||||
my @cmdargs = ( @{$cmd} );
|
||||
my @prog = __fixup_prg(__apps_file(shift @cmdargs, __exeext()));
|
||||
return cmd([ @prog, @cmdargs ],
|
||||
exe_shell => $ENV{EXE_SHELL}, %opts) -> (shift);
|
||||
}
|
||||
}
|
||||
|
||||
sub fuzz {
|
||||
my $cmd = shift;
|
||||
my %opts = @_;
|
||||
return sub { my $num = shift;
|
||||
return __build_cmd($num, \&__fuzz_file, $cmd, %opts); }
|
||||
return sub {
|
||||
my @cmdargs = ( @{$cmd} );
|
||||
my @prog = __fixup_prg(__fuzz_file(shift @cmdargs, __exeext()));
|
||||
return cmd([ @prog, @cmdargs ],
|
||||
exe_shell => $ENV{EXE_SHELL}, %opts) -> (shift);
|
||||
}
|
||||
}
|
||||
|
||||
sub test {
|
||||
my $cmd = shift;
|
||||
my %opts = @_;
|
||||
return sub { my $num = shift;
|
||||
return __build_cmd($num, \&__test_file, $cmd, %opts); }
|
||||
return sub {
|
||||
my @cmdargs = ( @{$cmd} );
|
||||
my @prog = __fixup_prg(__test_file(shift @cmdargs, __exeext()));
|
||||
return cmd([ @prog, @cmdargs ],
|
||||
exe_shell => $ENV{EXE_SHELL}, %opts) -> (shift);
|
||||
}
|
||||
}
|
||||
|
||||
sub perlapp {
|
||||
my $cmd = shift;
|
||||
my %opts = @_;
|
||||
return sub { my $num = shift;
|
||||
return __build_cmd($num, \&__perlapps_file, $cmd, %opts); }
|
||||
return sub {
|
||||
my @interpreter_args = defined $opts{interpreter_args} ?
|
||||
@{$opts{interpreter_args}} : ();
|
||||
my @interpreter = __fixup_prg($^X);
|
||||
my @cmdargs = ( @{$cmd} );
|
||||
my @prog = __apps_file(shift @cmdargs, undef);
|
||||
return cmd([ @interpreter, @interpreter_args,
|
||||
@prog, @cmdargs ], %opts) -> (shift);
|
||||
}
|
||||
}
|
||||
|
||||
sub perltest {
|
||||
my $cmd = shift;
|
||||
my %opts = @_;
|
||||
return sub { my $num = shift;
|
||||
return __build_cmd($num, \&__perltest_file, $cmd, %opts); }
|
||||
return sub {
|
||||
my @interpreter_args = defined $opts{interpreter_args} ?
|
||||
@{$opts{interpreter_args}} : ();
|
||||
my @interpreter = __fixup_prg($^X);
|
||||
my @cmdargs = ( @{$cmd} );
|
||||
my @prog = __test_file(shift @cmdargs, undef);
|
||||
return cmd([ @interpreter, @interpreter_args,
|
||||
@prog, @cmdargs ], %opts) -> (shift);
|
||||
}
|
||||
}
|
||||
|
||||
=over 4
|
||||
|
||||
=item B<run CODEREF, OPTS>
|
||||
|
||||
This CODEREF is expected to be the value return by C<app> or C<test>,
|
||||
anything else will most likely cause an error unless you know what you're
|
||||
doing.
|
||||
CODEREF is expected to be the value return by C<cmd> or any of its
|
||||
derivatives, anything else will most likely cause an error unless you
|
||||
know what you're doing.
|
||||
|
||||
C<run> executes the command returned by CODEREF and return either the
|
||||
resulting output (if the option C<capture> is set true) or a boolean indicating
|
||||
if the command succeeded or not.
|
||||
resulting output (if the option C<capture> is set true) or a boolean
|
||||
indicating if the command succeeded or not.
|
||||
|
||||
The options that C<run> can take are in the form of hash values:
|
||||
|
||||
@@ -344,6 +404,18 @@ return the resulting output as an array of lines. If false or not given,
|
||||
the command will be executed with C<system()>, and C<run> will return 1 if
|
||||
the command was successful or 0 if it wasn't.
|
||||
|
||||
=item B<prefix =E<gt> EXPR>
|
||||
|
||||
If specified, EXPR will be used as a string to prefix the output from the
|
||||
command. This is useful if the output contains lines starting with C<ok >
|
||||
or C<not ok > that can disturb Test::Harness.
|
||||
|
||||
=item B<statusvar =E<gt> VARREF>
|
||||
|
||||
If used, B<VARREF> must be a reference to a scalar variable. It will be
|
||||
assigned a boolean indicating if the command succeeded or not. This is
|
||||
particularly useful together with B<capture>.
|
||||
|
||||
=back
|
||||
|
||||
For further discussion on what is considered a successful command or not, see
|
||||
@@ -368,6 +440,9 @@ sub run {
|
||||
my $r = 0;
|
||||
my $e = 0;
|
||||
|
||||
die "OpenSSL::Test::run(): statusvar value not a scalar reference"
|
||||
if $opts{statusvar} && ref($opts{statusvar}) ne "SCALAR";
|
||||
|
||||
# In non-verbose, we want to shut up the command interpreter, in case
|
||||
# it has something to complain about. On VMS, it might complain both
|
||||
# on stdout and stderr
|
||||
@@ -380,17 +455,35 @@ sub run {
|
||||
open STDERR, ">", devnull();
|
||||
}
|
||||
|
||||
$ENV{HARNESS_OSSL_LEVEL} = $level + 1;
|
||||
|
||||
# The dance we do with $? is the same dance the Unix shells appear to
|
||||
# do. For example, a program that gets aborted (and therefore signals
|
||||
# SIGABRT = 6) will appear to exit with the code 134. We mimic this
|
||||
# to make it easier to compare with a manual run of the command.
|
||||
if ($opts{capture}) {
|
||||
@r = `$prefix$cmd`;
|
||||
$e = ($? & 0x7f) ? ($? & 0x7f)|0x80 : ($? >> 8);
|
||||
if ($opts{capture} || defined($opts{prefix})) {
|
||||
my $pipe;
|
||||
local $_;
|
||||
|
||||
open($pipe, '-|', "$prefix$cmd") or die "Can't start command: $!";
|
||||
while(<$pipe>) {
|
||||
my $l = ($opts{prefix} // "") . $_;
|
||||
if ($opts{capture}) {
|
||||
push @r, $l;
|
||||
} else {
|
||||
print STDOUT $l;
|
||||
}
|
||||
}
|
||||
close $pipe;
|
||||
} else {
|
||||
$ENV{HARNESS_OSSL_PREFIX} = "# ";
|
||||
system("$prefix$cmd");
|
||||
$e = ($? & 0x7f) ? ($? & 0x7f)|0x80 : ($? >> 8);
|
||||
$r = $hooks{exit_checker}->($e);
|
||||
delete $ENV{HARNESS_OSSL_PREFIX};
|
||||
}
|
||||
$e = ($? & 0x7f) ? ($? & 0x7f)|0x80 : ($? >> 8);
|
||||
$r = $hooks{exit_checker}->($e);
|
||||
if ($opts{statusvar}) {
|
||||
${$opts{statusvar}} = $r;
|
||||
}
|
||||
|
||||
if ($ENV{HARNESS_ACTIVE} && !$ENV{HARNESS_VERBOSE}) {
|
||||
@@ -570,7 +663,7 @@ sub pipe {
|
||||
|
||||
=item B<with HASHREF, CODEREF>
|
||||
|
||||
C<with> will temporarly install hooks given by the HASHREF and then execute
|
||||
C<with> will temporarily install hooks given by the HASHREF and then execute
|
||||
the given CODEREF. Hooks are usually expected to have a coderef as value.
|
||||
|
||||
The currently available hoosk are:
|
||||
@@ -616,7 +709,7 @@ sub with {
|
||||
C<cmdstr> takes a CODEREF from C<app> or C<test> and simply returns the
|
||||
command as a string.
|
||||
|
||||
C<cmdstr> takes some additiona options OPTS that affect the string returned:
|
||||
C<cmdstr> takes some additional options OPTS that affect the string returned:
|
||||
|
||||
=over 4
|
||||
|
||||
@@ -754,6 +847,14 @@ sub __env {
|
||||
$end_with_bailout = $ENV{STOPTEST} ? 1 : 0;
|
||||
};
|
||||
|
||||
# __srctop_file and __srctop_dir are helpers to build file and directory
|
||||
# names on top of the source directory. They depend on $SRCTOP, and
|
||||
# therefore on the proper use of setup() and when needed, indir().
|
||||
# __bldtop_file and __bldtop_dir do the same thing but relative to $BLDTOP.
|
||||
# __srctop_file and __bldtop_file take the same kind of argument as
|
||||
# File::Spec::Functions::catfile.
|
||||
# Similarly, __srctop_dir and __bldtop_dir take the same kind of argument
|
||||
# as File::Spec::Functions::catdir
|
||||
sub __srctop_file {
|
||||
BAIL_OUT("Must run setup() first") if (! $test_name);
|
||||
|
||||
@@ -780,6 +881,9 @@ sub __bldtop_dir {
|
||||
return catdir($directories{BLDTOP},@_);
|
||||
}
|
||||
|
||||
# __exeext is a function that returns the platform dependent file extension
|
||||
# for executable binaries, or the value of the environment variable $EXE_EXT
|
||||
# if that one is defined.
|
||||
sub __exeext {
|
||||
my $ext = "";
|
||||
if ($^O eq "VMS" ) { # VMS
|
||||
@@ -790,51 +894,45 @@ sub __exeext {
|
||||
return $ENV{"EXE_EXT"} || $ext;
|
||||
}
|
||||
|
||||
# __test_file, __apps_file and __fuzz_file return the full path to a file
|
||||
# relative to the test/, apps/ or fuzz/ directory in the build tree or the
|
||||
# source tree, depending on where the file is found. Note that when looking
|
||||
# in the build tree, the file name with an added extension is looked for, if
|
||||
# an extension is given. The intent is to look for executable binaries (in
|
||||
# the build tree) or possibly scripts (in the source tree).
|
||||
# These functions all take the same arguments as File::Spec::Functions::catfile,
|
||||
# *plus* a mandatory extension argument. This extension argument can be undef,
|
||||
# and is ignored in such a case.
|
||||
sub __test_file {
|
||||
BAIL_OUT("Must run setup() first") if (! $test_name);
|
||||
|
||||
my $e = pop || "";
|
||||
my $f = pop;
|
||||
my $out = catfile($directories{BLDTEST},@_,$f . __exeext());
|
||||
$out = catfile($directories{SRCTEST},@_,$f) unless -x $out;
|
||||
return $out;
|
||||
}
|
||||
|
||||
sub __perltest_file {
|
||||
BAIL_OUT("Must run setup() first") if (! $test_name);
|
||||
|
||||
my $f = pop;
|
||||
my $out = catfile($directories{BLDTEST},@_,$f);
|
||||
my $out = catfile($directories{BLDTEST},@_,$f . $e);
|
||||
$out = catfile($directories{SRCTEST},@_,$f) unless -f $out;
|
||||
return ($^X, $out);
|
||||
return $out;
|
||||
}
|
||||
|
||||
sub __apps_file {
|
||||
BAIL_OUT("Must run setup() first") if (! $test_name);
|
||||
|
||||
my $e = pop || "";
|
||||
my $f = pop;
|
||||
my $out = catfile($directories{BLDAPPS},@_,$f . __exeext());
|
||||
$out = catfile($directories{SRCAPPS},@_,$f) unless -x $out;
|
||||
my $out = catfile($directories{BLDAPPS},@_,$f . $e);
|
||||
$out = catfile($directories{SRCAPPS},@_,$f) unless -f $out;
|
||||
return $out;
|
||||
}
|
||||
|
||||
sub __fuzz_file {
|
||||
BAIL_OUT("Must run setup() first") if (! $test_name);
|
||||
|
||||
my $e = pop || "";
|
||||
my $f = pop;
|
||||
my $out = catfile($directories{BLDFUZZ},@_,$f . __exeext());
|
||||
$out = catfile($directories{SRCFUZZ},@_,$f) unless -x $out;
|
||||
my $out = catfile($directories{BLDFUZZ},@_,$f . $e);
|
||||
$out = catfile($directories{SRCFUZZ},@_,$f) unless -f $out;
|
||||
return $out;
|
||||
}
|
||||
|
||||
sub __perlapps_file {
|
||||
BAIL_OUT("Must run setup() first") if (! $test_name);
|
||||
|
||||
my $f = pop;
|
||||
my $out = catfile($directories{BLDAPPS},@_,$f);
|
||||
$out = catfile($directories{SRCAPPS},@_,$f) unless -f $out;
|
||||
return ($^X, $out);
|
||||
}
|
||||
|
||||
sub __data_file {
|
||||
BAIL_OUT("Must run setup() first") if (! $test_name);
|
||||
|
||||
@@ -849,6 +947,16 @@ sub __results_file {
|
||||
return catfile($directories{RESULTS},@_,$f);
|
||||
}
|
||||
|
||||
# __cwd DIR
|
||||
# __cwd DIR, OPTS
|
||||
#
|
||||
# __cwd changes directory to DIR (string) and changes all the relative
|
||||
# entries in %directories accordingly. OPTS is an optional series of
|
||||
# hash style arguments to alter __cwd's behavior:
|
||||
#
|
||||
# create = 0|1 The directory we move to is created if 1, not if 0.
|
||||
# cleanup = 0|1 The directory we move from is removed if 1, not if 0.
|
||||
|
||||
sub __cwd {
|
||||
my $dir = catdir(shift);
|
||||
my %opts = @_;
|
||||
@@ -910,7 +1018,7 @@ sub __cwd {
|
||||
}
|
||||
|
||||
# We put back new values carefully. Doing the obvious
|
||||
# %directories = ( %tmp_irectories )
|
||||
# %directories = ( %tmp_directories )
|
||||
# will clear out any value that happens to be an absolute path
|
||||
foreach (keys %tmp_directories) {
|
||||
$directories{$_} = $tmp_directories{$_};
|
||||
@@ -937,28 +1045,46 @@ sub __cwd {
|
||||
return $reverse;
|
||||
}
|
||||
|
||||
sub __fixup_cmd {
|
||||
my $prog = shift;
|
||||
# __wrap_cmd CMD
|
||||
# __wrap_cmd CMD, EXE_SHELL
|
||||
#
|
||||
# __wrap_cmd "wraps" CMD (string) with a beginning command that makes sure
|
||||
# the command gets executed with an appropriate environment. If EXE_SHELL
|
||||
# is given, it is used as the beginning command.
|
||||
#
|
||||
# __wrap_cmd returns a list that should be used to build up a larger list
|
||||
# of command tokens, or be joined together like this:
|
||||
#
|
||||
# join(" ", __wrap_cmd($cmd))
|
||||
sub __wrap_cmd {
|
||||
my $cmd = shift;
|
||||
my $exe_shell = shift;
|
||||
|
||||
my $prefix = __bldtop_file("util", "shlib_wrap.sh")." ";
|
||||
my @prefix = ( __bldtop_file("util", "shlib_wrap.sh") );
|
||||
|
||||
if (defined($exe_shell)) {
|
||||
$prefix = "$exe_shell ";
|
||||
} elsif ($^O eq "VMS" ) { # VMS
|
||||
$prefix = ($prog =~ /^(?:[\$a-z0-9_]+:)?[<\[]/i ? "mcr " : "mcr []");
|
||||
} elsif ($^O eq "MSWin32") { # Windows
|
||||
$prefix = "";
|
||||
if(defined($exe_shell)) {
|
||||
@prefix = ( $exe_shell );
|
||||
} elsif ($^O eq "VMS" || $^O eq "MSWin32") {
|
||||
# VMS and Windows don't use any wrapper script for the moment
|
||||
@prefix = ();
|
||||
}
|
||||
|
||||
# We test both with and without extension. The reason
|
||||
# is that we might be passed a complete file spec, with
|
||||
# extension.
|
||||
if ( ! -x $prog ) {
|
||||
my $prog = "$prog";
|
||||
if ( ! -x $prog ) {
|
||||
$prog = undef;
|
||||
}
|
||||
return (@prefix, $cmd);
|
||||
}
|
||||
|
||||
# __fixup_prg PROG
|
||||
#
|
||||
# __fixup_prg does whatever fixup is needed to execute an executable binary
|
||||
# given by PROG (string).
|
||||
#
|
||||
# __fixup_prg returns a string with the possibly prefixed program path spec.
|
||||
sub __fixup_prg {
|
||||
my $prog = shift;
|
||||
|
||||
my $prefix = "";
|
||||
|
||||
if ($^O eq "VMS" ) {
|
||||
$prefix = ($prog =~ /^(?:[\$a-z0-9_]+:)?[<\[]/i ? "mcr " : "mcr []");
|
||||
}
|
||||
|
||||
if (defined($prog)) {
|
||||
@@ -974,45 +1100,25 @@ sub __fixup_cmd {
|
||||
return undef;
|
||||
}
|
||||
|
||||
sub __build_cmd {
|
||||
# __decorate_cmd NUM, CMDARRAYREF
|
||||
#
|
||||
# __decorate_cmd takes a command number NUM and a command token array
|
||||
# CMDARRAYREF, builds up a command string from them and decorates it
|
||||
# with necessary redirections.
|
||||
# __decorate_cmd returns a list of two strings, one with the command
|
||||
# string to actually be used, the other to be displayed for the user.
|
||||
# The reason these strings might differ is that we redirect stderr to
|
||||
# the null device unless we're verbose and unless the user has
|
||||
# explicitly specified a stderr redirection.
|
||||
sub __decorate_cmd {
|
||||
BAIL_OUT("Must run setup() first") if (! $test_name);
|
||||
|
||||
my $num = shift;
|
||||
my $path_builder = shift;
|
||||
# Make a copy to not destroy the caller's array
|
||||
my @cmdarray = ( @{$_[0]} ); shift;
|
||||
my $cmd = shift;
|
||||
my %opts = @_;
|
||||
|
||||
# We do a little dance, as $path_builder might return a list of
|
||||
# more than one. If so, only the first is to be considered a
|
||||
# program to fix up, the rest is part of the arguments. This
|
||||
# happens for perl scripts, where $path_builder will return
|
||||
# a list of two, $^X and the script name.
|
||||
# Also, if $path_builder returned more than one, we don't apply
|
||||
# the EXE_SHELL environment variable.
|
||||
my @prog = ($path_builder->(shift @cmdarray));
|
||||
my $first = shift @prog;
|
||||
my $exe_shell = @prog ? undef : $ENV{EXE_SHELL};
|
||||
my $cmd = __fixup_cmd($first, $exe_shell);
|
||||
if (@prog) {
|
||||
if ( ! -f $prog[0] ) {
|
||||
print STDERR "$prog[0] not found\n";
|
||||
$cmd = undef;
|
||||
}
|
||||
}
|
||||
my @args = (@prog, @cmdarray);
|
||||
if (defined($opts{interpreter_args})) {
|
||||
unshift @args, @{$opts{interpreter_args}};
|
||||
}
|
||||
|
||||
return () if !$cmd;
|
||||
|
||||
my $arg_str = "";
|
||||
my $cmdstr = join(" ", @$cmd);
|
||||
my $null = devnull();
|
||||
|
||||
|
||||
$arg_str = " ".join(" ", quotify @args) if @args;
|
||||
|
||||
my $fileornull = sub { $_[0] ? $_[0] : $null; };
|
||||
my $stdin = "";
|
||||
my $stdout = "";
|
||||
@@ -1022,19 +1128,19 @@ sub __build_cmd {
|
||||
$stdout= " > ".$fileornull->($opts{stdout}) if exists($opts{stdout});
|
||||
$stderr=" 2> ".$fileornull->($opts{stderr}) if exists($opts{stderr});
|
||||
|
||||
my $display_cmd = "$cmd$arg_str$stdin$stdout$stderr";
|
||||
my $display_cmd = "$cmdstr$stdin$stdout$stderr";
|
||||
|
||||
$stderr=" 2> ".$null
|
||||
unless $stderr || !$ENV{HARNESS_ACTIVE} || $ENV{HARNESS_VERBOSE};
|
||||
|
||||
$cmd .= "$arg_str$stdin$stdout$stderr";
|
||||
$cmdstr .= "$stdin$stdout$stderr";
|
||||
|
||||
if ($debug) {
|
||||
print STDERR "DEBUG[__build_cmd]: \$cmd = \"$cmd\"\n";
|
||||
print STDERR "DEBUG[__build_cmd]: \$display_cmd = \"$display_cmd\"\n";
|
||||
print STDERR "DEBUG[__decorate_cmd]: \$cmdstr = \"$cmdstr\"\n";
|
||||
print STDERR "DEBUG[__decorate_cmd]: \$display_cmd = \"$display_cmd\"\n";
|
||||
}
|
||||
|
||||
return ($cmd, $display_cmd);
|
||||
return ($cmdstr, $display_cmd);
|
||||
}
|
||||
|
||||
=head1 SEE ALSO
|
||||
@@ -1043,9 +1149,18 @@ L<Test::More>, L<Test::Harness>
|
||||
|
||||
=head1 AUTHORS
|
||||
|
||||
Richard Levitte E<lt>levitte@openssl.orgE<gt> with assitance and
|
||||
Richard Levitte E<lt>levitte@openssl.orgE<gt> with assistance and
|
||||
inspiration from Andy Polyakov E<lt>appro@openssl.org<gt>.
|
||||
|
||||
=cut
|
||||
|
||||
no warnings 'redefine';
|
||||
sub subtest {
|
||||
$level++;
|
||||
|
||||
Test::More::subtest @_;
|
||||
|
||||
$level--;
|
||||
};
|
||||
|
||||
1;
|
||||
@@ -53,11 +53,8 @@ The additional hash is for extra parameters:
|
||||
|
||||
=item B<section =E<gt> N>
|
||||
|
||||
The value MUST be a number, and will be the default man section number
|
||||
to be used with the given .pod file. This number can be altered if
|
||||
the .pod file has a line like this:
|
||||
|
||||
=for comment openssl_manual_section: 4
|
||||
The value MUST be a number, and will be the man section number
|
||||
to be used with the given .pod file.
|
||||
|
||||
=item B<debug =E<gt> 0|1>
|
||||
|
||||
@@ -109,12 +106,6 @@ sub extract_pod_info {
|
||||
my %podinfo = ( section => $defaults{section});
|
||||
while(<$input>) {
|
||||
s|\R$||;
|
||||
if (m|^=for\s+comment\s+openssl_manual_section:\s*([0-9])\s*$|) {
|
||||
print STDERR "DEBUG: Found man section number $1\n"
|
||||
if $defaults{debug};
|
||||
$podinfo{section} = $1;
|
||||
}
|
||||
|
||||
# Stop reading when we have reached past the NAME section.
|
||||
last if (m|^=head1|
|
||||
&& defined $podinfo{lastsect}
|
||||
|
||||
@@ -0,0 +1,219 @@
|
||||
# Copyright 2016 The OpenSSL Project Authors. All Rights Reserved.
|
||||
#
|
||||
# Licensed under the OpenSSL license (the "License"). You may not use
|
||||
# this file except in compliance with the License. You can obtain a copy
|
||||
# in the file LICENSE in the source distribution or at
|
||||
# https://www.openssl.org/source/license.html
|
||||
|
||||
use strict;
|
||||
|
||||
package TLSProxy::Certificate;
|
||||
|
||||
use vars '@ISA';
|
||||
push @ISA, 'TLSProxy::Message';
|
||||
|
||||
sub new
|
||||
{
|
||||
my $class = shift;
|
||||
my ($server,
|
||||
$data,
|
||||
$records,
|
||||
$startoffset,
|
||||
$message_frag_lens) = @_;
|
||||
|
||||
my $self = $class->SUPER::new(
|
||||
$server,
|
||||
TLSProxy::Message::MT_CERTIFICATE,
|
||||
$data,
|
||||
$records,
|
||||
$startoffset,
|
||||
$message_frag_lens);
|
||||
|
||||
$self->{first_certificate} = "";
|
||||
$self->{extension_data} = "";
|
||||
$self->{remaining_certdata} = "";
|
||||
|
||||
return $self;
|
||||
}
|
||||
|
||||
sub parse
|
||||
{
|
||||
my $self = shift;
|
||||
|
||||
if (TLSProxy::Proxy->is_tls13()) {
|
||||
my $context_len = unpack('C', $self->data);
|
||||
my $context = substr($self->data, 1, $context_len);
|
||||
|
||||
my $remdata = substr($self->data, 1 + $context_len);
|
||||
|
||||
my ($hicertlistlen, $certlistlen) = unpack('Cn', $remdata);
|
||||
$certlistlen += ($hicertlistlen << 16);
|
||||
|
||||
$remdata = substr($remdata, 3);
|
||||
|
||||
die "Invalid Certificate List length"
|
||||
if length($remdata) != $certlistlen;
|
||||
|
||||
my ($hicertlen, $certlen) = unpack('Cn', $remdata);
|
||||
$certlen += ($hicertlen << 16);
|
||||
|
||||
die "Certificate too long" if ($certlen + 3) > $certlistlen;
|
||||
|
||||
$remdata = substr($remdata, 3);
|
||||
|
||||
my $certdata = substr($remdata, 0, $certlen);
|
||||
|
||||
$remdata = substr($remdata, $certlen);
|
||||
|
||||
my $extensions_len = unpack('n', $remdata);
|
||||
$remdata = substr($remdata, 2);
|
||||
|
||||
die "Extensions too long"
|
||||
if ($certlen + 3 + $extensions_len + 2) > $certlistlen;
|
||||
|
||||
my $extension_data = "";
|
||||
if ($extensions_len != 0) {
|
||||
$extension_data = substr($remdata, 0, $extensions_len);
|
||||
|
||||
if (length($extension_data) != $extensions_len) {
|
||||
die "Invalid extension length\n";
|
||||
}
|
||||
}
|
||||
my %extensions = ();
|
||||
while (length($extension_data) >= 4) {
|
||||
my ($type, $size) = unpack("nn", $extension_data);
|
||||
my $extdata = substr($extension_data, 4, $size);
|
||||
$extension_data = substr($extension_data, 4 + $size);
|
||||
$extensions{$type} = $extdata;
|
||||
}
|
||||
$remdata = substr($remdata, $extensions_len);
|
||||
|
||||
$self->context($context);
|
||||
$self->first_certificate($certdata);
|
||||
$self->extension_data(\%extensions);
|
||||
$self->remaining_certdata($remdata);
|
||||
|
||||
print " Context:".$context."\n";
|
||||
print " Certificate List Len:".$certlistlen."\n";
|
||||
print " Certificate Len:".$certlen."\n";
|
||||
print " Extensions Len:".$extensions_len."\n";
|
||||
} else {
|
||||
my ($hicertlistlen, $certlistlen) = unpack('Cn', $self->data);
|
||||
$certlistlen += ($hicertlistlen << 16);
|
||||
|
||||
my $remdata = substr($self->data, 3);
|
||||
|
||||
die "Invalid Certificate List length"
|
||||
if length($remdata) != $certlistlen;
|
||||
|
||||
my ($hicertlen, $certlen) = unpack('Cn', $remdata);
|
||||
$certlen += ($hicertlen << 16);
|
||||
|
||||
die "Certificate too long" if ($certlen + 3) > $certlistlen;
|
||||
|
||||
$remdata = substr($remdata, 3);
|
||||
|
||||
my $certdata = substr($remdata, 0, $certlen);
|
||||
|
||||
$remdata = substr($remdata, $certlen);
|
||||
|
||||
$self->first_certificate($certdata);
|
||||
$self->remaining_certdata($remdata);
|
||||
|
||||
print " Certificate List Len:".$certlistlen."\n";
|
||||
print " Certificate Len:".$certlen."\n";
|
||||
}
|
||||
}
|
||||
|
||||
#Reconstruct the on-the-wire message data following changes
|
||||
sub set_message_contents
|
||||
{
|
||||
my $self = shift;
|
||||
my $data;
|
||||
my $extensions = "";
|
||||
|
||||
if (TLSProxy::Proxy->is_tls13()) {
|
||||
foreach my $key (keys %{$self->extension_data}) {
|
||||
my $extdata = ${$self->extension_data}{$key};
|
||||
$extensions .= pack("n", $key);
|
||||
$extensions .= pack("n", length($extdata));
|
||||
$extensions .= $extdata;
|
||||
if ($key == TLSProxy::Message::EXT_DUPLICATE_EXTENSION) {
|
||||
$extensions .= pack("n", $key);
|
||||
$extensions .= pack("n", length($extdata));
|
||||
$extensions .= $extdata;
|
||||
}
|
||||
}
|
||||
$data = pack('C', length($self->context()));
|
||||
$data .= $self->context;
|
||||
my $certlen = length($self->first_certificate);
|
||||
my $certlistlen = $certlen + length($extensions)
|
||||
+ length($self->remaining_certdata);
|
||||
my $hi = $certlistlen >> 16;
|
||||
$certlistlen = $certlistlen & 0xffff;
|
||||
$data .= pack('Cn', $hi, $certlistlen);
|
||||
$hi = $certlen >> 16;
|
||||
$certlen = $certlen & 0xffff;
|
||||
$data .= pack('Cn', $hi, $certlen);
|
||||
$data .= pack('n', length($extensions));
|
||||
$data .= $extensions;
|
||||
$data .= $self->remaining_certdata();
|
||||
$self->data($data);
|
||||
} else {
|
||||
my $certlen = length($self->first_certificate);
|
||||
my $certlistlen = $certlen + length($self->remaining_certdata);
|
||||
my $hi = $certlistlen >> 16;
|
||||
$certlistlen = $certlistlen & 0xffff;
|
||||
$data .= pack('Cn', $hi, $certlistlen);
|
||||
$hi = $certlen >> 16;
|
||||
$certlen = $certlen & 0xffff;
|
||||
$data .= pack('Cn', $hi, $certlen);
|
||||
$data .= $self->remaining_certdata();
|
||||
$self->data($data);
|
||||
}
|
||||
}
|
||||
|
||||
#Read/write accessors
|
||||
sub context
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{context} = shift;
|
||||
}
|
||||
return $self->{context};
|
||||
}
|
||||
sub first_certificate
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{first_certificate} = shift;
|
||||
}
|
||||
return $self->{first_certificate};
|
||||
}
|
||||
sub remaining_certdata
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{remaining_certdata} = shift;
|
||||
}
|
||||
return $self->{remaining_certdata};
|
||||
}
|
||||
sub extension_data
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{extension_data} = shift;
|
||||
}
|
||||
return $self->{extension_data};
|
||||
}
|
||||
sub set_extension
|
||||
{
|
||||
my ($self, $ext_type, $ext_data) = @_;
|
||||
$self->{extension_data}{$ext_type} = $ext_data;
|
||||
}
|
||||
sub delete_extension
|
||||
{
|
||||
my ($self, $ext_type) = @_;
|
||||
delete $self->{extension_data}{$ext_type};
|
||||
}
|
||||
1;
|
||||
@@ -0,0 +1,96 @@
|
||||
# Copyright 2016 The OpenSSL Project Authors. All Rights Reserved.
|
||||
#
|
||||
# Licensed under the OpenSSL license (the "License"). You may not use
|
||||
# this file except in compliance with the License. You can obtain a copy
|
||||
# in the file LICENSE in the source distribution or at
|
||||
# https://www.openssl.org/source/license.html
|
||||
|
||||
use strict;
|
||||
|
||||
package TLSProxy::CertificateVerify;
|
||||
|
||||
use vars '@ISA';
|
||||
push @ISA, 'TLSProxy::Message';
|
||||
|
||||
sub new
|
||||
{
|
||||
my $class = shift;
|
||||
my ($server,
|
||||
$data,
|
||||
$records,
|
||||
$startoffset,
|
||||
$message_frag_lens) = @_;
|
||||
|
||||
my $self = $class->SUPER::new(
|
||||
$server,
|
||||
TLSProxy::Message::MT_CERTIFICATE_VERIFY,
|
||||
$data,
|
||||
$records,
|
||||
$startoffset,
|
||||
$message_frag_lens);
|
||||
|
||||
$self->{sigalg} = -1;
|
||||
$self->{signature} = "";
|
||||
|
||||
return $self;
|
||||
}
|
||||
|
||||
sub parse
|
||||
{
|
||||
my $self = shift;
|
||||
|
||||
my $sigalg = -1;
|
||||
my $remdata = $self->data;
|
||||
my $record = ${$self->records}[0];
|
||||
|
||||
if (TLSProxy::Proxy->is_tls13()
|
||||
|| $record->version() == TLSProxy::Record::VERS_TLS_1_2) {
|
||||
$sigalg = unpack('n', $remdata);
|
||||
$remdata = substr($remdata, 2);
|
||||
}
|
||||
|
||||
my $siglen = unpack('n', substr($remdata, 0, 2));
|
||||
my $sig = substr($remdata, 2);
|
||||
|
||||
die "Invalid CertificateVerify signature length" if length($sig) != $siglen;
|
||||
|
||||
print " SigAlg:".$sigalg."\n";
|
||||
print " Signature Len:".$siglen."\n";
|
||||
|
||||
$self->sigalg($sigalg);
|
||||
$self->signature($sig);
|
||||
}
|
||||
|
||||
#Reconstruct the on-the-wire message data following changes
|
||||
sub set_message_contents
|
||||
{
|
||||
my $self = shift;
|
||||
my $data = "";
|
||||
my $sig = $self->signature();
|
||||
my $olddata = $self->data();
|
||||
|
||||
$data .= pack("n", $self->sigalg()) if ($self->sigalg() != -1);
|
||||
$data .= pack("n", length($sig));
|
||||
$data .= $sig;
|
||||
|
||||
$self->data($data);
|
||||
}
|
||||
|
||||
#Read/write accessors
|
||||
sub sigalg
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{sigalg} = shift;
|
||||
}
|
||||
return $self->{sigalg};
|
||||
}
|
||||
sub signature
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{signature} = shift;
|
||||
}
|
||||
return $self->{signature};
|
||||
}
|
||||
1;
|
||||
@@ -114,6 +114,24 @@ sub process_extensions
|
||||
}
|
||||
}
|
||||
|
||||
sub extension_contents
|
||||
{
|
||||
my $self = shift;
|
||||
my $key = shift;
|
||||
my $extension = "";
|
||||
|
||||
my $extdata = ${$self->extension_data}{$key};
|
||||
$extension .= pack("n", $key);
|
||||
$extension .= pack("n", length($extdata));
|
||||
$extension .= $extdata;
|
||||
if ($key == TLSProxy::Message::EXT_DUPLICATE_EXTENSION) {
|
||||
$extension .= pack("n", $key);
|
||||
$extension .= pack("n", length($extdata));
|
||||
$extension .= $extdata;
|
||||
}
|
||||
return $extension;
|
||||
}
|
||||
|
||||
#Reconstruct the on-the-wire message data following changes
|
||||
sub set_message_contents
|
||||
{
|
||||
@@ -131,15 +149,16 @@ sub set_message_contents
|
||||
$data .= pack("C*", @{$self->comp_meths});
|
||||
|
||||
foreach my $key (keys %{$self->extension_data}) {
|
||||
my $extdata = ${$self->extension_data}{$key};
|
||||
$extensions .= pack("n", $key);
|
||||
$extensions .= pack("n", length($extdata));
|
||||
$extensions .= $extdata;
|
||||
if ($key == TLSProxy::Message::EXT_DUPLICATE_EXTENSION) {
|
||||
$extensions .= pack("n", $key);
|
||||
$extensions .= pack("n", length($extdata));
|
||||
$extensions .= $extdata;
|
||||
}
|
||||
next if ($key == TLSProxy::Message::EXT_PSK);
|
||||
$extensions .= $self->extension_contents($key);
|
||||
}
|
||||
#PSK extension always goes last...
|
||||
if (defined ${$self->extension_data}{TLSProxy::Message::EXT_PSK}) {
|
||||
$extensions .= $self->extension_contents(TLSProxy::Message::EXT_PSK);
|
||||
}
|
||||
#unless we have EXT_FORCE_LAST
|
||||
if (defined ${$self->extension_data}{TLSProxy::Message::EXT_FORCE_LAST}) {
|
||||
$extensions .= $self->extension_contents(TLSProxy::Message::EXT_FORCE_LAST);
|
||||
}
|
||||
|
||||
$data .= pack('n', length($extensions));
|
||||
|
||||
@@ -0,0 +1,115 @@
|
||||
# Copyright 2016 The OpenSSL Project Authors. All Rights Reserved.
|
||||
#
|
||||
# Licensed under the OpenSSL license (the "License"). You may not use
|
||||
# this file except in compliance with the License. You can obtain a copy
|
||||
# in the file LICENSE in the source distribution or at
|
||||
# https://www.openssl.org/source/license.html
|
||||
|
||||
use strict;
|
||||
|
||||
package TLSProxy::EncryptedExtensions;
|
||||
|
||||
use vars '@ISA';
|
||||
push @ISA, 'TLSProxy::Message';
|
||||
|
||||
sub new
|
||||
{
|
||||
my $class = shift;
|
||||
my ($server,
|
||||
$data,
|
||||
$records,
|
||||
$startoffset,
|
||||
$message_frag_lens) = @_;
|
||||
|
||||
my $self = $class->SUPER::new(
|
||||
$server,
|
||||
TLSProxy::Message::MT_ENCRYPTED_EXTENSIONS,
|
||||
$data,
|
||||
$records,
|
||||
$startoffset,
|
||||
$message_frag_lens);
|
||||
|
||||
$self->{extension_data} = "";
|
||||
|
||||
return $self;
|
||||
}
|
||||
|
||||
sub parse
|
||||
{
|
||||
my $self = shift;
|
||||
|
||||
my $extensions_len = unpack('n', $self->data);
|
||||
if (!defined $extensions_len) {
|
||||
$extensions_len = 0;
|
||||
}
|
||||
|
||||
my $extension_data;
|
||||
if ($extensions_len != 0) {
|
||||
$extension_data = substr($self->data, 2);
|
||||
|
||||
if (length($extension_data) != $extensions_len) {
|
||||
die "Invalid extension length\n";
|
||||
}
|
||||
} else {
|
||||
if (length($self->data) != 2) {
|
||||
die "Invalid extension length\n";
|
||||
}
|
||||
$extension_data = "";
|
||||
}
|
||||
my %extensions = ();
|
||||
while (length($extension_data) >= 4) {
|
||||
my ($type, $size) = unpack("nn", $extension_data);
|
||||
my $extdata = substr($extension_data, 4, $size);
|
||||
$extension_data = substr($extension_data, 4 + $size);
|
||||
$extensions{$type} = $extdata;
|
||||
}
|
||||
|
||||
$self->extension_data(\%extensions);
|
||||
|
||||
print " Extensions Len:".$extensions_len."\n";
|
||||
}
|
||||
|
||||
#Reconstruct the on-the-wire message data following changes
|
||||
sub set_message_contents
|
||||
{
|
||||
my $self = shift;
|
||||
my $data;
|
||||
my $extensions = "";
|
||||
|
||||
foreach my $key (keys %{$self->extension_data}) {
|
||||
my $extdata = ${$self->extension_data}{$key};
|
||||
$extensions .= pack("n", $key);
|
||||
$extensions .= pack("n", length($extdata));
|
||||
$extensions .= $extdata;
|
||||
if ($key == TLSProxy::Message::EXT_DUPLICATE_EXTENSION) {
|
||||
$extensions .= pack("n", $key);
|
||||
$extensions .= pack("n", length($extdata));
|
||||
$extensions .= $extdata;
|
||||
}
|
||||
}
|
||||
|
||||
$data = pack('n', length($extensions));
|
||||
$data .= $extensions;
|
||||
$self->data($data);
|
||||
}
|
||||
|
||||
#Read/write accessors
|
||||
sub extension_data
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{extension_data} = shift;
|
||||
}
|
||||
return $self->{extension_data};
|
||||
}
|
||||
sub set_extension
|
||||
{
|
||||
my ($self, $ext_type, $ext_data) = @_;
|
||||
$self->{extension_data}{$ext_type} = $ext_data;
|
||||
}
|
||||
sub delete_extension
|
||||
{
|
||||
my ($self, $ext_type) = @_;
|
||||
delete $self->{extension_data}{$ext_type};
|
||||
}
|
||||
1;
|
||||
+120
-12
@@ -1,4 +1,4 @@
|
||||
# Copyright 2016 The OpenSSL Project Authors. All Rights Reserved.
|
||||
# Copyright 2016-2018 The OpenSSL Project Authors. All Rights Reserved.
|
||||
#
|
||||
# Licensed under the OpenSSL license (the "License"). You may not use
|
||||
# this file except in compliance with the License. You can obtain a copy
|
||||
@@ -17,6 +17,7 @@ use constant {
|
||||
MT_CLIENT_HELLO => 1,
|
||||
MT_SERVER_HELLO => 2,
|
||||
MT_NEW_SESSION_TICKET => 4,
|
||||
MT_ENCRYPTED_EXTENSIONS => 8,
|
||||
MT_CERTIFICATE => 11,
|
||||
MT_SERVER_KEY_EXCHANGE => 12,
|
||||
MT_CERTIFICATE_REQUEST => 13,
|
||||
@@ -46,6 +47,7 @@ my %message_type = (
|
||||
MT_CLIENT_HELLO, "ClientHello",
|
||||
MT_SERVER_HELLO, "ServerHello",
|
||||
MT_NEW_SESSION_TICKET, "NewSessionTicket",
|
||||
MT_ENCRYPTED_EXTENSIONS, "EncryptedExtensions",
|
||||
MT_CERTIFICATE, "Certificate",
|
||||
MT_SERVER_KEY_EXCHANGE, "ServerKeyExchange",
|
||||
MT_CERTIFICATE_REQUEST, "CertificateRequest",
|
||||
@@ -58,13 +60,70 @@ my %message_type = (
|
||||
);
|
||||
|
||||
use constant {
|
||||
EXT_SERVER_NAME => 0,
|
||||
EXT_MAX_FRAGMENT_LENGTH => 1,
|
||||
EXT_STATUS_REQUEST => 5,
|
||||
EXT_SUPPORTED_GROUPS => 10,
|
||||
EXT_EC_POINT_FORMATS => 11,
|
||||
EXT_SRP => 12,
|
||||
EXT_SIG_ALGS => 13,
|
||||
EXT_USE_SRTP => 14,
|
||||
EXT_ALPN => 16,
|
||||
EXT_SCT => 18,
|
||||
EXT_PADDING => 21,
|
||||
EXT_ENCRYPT_THEN_MAC => 22,
|
||||
EXT_EXTENDED_MASTER_SECRET => 23,
|
||||
EXT_SESSION_TICKET => 35,
|
||||
# This extension does not exist and isn't recognised by OpenSSL.
|
||||
# We use it to test handling of duplicate extensions.
|
||||
EXT_DUPLICATE_EXTENSION => 1234
|
||||
EXT_KEY_SHARE => 51,
|
||||
EXT_PSK => 41,
|
||||
EXT_SUPPORTED_VERSIONS => 43,
|
||||
EXT_COOKIE => 44,
|
||||
EXT_PSK_KEX_MODES => 45,
|
||||
EXT_POST_HANDSHAKE_AUTH => 49,
|
||||
EXT_SIG_ALGS_CERT => 50,
|
||||
EXT_RENEGOTIATE => 65281,
|
||||
EXT_NPN => 13172,
|
||||
# This extension is an unofficial extension only ever written by OpenSSL
|
||||
# (i.e. not read), and even then only when enabled. We use it to test
|
||||
# handling of duplicate extensions.
|
||||
EXT_DUPLICATE_EXTENSION => 0xfde8,
|
||||
EXT_UNKNOWN => 0xfffe,
|
||||
#Unknown extension that should appear last
|
||||
EXT_FORCE_LAST => 0xffff
|
||||
};
|
||||
|
||||
# SignatureScheme of TLS 1.3, from
|
||||
# https://tools.ietf.org/html/draft-ietf-tls-tls13-20#appendix-B.3.1.3
|
||||
# TODO(TLS1.3) update link to IANA registry after publication
|
||||
# We have to manually grab the SHA224 equivalents from the old registry
|
||||
use constant {
|
||||
SIG_ALG_RSA_PKCS1_SHA256 => 0x0401,
|
||||
SIG_ALG_RSA_PKCS1_SHA384 => 0x0501,
|
||||
SIG_ALG_RSA_PKCS1_SHA512 => 0x0601,
|
||||
SIG_ALG_ECDSA_SECP256R1_SHA256 => 0x0403,
|
||||
SIG_ALG_ECDSA_SECP384R1_SHA384 => 0x0503,
|
||||
SIG_ALG_ECDSA_SECP521R1_SHA512 => 0x0603,
|
||||
SIG_ALG_RSA_PSS_SHA256 => 0x0804,
|
||||
SIG_ALG_RSA_PSS_SHA384 => 0x0805,
|
||||
SIG_ALG_RSA_PSS_SHA512 => 0x0806,
|
||||
SIG_ALG_ED25519 => 0x0807,
|
||||
SIG_ALG_ED448 => 0x0808,
|
||||
SIG_ALG_RSA_PKCS1_SHA1 => 0x0201,
|
||||
SIG_ALG_ECDSA_SHA1 => 0x0203,
|
||||
SIG_ALG_DSA_SHA1 => 0x0202,
|
||||
SIG_ALG_DSA_SHA256 => 0x0402,
|
||||
SIG_ALG_DSA_SHA384 => 0x0502,
|
||||
SIG_ALG_DSA_SHA512 => 0x0602,
|
||||
OSSL_SIG_ALG_RSA_PKCS1_SHA224 => 0x0301,
|
||||
OSSL_SIG_ALG_DSA_SHA224 => 0x0302,
|
||||
OSSL_SIG_ALG_ECDSA_SHA224 => 0x0303
|
||||
};
|
||||
|
||||
use constant {
|
||||
CIPHER_DHE_RSA_AES_128_SHA => 0x0033,
|
||||
CIPHER_ADH_AES_128_SHA => 0x0034,
|
||||
CIPHER_TLS13_AES_128_GCM_SHA256 => 0x1301,
|
||||
CIPHER_TLS13_AES_256_GCM_SHA384 => 0x1302
|
||||
};
|
||||
|
||||
my $payload = "";
|
||||
@@ -77,6 +136,7 @@ my $end = 0;
|
||||
my @message_rec_list = ();
|
||||
my @message_frag_lens = ();
|
||||
my $ciphersuite = 0;
|
||||
my $successondata = 0;
|
||||
|
||||
sub clear
|
||||
{
|
||||
@@ -86,6 +146,7 @@ sub clear
|
||||
$server = 0;
|
||||
$success = 0;
|
||||
$end = 0;
|
||||
$successondata = 0;
|
||||
@message_rec_list = ();
|
||||
@message_frag_lens = ();
|
||||
}
|
||||
@@ -111,10 +172,12 @@ sub get_messages
|
||||
#We can't handle this yet
|
||||
die "CCS received before message data complete\n";
|
||||
}
|
||||
if ($server) {
|
||||
TLSProxy::Record->server_ccs_seen(1);
|
||||
} else {
|
||||
TLSProxy::Record->client_ccs_seen(1);
|
||||
if (!TLSProxy::Proxy->is_tls13()) {
|
||||
if ($server) {
|
||||
TLSProxy::Record->server_encrypting(1);
|
||||
} else {
|
||||
TLSProxy::Record->client_encrypting(1);
|
||||
}
|
||||
}
|
||||
} elsif ($record->content_type == TLSProxy::Record::RT_HANDSHAKE) {
|
||||
if ($record->len == 0 || $record->len_real == 0) {
|
||||
@@ -197,6 +260,11 @@ sub get_messages
|
||||
} elsif ($record->content_type == TLSProxy::Record::RT_APPLICATION_DATA) {
|
||||
print " [ENCRYPTED APPLICATION DATA]\n";
|
||||
print " [".$record->decrypt_data."]\n";
|
||||
|
||||
if ($successondata) {
|
||||
$success = 1;
|
||||
$end = 1;
|
||||
}
|
||||
} elsif ($record->content_type == TLSProxy::Record::RT_ALERT) {
|
||||
my ($alertlev, $alertdesc) = unpack('CC', $record->decrypt_data);
|
||||
#A CloseNotify from the client indicates we have finished successfully
|
||||
@@ -239,6 +307,33 @@ sub create_message
|
||||
[@message_frag_lens]
|
||||
);
|
||||
$message->parse();
|
||||
} elsif ($mt == MT_ENCRYPTED_EXTENSIONS) {
|
||||
$message = TLSProxy::EncryptedExtensions->new(
|
||||
$server,
|
||||
$data,
|
||||
[@message_rec_list],
|
||||
$startoffset,
|
||||
[@message_frag_lens]
|
||||
);
|
||||
$message->parse();
|
||||
} elsif ($mt == MT_CERTIFICATE) {
|
||||
$message = TLSProxy::Certificate->new(
|
||||
$server,
|
||||
$data,
|
||||
[@message_rec_list],
|
||||
$startoffset,
|
||||
[@message_frag_lens]
|
||||
);
|
||||
$message->parse();
|
||||
} elsif ($mt == MT_CERTIFICATE_VERIFY) {
|
||||
$message = TLSProxy::CertificateVerify->new(
|
||||
$server,
|
||||
$data,
|
||||
[@message_rec_list],
|
||||
$startoffset,
|
||||
[@message_frag_lens]
|
||||
);
|
||||
$message->parse();
|
||||
} elsif ($mt == MT_SERVER_KEY_EXCHANGE) {
|
||||
$message = TLSProxy::ServerKeyExchange->new(
|
||||
$server,
|
||||
@@ -319,7 +414,7 @@ sub ciphersuite
|
||||
}
|
||||
|
||||
#Update all the underlying records with the modified data from this message
|
||||
#Note: Does not currently support re-encrypting
|
||||
#Note: Only supports re-encrypting for TLSv1.3
|
||||
sub repack
|
||||
{
|
||||
my $self = shift;
|
||||
@@ -362,8 +457,14 @@ sub repack
|
||||
# use an explicit override field instead.)
|
||||
$rec->decrypt_len(length($rec->decrypt_data));
|
||||
$rec->len($rec->len + length($msgdata) - $old_length);
|
||||
# Don't support re-encryption.
|
||||
$rec->data($rec->decrypt_data);
|
||||
# Only support re-encryption for TLSv1.3.
|
||||
if (TLSProxy::Proxy->is_tls13() && $rec->encrypted()) {
|
||||
#Add content type (1 byte) and 16 tag bytes
|
||||
$rec->data($rec->decrypt_data
|
||||
.pack("C", TLSProxy::Record::RT_HANDSHAKE).("\0"x16));
|
||||
} else {
|
||||
$rec->data($rec->decrypt_data);
|
||||
}
|
||||
|
||||
#Update the fragment len in case we changed it above
|
||||
${$self->message_frag_lens}[0] = length($msgdata)
|
||||
@@ -452,5 +553,12 @@ sub encoded_length
|
||||
my $self = shift;
|
||||
return TLS_MESSAGE_HEADER_LENGTH + length($self->data);
|
||||
}
|
||||
|
||||
sub successondata
|
||||
{
|
||||
my $class = shift;
|
||||
if (@_) {
|
||||
$successondata = shift;
|
||||
}
|
||||
return $successondata;
|
||||
}
|
||||
1;
|
||||
+89
-38
@@ -17,6 +17,9 @@ use TLSProxy::Record;
|
||||
use TLSProxy::Message;
|
||||
use TLSProxy::ClientHello;
|
||||
use TLSProxy::ServerHello;
|
||||
use TLSProxy::EncryptedExtensions;
|
||||
use TLSProxy::Certificate;
|
||||
use TLSProxy::CertificateVerify;
|
||||
use TLSProxy::ServerKeyExchange;
|
||||
use TLSProxy::NewSessionTicket;
|
||||
use Time::HiRes qw/usleep/;
|
||||
@@ -24,6 +27,9 @@ use Time::HiRes qw/usleep/;
|
||||
my $have_IPv6 = 0;
|
||||
my $IP_factory;
|
||||
|
||||
my $is_tls13 = 0;
|
||||
my $ciphersuite = undef;
|
||||
|
||||
sub new
|
||||
{
|
||||
my $class = shift;
|
||||
@@ -45,16 +51,15 @@ sub new
|
||||
serverpid => 0,
|
||||
clientpid => 0,
|
||||
reneg => 0,
|
||||
sessionfile => undef,
|
||||
|
||||
#Public read
|
||||
execute => $execute,
|
||||
cert => $cert,
|
||||
debug => $debug,
|
||||
cipherc => "",
|
||||
ciphers => "AES128-SHA",
|
||||
flight => -1,
|
||||
direction => -1,
|
||||
partial => ["", ""],
|
||||
ciphers => "AES128-SHA:TLS13-AES-128-GCM-SHA256",
|
||||
flight => 0,
|
||||
record_list => [],
|
||||
message_list => [],
|
||||
};
|
||||
@@ -130,13 +135,14 @@ sub clearClient
|
||||
my $self = shift;
|
||||
|
||||
$self->{cipherc} = "";
|
||||
$self->{flight} = -1;
|
||||
$self->{direction} = -1;
|
||||
$self->{partial} = ["", ""];
|
||||
$self->{flight} = 0;
|
||||
$self->{record_list} = [];
|
||||
$self->{message_list} = [];
|
||||
$self->{clientflags} = "";
|
||||
$self->{sessionfile} = undef;
|
||||
$self->{clientpid} = 0;
|
||||
$is_tls13 = 0;
|
||||
$ciphersuite = undef;
|
||||
|
||||
TLSProxy::Message->clear();
|
||||
TLSProxy::Record->clear();
|
||||
@@ -147,7 +153,7 @@ sub clear
|
||||
my $self = shift;
|
||||
|
||||
$self->clearClient;
|
||||
$self->{ciphers} = "AES128-SHA";
|
||||
$self->{ciphers} = "AES128-SHA:TLS13-AES-128-GCM-SHA256";
|
||||
$self->{serverflags} = "";
|
||||
$self->{serverconnects} = 1;
|
||||
$self->{serverpid} = 0;
|
||||
@@ -182,9 +188,10 @@ sub start
|
||||
$pid = fork();
|
||||
if ($pid == 0) {
|
||||
my $execcmd = $self->execute
|
||||
." s_server -max_protocol TLSv1.2 -no_comp -rev -engine ossltest -accept "
|
||||
." s_server -no_comp -rev -engine ossltest -accept "
|
||||
.($self->server_port)
|
||||
." -cert ".$self->cert." -naccept ".$self->serverconnects;
|
||||
." -cert ".$self->cert." -cert2 ".$self->cert
|
||||
." -naccept ".$self->serverconnects;
|
||||
unless ($self->supports_IPv6) {
|
||||
$execcmd .= " -4";
|
||||
}
|
||||
@@ -219,7 +226,7 @@ sub clientstart
|
||||
$echostr = "test";
|
||||
}
|
||||
my $execcmd = "echo ".$echostr." | ".$self->execute
|
||||
." s_client -max_protocol TLSv1.2 -engine ossltest -connect "
|
||||
." s_client -engine ossltest -connect "
|
||||
.($self->proxy_addr).":".($self->proxy_port);
|
||||
unless ($self->supports_IPv6) {
|
||||
$execcmd .= " -4";
|
||||
@@ -230,6 +237,9 @@ sub clientstart
|
||||
if ($self->clientflags ne "") {
|
||||
$execcmd .= " ".$self->clientflags;
|
||||
}
|
||||
if (defined $self->sessionfile) {
|
||||
$execcmd .= " -ign_eof";
|
||||
}
|
||||
if ($self->debug) {
|
||||
print STDERR "Client command: $execcmd\n";
|
||||
}
|
||||
@@ -286,24 +296,35 @@ sub clientstart
|
||||
|
||||
#Wait for either the server socket or the client socket to become readable
|
||||
my @ready;
|
||||
my $ctr = 0;
|
||||
local $SIG{PIPE} = "IGNORE";
|
||||
while(!(TLSProxy::Message->end) && (@ready = $sel->can_read)) {
|
||||
while( (!(TLSProxy::Message->end)
|
||||
|| (defined $self->sessionfile()
|
||||
&& (-s $self->sessionfile()) == 0))
|
||||
&& $ctr < 10) {
|
||||
if (!(@ready = $sel->can_read(1))) {
|
||||
$ctr++;
|
||||
next;
|
||||
}
|
||||
foreach my $hand (@ready) {
|
||||
if ($hand == $server_sock) {
|
||||
$server_sock->sysread($indata, 16384) or goto END;
|
||||
$indata = $self->process_packet(1, $indata);
|
||||
$client_sock->syswrite($indata);
|
||||
$ctr = 0;
|
||||
} elsif ($hand == $client_sock) {
|
||||
$client_sock->sysread($indata, 16384) or goto END;
|
||||
$indata = $self->process_packet(0, $indata);
|
||||
$server_sock->syswrite($indata);
|
||||
$ctr = 0;
|
||||
} else {
|
||||
print "Err\n";
|
||||
goto END;
|
||||
die "Unexpected handle";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
die "No progress made" if $ctr >= 10;
|
||||
|
||||
END:
|
||||
print "Connection closed\n";
|
||||
if($server_sock) {
|
||||
@@ -348,38 +369,34 @@ sub process_packet
|
||||
print "Received client packet\n";
|
||||
}
|
||||
|
||||
if ($self->{direction} != $server) {
|
||||
$self->{flight} = $self->{flight} + 1;
|
||||
$self->{direction} = $server;
|
||||
}
|
||||
|
||||
print "Packet length = ".length($packet)."\n";
|
||||
print "Processing flight ".$self->flight."\n";
|
||||
|
||||
#Return contains the list of record found in the packet followed by the
|
||||
#list of messages in those records and any partial message
|
||||
my @ret = TLSProxy::Record->get_records($server, $self->flight, $self->{partial}[$server].$packet);
|
||||
$self->{partial}[$server] = $ret[2];
|
||||
#list of messages in those records
|
||||
my @ret = TLSProxy::Record->get_records($server, $self->flight, $packet);
|
||||
push @{$self->record_list}, @{$ret[0]};
|
||||
push @{$self->{message_list}}, @{$ret[1]};
|
||||
|
||||
print "\n";
|
||||
|
||||
if (scalar(@{$ret[0]}) == 0 or length($ret[2]) != 0) {
|
||||
return "";
|
||||
}
|
||||
|
||||
#Finished parsing. Call user provided filter here
|
||||
if (defined $self->filter) {
|
||||
if(defined $self->filter) {
|
||||
$self->filter->($self);
|
||||
}
|
||||
|
||||
#Reconstruct the packet
|
||||
$packet = "";
|
||||
foreach my $record (@{$self->record_list}) {
|
||||
$packet .= $record->reconstruct_record();
|
||||
#We only replay the records for the current flight
|
||||
if ($record->flight != $self->flight) {
|
||||
next;
|
||||
}
|
||||
$packet .= $record->reconstruct_record($server);
|
||||
}
|
||||
|
||||
$self->{flight} = $self->{flight} + 1;
|
||||
|
||||
print "Forwarded packet length = ".length($packet)."\n\n";
|
||||
|
||||
return $packet;
|
||||
@@ -442,7 +459,7 @@ sub server_addr
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{server_addr} = shift;
|
||||
$self->{server_addr} = shift;
|
||||
}
|
||||
return $self->{server_addr};
|
||||
}
|
||||
@@ -450,7 +467,7 @@ sub server_port
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{server_port} = shift;
|
||||
$self->{server_port} = shift;
|
||||
}
|
||||
return $self->{server_port};
|
||||
}
|
||||
@@ -458,7 +475,7 @@ sub filter
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{filter} = shift;
|
||||
$self->{filter} = shift;
|
||||
}
|
||||
return $self->{filter};
|
||||
}
|
||||
@@ -466,7 +483,7 @@ sub cipherc
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{cipherc} = shift;
|
||||
$self->{cipherc} = shift;
|
||||
}
|
||||
return $self->{cipherc};
|
||||
}
|
||||
@@ -474,7 +491,7 @@ sub ciphers
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{ciphers} = shift;
|
||||
$self->{ciphers} = shift;
|
||||
}
|
||||
return $self->{ciphers};
|
||||
}
|
||||
@@ -482,7 +499,7 @@ sub serverflags
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{serverflags} = shift;
|
||||
$self->{serverflags} = shift;
|
||||
}
|
||||
return $self->{serverflags};
|
||||
}
|
||||
@@ -490,7 +507,7 @@ sub clientflags
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{clientflags} = shift;
|
||||
$self->{clientflags} = shift;
|
||||
}
|
||||
return $self->{clientflags};
|
||||
}
|
||||
@@ -498,7 +515,7 @@ sub serverconnects
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{serverconnects} = shift;
|
||||
$self->{serverconnects} = shift;
|
||||
}
|
||||
return $self->{serverconnects};
|
||||
}
|
||||
@@ -518,7 +535,7 @@ sub serverpid
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{serverpid} = shift;
|
||||
$self->{serverpid} = shift;
|
||||
}
|
||||
return $self->{serverpid};
|
||||
}
|
||||
@@ -541,13 +558,47 @@ sub fill_known_data
|
||||
return $ret;
|
||||
}
|
||||
|
||||
sub is_tls13
|
||||
{
|
||||
my $class = shift;
|
||||
if (@_) {
|
||||
$is_tls13 = shift;
|
||||
}
|
||||
return $is_tls13;
|
||||
}
|
||||
|
||||
sub reneg
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{reneg} = shift;
|
||||
$self->{reneg} = shift;
|
||||
}
|
||||
return $self->{reneg};
|
||||
}
|
||||
|
||||
#Setting a sessionfile means that the client will not close until the given
|
||||
#file exists. This is useful in TLSv1.3 where otherwise s_client will close
|
||||
#immediately at the end of the handshake, but before the session has been
|
||||
#received from the server. A side effect of this is that s_client never sends
|
||||
#a close_notify, so instead we consider success to be when it sends application
|
||||
#data over the connection.
|
||||
sub sessionfile
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{sessionfile} = shift;
|
||||
TLSProxy::Message->successondata(1);
|
||||
}
|
||||
return $self->{sessionfile};
|
||||
}
|
||||
|
||||
sub ciphersuite
|
||||
{
|
||||
my $class = shift;
|
||||
if (@_) {
|
||||
$ciphersuite = shift;
|
||||
}
|
||||
return $ciphersuite;
|
||||
}
|
||||
|
||||
1;
|
||||
+109
-54
@@ -11,8 +11,8 @@ use TLSProxy::Proxy;
|
||||
|
||||
package TLSProxy::Record;
|
||||
|
||||
my $server_ccs_seen = 0;
|
||||
my $client_ccs_seen = 0;
|
||||
my $server_encrypting = 0;
|
||||
my $client_encrypting = 0;
|
||||
my $etm = 0;
|
||||
|
||||
use constant TLS_RECORD_HEADER_LENGTH => 5;
|
||||
@@ -35,12 +35,14 @@ my %record_type = (
|
||||
);
|
||||
|
||||
use constant {
|
||||
VERS_TLS_1_3 => 772,
|
||||
VERS_TLS_1_2 => 771,
|
||||
VERS_TLS_1_1 => 770,
|
||||
VERS_TLS_1_0 => 769,
|
||||
VERS_SSL_3_0 => 768,
|
||||
VERS_SSL_LT_3_0 => 767
|
||||
VERS_TLS_1_4 => 0x0305,
|
||||
VERS_TLS_1_3_DRAFT => 0x7f17,
|
||||
VERS_TLS_1_3 => 0x0304,
|
||||
VERS_TLS_1_2 => 0x0303,
|
||||
VERS_TLS_1_1 => 0x0302,
|
||||
VERS_TLS_1_0 => 0x0301,
|
||||
VERS_SSL_3_0 => 0x0300,
|
||||
VERS_SSL_LT_3_0 => 0x02ff
|
||||
};
|
||||
|
||||
my %tls_version = (
|
||||
@@ -59,7 +61,6 @@ sub get_records
|
||||
my $server = shift;
|
||||
my $flight = shift;
|
||||
my $packet = shift;
|
||||
my $partial = "";
|
||||
my @record_list = ();
|
||||
my @message_list = ();
|
||||
my $data;
|
||||
@@ -78,10 +79,8 @@ sub get_records
|
||||
print " (client -> server)\n";
|
||||
}
|
||||
#Get the record header
|
||||
if (length($packet) < TLS_RECORD_HEADER_LENGTH
|
||||
|| length($packet) < 5 + unpack("n", substr($packet, 3, 2))) {
|
||||
if (length($packet) < TLS_RECORD_HEADER_LENGTH) {
|
||||
print "Partial data : ".length($packet)." bytes\n";
|
||||
$partial = $packet;
|
||||
$packet = "";
|
||||
} else {
|
||||
($content_type, $version, $len) = unpack('CnnC*', $packet);
|
||||
@@ -110,12 +109,20 @@ sub get_records
|
||||
substr($packet, TLS_RECORD_HEADER_LENGTH, $len_real)
|
||||
);
|
||||
|
||||
if (($server && $server_ccs_seen)
|
||||
|| (!$server && $client_ccs_seen)) {
|
||||
if ($etm) {
|
||||
$record->decryptETM();
|
||||
} else {
|
||||
$record->decrypt();
|
||||
if ($content_type != RT_CCS) {
|
||||
if (($server && $server_encrypting)
|
||||
|| (!$server && $client_encrypting)) {
|
||||
if (!TLSProxy::Proxy->is_tls13() && $etm) {
|
||||
$record->decryptETM();
|
||||
} else {
|
||||
$record->decrypt();
|
||||
}
|
||||
$record->encrypted(1);
|
||||
|
||||
if (TLSProxy::Proxy->is_tls13()) {
|
||||
print " Inner content type: "
|
||||
.$record_type{$record->content_type()}."\n";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -130,31 +137,31 @@ sub get_records
|
||||
}
|
||||
}
|
||||
|
||||
return (\@record_list, \@message_list, $partial);
|
||||
return (\@record_list, \@message_list);
|
||||
}
|
||||
|
||||
sub clear
|
||||
{
|
||||
$server_ccs_seen = 0;
|
||||
$client_ccs_seen = 0;
|
||||
$server_encrypting = 0;
|
||||
$client_encrypting = 0;
|
||||
}
|
||||
|
||||
#Class level accessors
|
||||
sub server_ccs_seen
|
||||
sub server_encrypting
|
||||
{
|
||||
my $class = shift;
|
||||
if (@_) {
|
||||
$server_ccs_seen = shift;
|
||||
$server_encrypting = shift;
|
||||
}
|
||||
return $server_ccs_seen;
|
||||
return $server_encrypting;
|
||||
}
|
||||
sub client_ccs_seen
|
||||
sub client_encrypting
|
||||
{
|
||||
my $class = shift;
|
||||
if (@_) {
|
||||
$client_ccs_seen = shift;
|
||||
$client_encrypting= shift;
|
||||
}
|
||||
return $client_ccs_seen;
|
||||
return $client_encrypting;
|
||||
}
|
||||
#Enable/Disable Encrypt-then-MAC
|
||||
sub etm
|
||||
@@ -190,7 +197,8 @@ sub new
|
||||
data => $data,
|
||||
decrypt_data => $decrypt_data,
|
||||
orig_decrypt_data => $decrypt_data,
|
||||
sent => 0
|
||||
encrypted => 0,
|
||||
outer_content_type => RT_APPLICATION_DATA
|
||||
};
|
||||
|
||||
return bless $self, $class;
|
||||
@@ -227,22 +235,44 @@ sub decryptETM
|
||||
sub decrypt()
|
||||
{
|
||||
my ($self) = shift;
|
||||
|
||||
my $mactaglen = 20;
|
||||
my $data = $self->data;
|
||||
|
||||
if($self->version >= VERS_TLS_1_1()) {
|
||||
#TLS1.1+ has an explicit IV. Throw it away
|
||||
#Throw away any IVs
|
||||
if (TLSProxy::Proxy->is_tls13()) {
|
||||
#A TLS1.3 client, when processing the server's initial flight, could
|
||||
#respond with either an encrypted or an unencrypted alert.
|
||||
if ($self->content_type() == RT_ALERT) {
|
||||
#TODO(TLS1.3): Eventually it is sufficient just to check the record
|
||||
#content type. If an alert is encrypted it will have a record
|
||||
#content type of application data. However we haven't done the
|
||||
#record layer changes yet, so it's a bit more complicated. For now
|
||||
#we will additionally check if the data length is 2 (1 byte for
|
||||
#alert level, 1 byte for alert description). If it is, then this is
|
||||
#an unencrypted alert, so don't try to decrypt
|
||||
return $data if (length($data) == 2);
|
||||
}
|
||||
$mactaglen = 16;
|
||||
} elsif ($self->version >= VERS_TLS_1_1()) {
|
||||
#16 bytes for a standard IV
|
||||
$data = substr($data, 16);
|
||||
|
||||
#Find out what the padding byte is
|
||||
my $padval = unpack("C", substr($data, length($data) - 1));
|
||||
|
||||
#Throw away the padding
|
||||
$data = substr($data, 0, length($data) - ($padval + 1));
|
||||
}
|
||||
|
||||
#Find out what the padding byte is
|
||||
my $padval = unpack("C", substr($data, length($data) - 1));
|
||||
#Throw away the MAC or TAG
|
||||
$data = substr($data, 0, length($data) - $mactaglen);
|
||||
|
||||
#Throw away the padding
|
||||
$data = substr($data, 0, length($data) - ($padval + 1));
|
||||
|
||||
#Throw away the MAC (assumes MAC is 20 bytes for now. FIXME)
|
||||
$data = substr($data, 0, length($data) - 20);
|
||||
if (TLSProxy::Proxy->is_tls13()) {
|
||||
#Get the content type
|
||||
my $content_type = unpack("C", substr($data, length($data) - 1));
|
||||
$self->content_type($content_type);
|
||||
$data = substr($data, 0, length($data) - 1);
|
||||
}
|
||||
|
||||
$self->decrypt_data($data);
|
||||
$self->decrypt_len(length($data));
|
||||
@@ -254,17 +284,20 @@ sub decrypt()
|
||||
sub reconstruct_record
|
||||
{
|
||||
my $self = shift;
|
||||
my $server = shift;
|
||||
my $data;
|
||||
|
||||
if ($self->{sent}) {
|
||||
return "";
|
||||
}
|
||||
$self->{sent} = 1;
|
||||
|
||||
if ($self->sslv2) {
|
||||
$data = pack('n', $self->len | 0x8000);
|
||||
} else {
|
||||
$data = pack('Cnn', $self->content_type, $self->version, $self->len);
|
||||
if (TLSProxy::Proxy->is_tls13() && $self->encrypted) {
|
||||
$data = pack('Cnn', $self->outer_content_type, $self->version,
|
||||
$self->len);
|
||||
} else {
|
||||
$data = pack('Cnn', $self->content_type, $self->version,
|
||||
$self->len);
|
||||
}
|
||||
|
||||
}
|
||||
$data .= $self->data;
|
||||
|
||||
@@ -277,16 +310,6 @@ sub flight
|
||||
my $self = shift;
|
||||
return $self->{flight};
|
||||
}
|
||||
sub content_type
|
||||
{
|
||||
my $self = shift;
|
||||
return $self->{content_type};
|
||||
}
|
||||
sub version
|
||||
{
|
||||
my $self = shift;
|
||||
return $self->{version};
|
||||
}
|
||||
sub sslv2
|
||||
{
|
||||
my $self = shift;
|
||||
@@ -336,4 +359,36 @@ sub len
|
||||
}
|
||||
return $self->{len};
|
||||
}
|
||||
sub version
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{version} = shift;
|
||||
}
|
||||
return $self->{version};
|
||||
}
|
||||
sub content_type
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{content_type} = shift;
|
||||
}
|
||||
return $self->{content_type};
|
||||
}
|
||||
sub encrypted
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{encrypted} = shift;
|
||||
}
|
||||
return $self->{encrypted};
|
||||
}
|
||||
sub outer_content_type
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{outer_content_type} = shift;
|
||||
}
|
||||
return $self->{outer_content_type};
|
||||
}
|
||||
1;
|
||||
@@ -12,6 +12,11 @@ package TLSProxy::ServerHello;
|
||||
use vars '@ISA';
|
||||
push @ISA, 'TLSProxy::Message';
|
||||
|
||||
my $hrrrandom = pack("C*", 0xCF, 0x21, 0xAD, 0x74, 0xE5, 0x9A, 0x61, 0x11, 0xBE,
|
||||
0x1D, 0x8C, 0x02, 0x1E, 0x65, 0xB8, 0x91, 0xC2, 0xA2,
|
||||
0x11, 0x16, 0x7A, 0xBB, 0x8C, 0x5E, 0x07, 0x9E, 0x09,
|
||||
0xE2, 0xC8, 0xA8, 0x33, 0x9C);
|
||||
|
||||
sub new
|
||||
{
|
||||
my $class = shift;
|
||||
@@ -45,16 +50,23 @@ sub parse
|
||||
my $self = shift;
|
||||
my $ptr = 2;
|
||||
my ($server_version) = unpack('n', $self->data);
|
||||
my $neg_version = $server_version;
|
||||
|
||||
my $random = substr($self->data, $ptr, 32);
|
||||
$ptr += 32;
|
||||
my $session_id_len = unpack('C', substr($self->data, $ptr));
|
||||
my $session_id_len = 0;
|
||||
my $session = "";
|
||||
$session_id_len = unpack('C', substr($self->data, $ptr));
|
||||
$ptr++;
|
||||
my $session = substr($self->data, $ptr, $session_id_len);
|
||||
$session = substr($self->data, $ptr, $session_id_len);
|
||||
$ptr += $session_id_len;
|
||||
|
||||
my $ciphersuite = unpack('n', substr($self->data, $ptr));
|
||||
$ptr += 2;
|
||||
my $comp_meth = unpack('C', substr($self->data, $ptr));
|
||||
my $comp_meth = 0;
|
||||
$comp_meth = unpack('C', substr($self->data, $ptr));
|
||||
$ptr++;
|
||||
|
||||
my $extensions_len = unpack('n', substr($self->data, $ptr));
|
||||
if (!defined $extensions_len) {
|
||||
$extensions_len = 0;
|
||||
@@ -82,6 +94,20 @@ sub parse
|
||||
my $extdata = substr($extension_data, 4, $size);
|
||||
$extension_data = substr($extension_data, 4 + $size);
|
||||
$extensions{$type} = $extdata;
|
||||
if ($type == TLSProxy::Message::EXT_SUPPORTED_VERSIONS) {
|
||||
$neg_version = unpack('n', $extdata);
|
||||
}
|
||||
}
|
||||
|
||||
if ($random eq $hrrrandom) {
|
||||
TLSProxy::Proxy->is_tls13(1);
|
||||
# TODO(TLS1.3): Replace this reference to draft version before release
|
||||
} elsif ($neg_version == TLSProxy::Record::VERS_TLS_1_3_DRAFT) {
|
||||
$neg_version = TLSProxy::Record::VERS_TLS_1_3;
|
||||
TLSProxy::Proxy->is_tls13(1);
|
||||
|
||||
TLSProxy::Record->server_encrypting(1);
|
||||
TLSProxy::Record->client_encrypting(1);
|
||||
}
|
||||
|
||||
$self->server_version($server_version);
|
||||
@@ -89,11 +115,13 @@ sub parse
|
||||
$self->session_id_len($session_id_len);
|
||||
$self->session($session);
|
||||
$self->ciphersuite($ciphersuite);
|
||||
TLSProxy::Proxy->ciphersuite($ciphersuite);
|
||||
$self->comp_meth($comp_meth);
|
||||
$self->extension_data(\%extensions);
|
||||
|
||||
$self->process_data();
|
||||
|
||||
|
||||
print " Server Version:".$server_version."\n";
|
||||
print " Session ID Len:".$session_id_len."\n";
|
||||
print " Ciphersuite:".$ciphersuite."\n";
|
||||
@@ -145,9 +173,9 @@ sub server_version
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{client_version} = shift;
|
||||
$self->{server_version} = shift;
|
||||
}
|
||||
return $self->{client_version};
|
||||
return $self->{server_version};
|
||||
}
|
||||
sub random
|
||||
{
|
||||
|
||||
@@ -33,6 +33,7 @@ sub new
|
||||
$self->{p} = "";
|
||||
$self->{g} = "";
|
||||
$self->{pub_key} = "";
|
||||
$self->{sigalg} = -1;
|
||||
$self->{sig} = "";
|
||||
|
||||
return $self;
|
||||
@@ -41,10 +42,13 @@ sub new
|
||||
sub parse
|
||||
{
|
||||
my $self = shift;
|
||||
my $sigalg = -1;
|
||||
|
||||
#Minimal SKE parsing. Only supports DHE at the moment (if its not DHE
|
||||
#the parsing data will be trash...which is ok as long as we don't try to
|
||||
#use it)
|
||||
#Minimal SKE parsing. Only supports one known DHE ciphersuite at the moment
|
||||
return if TLSProxy::Proxy->ciphersuite()
|
||||
!= TLSProxy::Message::CIPHER_ADH_AES_128_SHA
|
||||
&& TLSProxy::Proxy->ciphersuite()
|
||||
!= TLSProxy::Message::CIPHER_DHE_RSA_AES_128_SHA;
|
||||
|
||||
my $p_len = unpack('n', $self->data);
|
||||
my $ptr = 2;
|
||||
@@ -62,18 +66,28 @@ sub parse
|
||||
$ptr += $pub_key_len;
|
||||
|
||||
#We assume its signed
|
||||
my $sig_len = unpack('n', substr($self->data, $ptr));
|
||||
my $record = ${$self->records}[0];
|
||||
|
||||
if (TLSProxy::Proxy->is_tls13()
|
||||
|| $record->version() == TLSProxy::Record::VERS_TLS_1_2) {
|
||||
$sigalg = unpack('n', substr($self->data, $ptr));
|
||||
$ptr += 2;
|
||||
}
|
||||
my $sig = "";
|
||||
if (defined $sig_len) {
|
||||
$ptr += 2;
|
||||
$sig = substr($self->data, $ptr, $sig_len);
|
||||
$ptr += $sig_len;
|
||||
if (defined $sigalg) {
|
||||
my $sig_len = unpack('n', substr($self->data, $ptr));
|
||||
if (defined $sig_len) {
|
||||
$ptr += 2;
|
||||
$sig = substr($self->data, $ptr, $sig_len);
|
||||
$ptr += $sig_len;
|
||||
}
|
||||
}
|
||||
|
||||
$self->p($p);
|
||||
$self->g($g);
|
||||
$self->pub_key($pub_key);
|
||||
$self->sig($sig);
|
||||
$self->sigalg($sigalg) if defined $sigalg;
|
||||
$self->signature($sig);
|
||||
}
|
||||
|
||||
|
||||
@@ -89,9 +103,10 @@ sub set_message_contents
|
||||
$data .= $self->g;
|
||||
$data .= pack('n', length($self->pub_key));
|
||||
$data .= $self->pub_key;
|
||||
if (length($self->sig) > 0) {
|
||||
$data .= pack('n', length($self->sig));
|
||||
$data .= $self->sig;
|
||||
$data .= pack('n', $self->sigalg) if ($self->sigalg != -1);
|
||||
if (length($self->signature) > 0) {
|
||||
$data .= pack('n', length($self->signature));
|
||||
$data .= $self->signature;
|
||||
}
|
||||
|
||||
$self->data($data);
|
||||
@@ -123,7 +138,15 @@ sub pub_key
|
||||
}
|
||||
return $self->{pub_key};
|
||||
}
|
||||
sub sig
|
||||
sub sigalg
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
$self->{sigalg} = shift;
|
||||
}
|
||||
return $self->{sigalg};
|
||||
}
|
||||
sub signature
|
||||
{
|
||||
my $self = shift;
|
||||
if (@_) {
|
||||
|
||||
@@ -0,0 +1,228 @@
|
||||
#! /usr/bin/env perl
|
||||
# Copyright 2015-2018 The OpenSSL Project Authors. All Rights Reserved.
|
||||
#
|
||||
# Licensed under the OpenSSL license (the "License"). You may not use
|
||||
# this file except in compliance with the License. You can obtain a copy
|
||||
# in the file LICENSE in the source distribution or at
|
||||
# https://www.openssl.org/source/license.html
|
||||
|
||||
package checkhandshake;
|
||||
|
||||
use OpenSSL::Test qw/:DEFAULT cmdstr srctop_file srctop_dir bldtop_dir/;
|
||||
use OpenSSL::Test::Utils;
|
||||
use TLSProxy::Proxy;
|
||||
|
||||
use Exporter;
|
||||
our @ISA = 'Exporter';
|
||||
our @EXPORT = qw(@handmessages @extensions checkhandshake);
|
||||
|
||||
use constant {
|
||||
DEFAULT_HANDSHAKE => 1,
|
||||
OCSP_HANDSHAKE => 2,
|
||||
RESUME_HANDSHAKE => 4,
|
||||
CLIENT_AUTH_HANDSHAKE => 8,
|
||||
RENEG_HANDSHAKE => 16,
|
||||
NPN_HANDSHAKE => 32,
|
||||
EC_HANDSHAKE => 64,
|
||||
HRR_HANDSHAKE => 128,
|
||||
HRR_RESUME_HANDSHAKE => 256,
|
||||
|
||||
ALL_HANDSHAKES => 511
|
||||
};
|
||||
|
||||
use constant {
|
||||
#DEFAULT also includes SESSION_TICKET_SRV_EXTENSION and SERVER_NAME_CLI
|
||||
DEFAULT_EXTENSIONS => 0x00000007,
|
||||
SESSION_TICKET_SRV_EXTENSION => 0x00000002,
|
||||
SERVER_NAME_CLI_EXTENSION => 0x00000004,
|
||||
SERVER_NAME_SRV_EXTENSION => 0x00000008,
|
||||
STATUS_REQUEST_CLI_EXTENSION => 0x00000010,
|
||||
STATUS_REQUEST_SRV_EXTENSION => 0x00000020,
|
||||
ALPN_CLI_EXTENSION => 0x00000040,
|
||||
ALPN_SRV_EXTENSION => 0x00000080,
|
||||
SCT_CLI_EXTENSION => 0x00000100,
|
||||
SCT_SRV_EXTENSION => 0x00000200,
|
||||
RENEGOTIATE_CLI_EXTENSION => 0x00000400,
|
||||
NPN_CLI_EXTENSION => 0x00000800,
|
||||
NPN_SRV_EXTENSION => 0x00001000,
|
||||
SRP_CLI_EXTENSION => 0x00002000,
|
||||
#Client side for ec point formats is a default extension
|
||||
EC_POINT_FORMAT_SRV_EXTENSION => 0x00004000,
|
||||
PSK_CLI_EXTENSION => 0x00008000,
|
||||
PSK_SRV_EXTENSION => 0x00010000,
|
||||
KEY_SHARE_SRV_EXTENSION => 0x00020000,
|
||||
PSK_KEX_MODES_EXTENSION => 0x00040000,
|
||||
KEY_SHARE_HRR_EXTENSION => 0x00080000,
|
||||
SUPPORTED_GROUPS_SRV_EXTENSION => 0x00100000,
|
||||
POST_HANDSHAKE_AUTH_CLI_EXTENSION => 0x00200000
|
||||
};
|
||||
|
||||
our @handmessages = ();
|
||||
our @extensions = ();
|
||||
|
||||
sub checkhandshake($$$$)
|
||||
{
|
||||
my ($proxy, $handtype, $exttype, $testname) = @_;
|
||||
|
||||
subtest $testname => sub {
|
||||
my $loop = 0;
|
||||
my $numtests;
|
||||
my $extcount;
|
||||
my $clienthelloseen = 0;
|
||||
|
||||
my $lastmt = 0;
|
||||
my $numsh = 0;
|
||||
if (TLSProxy::Proxy::is_tls13()) {
|
||||
#How many ServerHellos are we expecting?
|
||||
for ($numtests = 0; $handmessages[$loop][1] != 0; $loop++) {
|
||||
next if (($handmessages[$loop][1] & $handtype) == 0);
|
||||
$numsh++ if ($lastmt != TLSProxy::Message::MT_SERVER_HELLO
|
||||
&& $handmessages[$loop][0] == TLSProxy::Message::MT_SERVER_HELLO);
|
||||
$lastmt = $handmessages[$loop][0];
|
||||
}
|
||||
}
|
||||
|
||||
#First count the number of tests
|
||||
my $nextmess = 0;
|
||||
my $message = undef;
|
||||
my $chnum = 0;
|
||||
my $shnum = 0;
|
||||
if (!TLSProxy::Proxy::is_tls13()) {
|
||||
# In non-TLSv1.3 we always treat reneg CH and SH like the first CH
|
||||
# and SH
|
||||
$chnum = 1;
|
||||
$shnum = 1;
|
||||
}
|
||||
#If we're only expecting one ServerHello out of two then we skip the
|
||||
#first ServerHello in the list completely
|
||||
$shnum++ if ($numsh == 1 && TLSProxy::Proxy::is_tls13());
|
||||
$loop = 0;
|
||||
for ($numtests = 0; $handmessages[$loop][1] != 0; $loop++) {
|
||||
next if (($handmessages[$loop][1] & $handtype) == 0);
|
||||
if (scalar @{$proxy->message_list} > $nextmess) {
|
||||
$message = ${$proxy->message_list}[$nextmess];
|
||||
$nextmess++;
|
||||
} else {
|
||||
$message = undef;
|
||||
}
|
||||
$numtests++;
|
||||
|
||||
next if (!defined $message);
|
||||
if (TLSProxy::Proxy::is_tls13()) {
|
||||
$chnum++ if $message->mt() == TLSProxy::Message::MT_CLIENT_HELLO;
|
||||
$shnum++ if $message->mt() == TLSProxy::Message::MT_SERVER_HELLO;
|
||||
}
|
||||
next if ($message->mt() != TLSProxy::Message::MT_CLIENT_HELLO
|
||||
&& $message->mt() != TLSProxy::Message::MT_SERVER_HELLO
|
||||
&& $message->mt() !=
|
||||
TLSProxy::Message::MT_ENCRYPTED_EXTENSIONS
|
||||
&& $message->mt() != TLSProxy::Message::MT_CERTIFICATE);
|
||||
|
||||
next if $message->mt() == TLSProxy::Message::MT_CERTIFICATE
|
||||
&& !TLSProxy::Proxy::is_tls13();
|
||||
|
||||
my $extchnum = 1;
|
||||
my $extshnum = 1;
|
||||
for (my $extloop = 0;
|
||||
$extensions[$extloop][2] != 0;
|
||||
$extloop++) {
|
||||
$extchnum = 2 if $extensions[$extloop][0] != TLSProxy::Message::MT_CLIENT_HELLO
|
||||
&& TLSProxy::Proxy::is_tls13();
|
||||
$extshnum = 2 if $extensions[$extloop][0] != TLSProxy::Message::MT_SERVER_HELLO
|
||||
&& $extchnum == 2;
|
||||
next if $extensions[$extloop][0] == TLSProxy::Message::MT_CLIENT_HELLO
|
||||
&& $extchnum != $chnum;
|
||||
next if $extensions[$extloop][0] == TLSProxy::Message::MT_SERVER_HELLO
|
||||
&& $extshnum != $shnum;
|
||||
next if ($message->mt() != $extensions[$extloop][0]);
|
||||
$numtests++;
|
||||
}
|
||||
$numtests++;
|
||||
}
|
||||
|
||||
plan tests => $numtests;
|
||||
|
||||
$nextmess = 0;
|
||||
$message = undef;
|
||||
if (TLSProxy::Proxy::is_tls13()) {
|
||||
$chnum = 0;
|
||||
$shnum = 0;
|
||||
} else {
|
||||
# In non-TLSv1.3 we always treat reneg CH and SH like the first CH
|
||||
# and SH
|
||||
$chnum = 1;
|
||||
$shnum = 1;
|
||||
}
|
||||
#If we're only expecting one ServerHello out of two then we skip the
|
||||
#first ServerHello in the list completely
|
||||
$shnum++ if ($numsh == 1 && TLSProxy::Proxy::is_tls13());
|
||||
for ($loop = 0; $handmessages[$loop][1] != 0; $loop++) {
|
||||
next if (($handmessages[$loop][1] & $handtype) == 0);
|
||||
if (scalar @{$proxy->message_list} > $nextmess) {
|
||||
$message = ${$proxy->message_list}[$nextmess];
|
||||
$nextmess++;
|
||||
} else {
|
||||
$message = undef;
|
||||
}
|
||||
if (!defined $message) {
|
||||
fail("Message type check. Got nothing, expected "
|
||||
.$handmessages[$loop][0]);
|
||||
next;
|
||||
} else {
|
||||
ok($message->mt == $handmessages[$loop][0],
|
||||
"Message type check. Got ".$message->mt
|
||||
.", expected ".$handmessages[$loop][0]);
|
||||
}
|
||||
if (TLSProxy::Proxy::is_tls13()) {
|
||||
$chnum++ if $message->mt() == TLSProxy::Message::MT_CLIENT_HELLO;
|
||||
$shnum++ if $message->mt() == TLSProxy::Message::MT_SERVER_HELLO;
|
||||
}
|
||||
|
||||
next if ($message->mt() != TLSProxy::Message::MT_CLIENT_HELLO
|
||||
&& $message->mt() != TLSProxy::Message::MT_SERVER_HELLO
|
||||
&& $message->mt() !=
|
||||
TLSProxy::Message::MT_ENCRYPTED_EXTENSIONS
|
||||
&& $message->mt() != TLSProxy::Message::MT_CERTIFICATE);
|
||||
|
||||
next if $message->mt() == TLSProxy::Message::MT_CERTIFICATE
|
||||
&& !TLSProxy::Proxy::is_tls13();
|
||||
|
||||
if ($message->mt() == TLSProxy::Message::MT_CLIENT_HELLO) {
|
||||
#Add renegotiate extension we will expect if renegotiating
|
||||
$exttype |= RENEGOTIATE_CLI_EXTENSION
|
||||
if ($clienthelloseen && !TLSProxy::Proxy::is_tls13());
|
||||
$clienthelloseen = 1;
|
||||
}
|
||||
#Now check that we saw the extensions we expected
|
||||
my $msgexts = $message->extension_data();
|
||||
my $extchnum = 1;
|
||||
my $extshnum = 1;
|
||||
for (my $extloop = 0, $extcount = 0; $extensions[$extloop][2] != 0;
|
||||
$extloop++) {
|
||||
#In TLSv1.3 we can have two ClientHellos if there has been a
|
||||
#HelloRetryRequest, and they may have different extensions. Skip
|
||||
#if these are extensions for a different ClientHello
|
||||
$extchnum = 2 if $extensions[$extloop][0] != TLSProxy::Message::MT_CLIENT_HELLO
|
||||
&& TLSProxy::Proxy::is_tls13();
|
||||
$extshnum = 2 if $extensions[$extloop][0] != TLSProxy::Message::MT_SERVER_HELLO
|
||||
&& $extchnum == 2;
|
||||
next if $extensions[$extloop][0] == TLSProxy::Message::MT_CLIENT_HELLO
|
||||
&& $extchnum != $chnum;
|
||||
next if $extensions[$extloop][0] == TLSProxy::Message::MT_SERVER_HELLO
|
||||
&& $extshnum != $shnum;
|
||||
next if ($message->mt() != $extensions[$extloop][0]);
|
||||
ok (($extensions[$extloop][2] & $exttype) == 0
|
||||
|| defined ($msgexts->{$extensions[$extloop][1]}),
|
||||
"Extension presence check (Message: ".$message->mt()
|
||||
." Extension: ".($extensions[$extloop][2] & $exttype).", "
|
||||
.$extloop.")");
|
||||
$extcount++ if (($extensions[$extloop][2] & $exttype) != 0);
|
||||
}
|
||||
ok($extcount == keys %$msgexts, "Extensions count mismatch ("
|
||||
.$extcount.", ".(keys %$msgexts)
|
||||
.")");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
1;
|
||||
@@ -1,10 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
rm -f "$2"
|
||||
if test "$OSTYPE" = msdosdjgpp || test "x$PLATFORM" = xmingw ; then
|
||||
cp "$1" "$2"
|
||||
else
|
||||
ln -s "$1" "$2"
|
||||
fi
|
||||
echo "$2 => $1"
|
||||
|
||||
@@ -0,0 +1,384 @@
|
||||
# This isn't a library ".num" file but is a list of documented items
|
||||
# that don't appear in lib*.num -- because they are define's, in
|
||||
# assembly language, etc.
|
||||
#
|
||||
OPENSSL_ia32cap environment
|
||||
OPENSSL_MALLOC_FD environment
|
||||
OPENSSL_MALLOC_FAILURES environment
|
||||
OPENSSL_instrument_bus assembler
|
||||
OPENSSL_instrument_bus2 assembler
|
||||
#
|
||||
ADMISSION_SYNTAX datatype
|
||||
ADMISSIONS datatype
|
||||
ASN1_STRING_TABLE datatype
|
||||
BIO_ADDR datatype
|
||||
BIO_ADDRINFO datatype
|
||||
BIO_callback_fn datatype
|
||||
BIO_callback_fn_ex datatype
|
||||
BIO_hostserv_priorities datatype
|
||||
BIO_lookup_type datatype
|
||||
CRYPTO_EX_dup datatype
|
||||
CRYPTO_EX_free datatype
|
||||
CRYPTO_EX_new datatype
|
||||
DTLS_timer_cb datatype
|
||||
EVP_PKEY_gen_cb datatype
|
||||
EVP_PKEY_METHOD datatype
|
||||
EVP_PKEY_ASN1_METHOD datatype
|
||||
GEN_SESSION_CB datatype
|
||||
OPENSSL_Applink external
|
||||
NAMING_AUTHORITY datatype
|
||||
OSSL_STORE_CTX datatype
|
||||
OSSL_STORE_INFO datatype
|
||||
OSSL_STORE_LOADER datatype
|
||||
OSSL_STORE_LOADER_CTX datatype
|
||||
OSSL_STORE_SEARCH datatype
|
||||
OSSL_STORE_close_fn datatype
|
||||
OSSL_STORE_ctrl_fn datatype
|
||||
OSSL_STORE_expect_fn datatype
|
||||
OSSL_STORE_find_fn datatype
|
||||
OSSL_STORE_eof_fn datatype
|
||||
OSSL_STORE_error_fn datatype
|
||||
OSSL_STORE_load_fn datatype
|
||||
OSSL_STORE_open_fn datatype
|
||||
OSSL_STORE_post_process_info_fn datatype
|
||||
PROFESSION_INFO datatype
|
||||
PROFESSION_INFOS datatype
|
||||
RAND_poll_cb datatype
|
||||
SSL_CTX_keylog_cb_func datatype
|
||||
SSL_client_hello_cb_fn datatype
|
||||
SSL_psk_client_cb_func datatype
|
||||
SSL_psk_find_session_cb_func datatype
|
||||
SSL_psk_server_cb_func datatype
|
||||
SSL_psk_use_session_cb_func datatype
|
||||
SSL_verify_cb datatype
|
||||
UI datatype
|
||||
UI_METHOD datatype
|
||||
UI_STRING datatype
|
||||
UI_string_types datatype
|
||||
UI_string_types datatype
|
||||
X509_STORE_CTX_cert_crl_fn datatype
|
||||
X509_STORE_CTX_check_crl_fn datatype
|
||||
X509_STORE_CTX_check_issued_fn datatype
|
||||
X509_STORE_CTX_check_policy_fn datatype
|
||||
X509_STORE_CTX_check_revocation_fn datatype
|
||||
X509_STORE_CTX_cleanup_fn datatype
|
||||
X509_STORE_CTX_get_crl_fn datatype
|
||||
X509_STORE_CTX_get_issuer_fn datatype
|
||||
X509_STORE_CTX_lookup_certs_fn datatype
|
||||
X509_STORE_CTX_lookup_crls_fn datatype
|
||||
X509_STORE_CTX_verify_cb datatype
|
||||
X509_STORE_CTX_verify_fn datatype
|
||||
X509_STORE_set_verify_cb_func datatype
|
||||
bio_info_cb datatype
|
||||
BIO_info_cb datatype
|
||||
custom_ext_add_cb datatype
|
||||
custom_ext_free_cb datatype
|
||||
custom_ext_parse_cb datatype
|
||||
pem_password_cb datatype
|
||||
ssl_ct_validation_cb datatype
|
||||
#
|
||||
BIO_append_filename define
|
||||
BIO_destroy_bio_pair define
|
||||
BIO_do_accept define
|
||||
BIO_do_connect define
|
||||
BIO_do_handshake define
|
||||
BIO_eof define
|
||||
BIO_flush define
|
||||
BIO_get_accept_name define
|
||||
BIO_get_accept_port define
|
||||
BIO_get_bind_mode define
|
||||
BIO_get_buffer_num_lines define
|
||||
BIO_get_cipher_ctx define
|
||||
BIO_get_cipher_status define
|
||||
BIO_get_close define
|
||||
BIO_get_conn_address define
|
||||
BIO_get_conn_hostname define
|
||||
BIO_get_conn_port define
|
||||
BIO_get_fd define
|
||||
BIO_get_fp define
|
||||
BIO_get_info_callback define
|
||||
BIO_get_md define
|
||||
BIO_get_md_ctx define
|
||||
BIO_get_mem_data define
|
||||
BIO_get_mem_ptr define
|
||||
BIO_get_num_renegotiates define
|
||||
BIO_get_read_request define
|
||||
BIO_get_ssl define
|
||||
BIO_get_write_buf_size define
|
||||
BIO_get_write_guarantee define
|
||||
BIO_make_bio_pair define
|
||||
BIO_pending define
|
||||
BIO_read_filename define
|
||||
BIO_reset define
|
||||
BIO_retry_type define
|
||||
BIO_rw_filename define
|
||||
BIO_seek define
|
||||
BIO_set_accept_bios define
|
||||
BIO_set_accept_name define
|
||||
BIO_set_accept_port define
|
||||
BIO_set_bind_mode define
|
||||
BIO_set_buffer_read_data define
|
||||
BIO_set_buffer_size define
|
||||
BIO_set_close define
|
||||
BIO_set_conn_address define
|
||||
BIO_set_conn_hostname define
|
||||
BIO_set_conn_port define
|
||||
BIO_set_fd define
|
||||
BIO_set_fp define
|
||||
BIO_set_info_callback define
|
||||
BIO_set_md define
|
||||
BIO_set_mem_buf define
|
||||
BIO_set_mem_eof_return define
|
||||
BIO_set_nbio define
|
||||
BIO_set_nbio_accept define
|
||||
BIO_set_read_buffer_size define
|
||||
BIO_set_ssl define
|
||||
BIO_set_ssl_mode define
|
||||
BIO_set_ssl_renegotiate_bytes define
|
||||
BIO_set_ssl_renegotiate_timeout define
|
||||
BIO_set_write_buf_size define
|
||||
BIO_set_write_buffer_size define
|
||||
BIO_should_io_special define
|
||||
BIO_should_read define
|
||||
BIO_should_retry define
|
||||
BIO_should_write define
|
||||
BIO_shutdown_wr define
|
||||
BIO_tell define
|
||||
BIO_wpending define
|
||||
BIO_write_filename define
|
||||
BN_mod define
|
||||
BN_num_bytes define
|
||||
BN_one define
|
||||
BN_zero define deprecated 0.9.8
|
||||
CONF_modules_free define deprecated 1.1.0
|
||||
DES_ecb2_encrypt define
|
||||
DES_ede2_cbc_encrypt define
|
||||
DES_ede2_cfb64_encrypt define
|
||||
DES_ede2_ofb64_encrypt define
|
||||
DTLS_get_link_min_mtu define
|
||||
DTLS_set_link_mtu define
|
||||
ENGINE_cleanup define deprecated 1.1.0
|
||||
ERR_FATAL_ERROR define
|
||||
ERR_GET_FUNC define
|
||||
ERR_GET_LIB define
|
||||
ERR_GET_REASON define
|
||||
ERR_PACK define
|
||||
ERR_free_strings define deprecated 1.1.0
|
||||
ERR_load_crypto_strings define deprecated 1.1.0
|
||||
EVP_DigestSignUpdate define
|
||||
EVP_DigestVerifyUpdate define
|
||||
EVP_MD_CTX_block_size define
|
||||
EVP_MD_CTX_size define
|
||||
EVP_MD_CTX_type define
|
||||
EVP_OpenUpdate define
|
||||
EVP_PKEY_CTX_add1_hkdf_info define
|
||||
EVP_PKEY_CTX_add1_tls1_prf_seed define
|
||||
EVP_PKEY_CTX_hkdf_mode define
|
||||
EVP_PKEY_CTX_set1_hkdf_key define
|
||||
EVP_PKEY_CTX_set1_hkdf_salt define
|
||||
EVP_PKEY_CTX_set1_tls1_prf_secret define
|
||||
EVP_PKEY_CTX_set_dh_paramgen_generator define
|
||||
EVP_PKEY_CTX_set_dh_paramgen_prime_len define
|
||||
EVP_PKEY_CTX_set_dh_pad define
|
||||
EVP_PKEY_CTX_set_dh_nid define
|
||||
EVP_PKEY_CTX_set_dsa_paramgen_bits define
|
||||
EVP_PKEY_CTX_set_ec_param_enc define
|
||||
EVP_PKEY_CTX_set_ec_paramgen_curve_nid define
|
||||
EVP_PKEY_CTX_set_hkdf_md define
|
||||
EVP_PKEY_CTX_set_rsa_keygen_pubexp define
|
||||
EVP_PKEY_CTX_set_rsa_padding define
|
||||
EVP_PKEY_CTX_set_rsa_pss_saltlen define
|
||||
EVP_PKEY_CTX_set_signature_md define
|
||||
EVP_PKEY_CTX_set_tls1_prf_md define
|
||||
EVP_PKEY_assign_DH define
|
||||
EVP_PKEY_assign_DSA define
|
||||
EVP_PKEY_assign_EC_KEY define
|
||||
EVP_PKEY_assign_RSA define
|
||||
EVP_SealUpdate define
|
||||
EVP_SignInit define
|
||||
EVP_SignInit_ex define
|
||||
EVP_SignUpdate define
|
||||
EVP_VerifyInit define
|
||||
EVP_VerifyInit_ex define
|
||||
EVP_VerifyUpdate define
|
||||
EVP_bf_cfb define
|
||||
EVP_cast5_cfb define
|
||||
EVP_cleanup define deprecated 1.1.0
|
||||
EVP_get_digestbynid define
|
||||
EVP_get_digestbyobj define
|
||||
EVP_idea_cfb define
|
||||
EVP_rc2_cfb define
|
||||
EVP_rc5_32_12_16_cfb define
|
||||
EVP_seed_cfb define
|
||||
EVP_sm4_cfb define
|
||||
OBJ_cleanup define deprecated 1.1.0
|
||||
OPENSSL_VERSION_NUMBER define
|
||||
OPENSSL_clear_free define
|
||||
OPENSSL_clear_realloc define
|
||||
OPENSSL_free define
|
||||
OPENSSL_malloc define
|
||||
OPENSSL_malloc_init define
|
||||
OPENSSL_mem_debug_pop define
|
||||
OPENSSL_mem_debug_push define
|
||||
OPENSSL_memdup define
|
||||
OPENSSL_no_config define deprecated 1.1.0
|
||||
OPENSSL_realloc define
|
||||
OPENSSL_secure_actual_size define
|
||||
OPENSSL_secure_clear_free define
|
||||
OPENSSL_secure_free define
|
||||
OPENSSL_secure_malloc define
|
||||
OPENSSL_secure_zalloc define
|
||||
OPENSSL_strdup define
|
||||
OPENSSL_strndup define
|
||||
OPENSSL_zalloc define
|
||||
OpenSSL_add_all_algorithms define deprecated 1.1.0
|
||||
OpenSSL_add_all_ciphers define deprecated 1.1.0
|
||||
OpenSSL_add_all_digests define deprecated 1.1.0
|
||||
OpenSSL_add_ssl_algorithms define
|
||||
PEM_FLAG_EAY_COMPATIBLE define
|
||||
PEM_FLAG_ONLY_B64 define
|
||||
PEM_FLAG_SECURE define
|
||||
RAND_cleanup define deprecated 1.1.0
|
||||
EVP_PKEY_CTX_set_rsa_keygen_bits define
|
||||
SSL_COMP_free_compression_methods define deprecated 1.1.0
|
||||
SSL_CTX_add0_chain_cert define
|
||||
SSL_CTX_add1_chain_cert define
|
||||
SSL_CTX_add_extra_chain_cert define
|
||||
SSL_CTX_build_cert_chain define
|
||||
SSL_CTX_clear_chain_certs define
|
||||
SSL_CTX_clear_extra_chain_certs define
|
||||
SSL_CTX_clear_mode define
|
||||
SSL_CTX_disable_ct define
|
||||
SSL_CTX_get0_chain_certs define
|
||||
SSL_CTX_get_default_read_ahead define
|
||||
SSL_CTX_get_max_cert_list define
|
||||
SSL_CTX_get_max_proto_version define
|
||||
SSL_CTX_get_min_proto_version define
|
||||
SSL_CTX_get_mode define
|
||||
SSL_CTX_get_read_ahead define
|
||||
SSL_CTX_get_session_cache_mode define
|
||||
SSL_CTX_get_tlsext_status_arg define
|
||||
SSL_CTX_get_tlsext_status_cb define
|
||||
SSL_CTX_get_tlsext_status_type define
|
||||
SSL_CTX_select_current_cert define
|
||||
SSL_CTX_sess_accept define
|
||||
SSL_CTX_sess_accept_good define
|
||||
SSL_CTX_sess_accept_renegotiate define
|
||||
SSL_CTX_sess_cache_full define
|
||||
SSL_CTX_sess_cb_hits define
|
||||
SSL_CTX_sess_connect define
|
||||
SSL_CTX_sess_connect_good define
|
||||
SSL_CTX_sess_connect_renegotiate define
|
||||
SSL_CTX_sess_get_cache_size define
|
||||
SSL_CTX_sess_hits define
|
||||
SSL_CTX_sess_misses define
|
||||
SSL_CTX_sess_number define
|
||||
SSL_CTX_sess_set_cache_size define
|
||||
SSL_CTX_sess_timeouts define
|
||||
SSL_CTX_set0_chain define
|
||||
SSL_CTX_set0_chain_cert_store define
|
||||
SSL_CTX_set0_verify_cert_store define
|
||||
SSL_CTX_set1_chain define
|
||||
SSL_CTX_set1_chain_cert_store define
|
||||
SSL_CTX_set1_client_sigalgs define
|
||||
SSL_CTX_set1_client_sigalgs_list define
|
||||
SSL_CTX_set1_curves define
|
||||
SSL_CTX_set1_curves_list define
|
||||
SSL_CTX_set1_groups define
|
||||
SSL_CTX_set1_groups_list define
|
||||
SSL_CTX_set1_sigalgs define
|
||||
SSL_CTX_set1_sigalgs_list define
|
||||
SSL_CTX_set1_verify_cert_store define
|
||||
SSL_CTX_set_current_cert define
|
||||
SSL_CTX_set_max_cert_list define
|
||||
SSL_CTX_set_max_pipelines define
|
||||
SSL_CTX_set_max_proto_version define
|
||||
SSL_CTX_set_max_send_fragment define
|
||||
SSL_CTX_set_min_proto_version define
|
||||
SSL_CTX_set_mode define
|
||||
SSL_CTX_set_msg_callback_arg define
|
||||
SSL_CTX_set_read_ahead define
|
||||
SSL_CTX_set_session_cache_mode define
|
||||
SSL_CTX_set_split_send_fragment define
|
||||
SSL_CTX_set_tlsext_servername_arg define
|
||||
SSL_CTX_set_tlsext_servername_callback define
|
||||
SSL_CTX_set_tlsext_status_arg define
|
||||
SSL_CTX_set_tlsext_status_cb define
|
||||
SSL_CTX_set_tlsext_status_type define
|
||||
SSL_CTX_set_tlsext_ticket_key_cb define
|
||||
SSL_CTX_set_tmp_dh define
|
||||
SSL_add0_chain_cert define
|
||||
SSL_add1_chain_cert define
|
||||
SSL_build_cert_chain define
|
||||
SSL_clear_chain_certs define
|
||||
SSL_clear_mode define
|
||||
SSL_disable_ct define
|
||||
SSL_get0_chain_certs define
|
||||
SSL_get0_session define
|
||||
SSL_get1_curves define
|
||||
SSL_get1_groups define
|
||||
SSL_get_cipher define
|
||||
SSL_get_cipher_bits define
|
||||
SSL_get_cipher_name define
|
||||
SSL_get_cipher_version define
|
||||
SSL_get_extms_support define
|
||||
SSL_get_max_cert_list define
|
||||
SSL_get_max_proto_version define
|
||||
SSL_get_min_proto_version define
|
||||
SSL_get_mode define
|
||||
SSL_get_peer_signature_nid define
|
||||
SSL_get_secure_renegotiation_support define
|
||||
SSL_get_server_tmp_key define
|
||||
SSL_get_shared_curve define
|
||||
SSL_get_shared_group define
|
||||
SSL_get_time define
|
||||
SSL_get_timeout define
|
||||
SSL_get_tlsext_status_ocsp_resp define
|
||||
SSL_get_tlsext_status_type define
|
||||
SSL_in_accept_init define
|
||||
SSL_in_connect_init define
|
||||
SSL_library_init define
|
||||
SSL_load_error_strings define deprecated 1.1.0
|
||||
SSL_select_current_cert define
|
||||
SSL_set0_chain define
|
||||
SSL_set0_chain_cert_store define
|
||||
SSL_set0_verify_cert_store define
|
||||
SSL_set1_chain define
|
||||
SSL_set1_chain_cert_store define
|
||||
SSL_set1_client_sigalgs define
|
||||
SSL_set1_client_sigalgs_list define
|
||||
SSL_set1_curves define
|
||||
SSL_set1_curves_list define
|
||||
SSL_set1_groups define
|
||||
SSL_set1_groups_list define
|
||||
SSL_set1_sigalgs define
|
||||
SSL_set1_sigalgs_list define
|
||||
SSL_set1_verify_cert_store define
|
||||
SSL_set_current_cert define
|
||||
SSL_set_max_cert_list define
|
||||
SSL_set_max_pipelines define
|
||||
SSL_set_max_proto_version define
|
||||
SSL_set_max_send_fragment define
|
||||
SSL_set_min_proto_version define
|
||||
SSL_set_mode define
|
||||
SSL_set_msg_callback_arg define
|
||||
SSL_set_mtu define
|
||||
SSL_set_split_send_fragment define
|
||||
SSL_set_time define
|
||||
SSL_set_timeout define
|
||||
SSL_set_tlsext_host_name define
|
||||
SSL_set_tlsext_status_ocsp_resp define
|
||||
SSL_set_tlsext_status_type define
|
||||
SSL_set_tmp_dh define
|
||||
SSL_want_async define
|
||||
SSL_want_async_job define
|
||||
SSL_want_client_hello_cb define
|
||||
SSL_want_nothing define
|
||||
SSL_want_read define
|
||||
SSL_want_write define
|
||||
SSL_want_x509_lookup define
|
||||
SSLv23_client_method define
|
||||
SSLv23_method define
|
||||
SSLv23_server_method define
|
||||
X509_STORE_set_lookup_crls_cb define
|
||||
X509_STORE_set_verify_func define
|
||||
+10
-13
@@ -30,11 +30,10 @@ use OpenSSL::Util::Pod;
|
||||
my %options = ();
|
||||
GetOptions(\%options,
|
||||
'sourcedir=s', # Source directory
|
||||
'subdir=s%', # Subdirectories to look through,
|
||||
'section=i@', # Subdirectories to look through,
|
||||
# with associated section numbers
|
||||
'destdir=s', # Destination directory
|
||||
#'in=s@', # Explicit files to process (ignores sourcedir)
|
||||
#'section=i', # Default section used for --in files
|
||||
'type=s', # The result type, 'man' or 'html'
|
||||
'suffix:s', # Suffix to add to the extension.
|
||||
# Only used with type=man
|
||||
@@ -43,15 +42,13 @@ GetOptions(\%options,
|
||||
'debug|D+',
|
||||
);
|
||||
|
||||
unless ($options{subdir}) {
|
||||
$options{subdir} = { apps => '1',
|
||||
crypto => '3',
|
||||
ssl => '3' };
|
||||
unless ($options{section}) {
|
||||
$options{section} = [ 1, 3, 5, 7 ];
|
||||
}
|
||||
unless ($options{sourcedir}) {
|
||||
$options{sourcedir} = catdir($config{sourcedir}, "doc");
|
||||
}
|
||||
pod2usage(1) unless ( defined $options{subdir}
|
||||
pod2usage(1) unless ( defined $options{section}
|
||||
&& defined $options{sourcedir}
|
||||
&& defined $options{destdir}
|
||||
&& defined $options{type}
|
||||
@@ -70,8 +67,8 @@ if ($options{debug}) {
|
||||
if defined $options{type};
|
||||
print STDERR "DEBUG: --suffix = $options{suffix}\n"
|
||||
if defined $options{suffix};
|
||||
foreach (keys %{$options{subdir}}) {
|
||||
print STDERR "DEBUG: --subdir = $_=$options{subdir}->{$_}\n";
|
||||
foreach (sort @{$options{section}}) {
|
||||
print STDERR "DEBUG: --section = $_\n";
|
||||
}
|
||||
print STDERR "DEBUG: --remove = $options{remove}\n"
|
||||
if defined $options{remove};
|
||||
@@ -83,8 +80,8 @@ if ($options{debug}) {
|
||||
|
||||
my $symlink_exists = eval { symlink("",""); 1 };
|
||||
|
||||
foreach my $subdir (keys %{$options{subdir}}) {
|
||||
my $section = $options{subdir}->{$subdir};
|
||||
foreach my $section (sort @{$options{section}}) {
|
||||
my $subdir = "man$section";
|
||||
my $podsourcedir = catfile($options{sourcedir}, $subdir);
|
||||
my $podglob = catfile($podsourcedir, "*.pod");
|
||||
|
||||
@@ -101,7 +98,7 @@ foreach my $subdir (keys %{$options{subdir}}) {
|
||||
my $suffix = { man => ".$podinfo{section}".($options{suffix} // ""),
|
||||
html => ".html" } -> {$options{type}};
|
||||
my $generate = { man => "pod2man --name=$name --section=$podinfo{section} --center=OpenSSL --release=$config{version} \"$podpath\"",
|
||||
html => "pod2html \"--podroot=$options{sourcedir}\" --htmldir=$updir --podpath=apps:crypto:ssl \"--infile=$podpath\" \"--title=$podname\""
|
||||
html => "pod2html \"--podroot=$options{sourcedir}\" --htmldir=$updir --podpath=man1:man3:man5:man7 \"--infile=$podpath\" \"--title=$podname\""
|
||||
} -> {$options{type}};
|
||||
my $output_dir = catdir($options{destdir}, "man$podinfo{section}");
|
||||
my $output_file = $podname . $suffix;
|
||||
@@ -113,7 +110,7 @@ foreach my $subdir (keys %{$options{subdir}}) {
|
||||
if $options{debug};
|
||||
unless ($options{"dry-run"}) {
|
||||
@output = `$generate`;
|
||||
map { s|href="http://man\.he\.net/(man\d/[^"]+)(?:\.html)?"|href="../$1.html|g; } @output
|
||||
map { s|href="http://man\.he\.net/(man\d/[^"]+)(?:\.html)?"|href="../$1.html"|g; } @output
|
||||
if $options{type} eq "html";
|
||||
}
|
||||
print STDERR "DEBUG: Done processing\n" if $options{debug};
|
||||
|
||||
@@ -1,207 +0,0 @@
|
||||
#! /usr/bin/env perl
|
||||
# Copyright 2000-2016 The OpenSSL Project Authors. All Rights Reserved.
|
||||
#
|
||||
# Licensed under the OpenSSL license (the "License"). You may not use
|
||||
# this file except in compliance with the License. You can obtain a copy
|
||||
# in the file LICENSE in the source distribution or at
|
||||
# https://www.openssl.org/source/license.html
|
||||
|
||||
# Run the test suite and generate a report
|
||||
|
||||
if (! -f "Configure") {
|
||||
print "Please run perl util/selftest.pl in the OpenSSL directory.\n";
|
||||
exit 1;
|
||||
}
|
||||
|
||||
my $report="testlog";
|
||||
my $os="??";
|
||||
my $version="??";
|
||||
my $platform0="??";
|
||||
my $platform="??";
|
||||
my $options="??";
|
||||
my $last="??";
|
||||
my $ok=0;
|
||||
my $cc="cc";
|
||||
my $cversion="??";
|
||||
my $sep="-----------------------------------------------------------------------------\n";
|
||||
my $not_our_fault="\nPlease ask your system administrator/vendor for more information.\n[Problems with your operating system setup should not be reported\nto the OpenSSL project.]\n";
|
||||
|
||||
open(OUT,">$report") or die;
|
||||
|
||||
print OUT "OpenSSL self-test report:\n\n";
|
||||
|
||||
$uname=`uname -a`;
|
||||
$uname="??\n" if $uname eq "";
|
||||
|
||||
$c=`sh config -t`;
|
||||
foreach $_ (split("\n",$c)) {
|
||||
$os=$1 if (/Operating system: (.*)$/);
|
||||
$platform0=$1 if (/Configuring for (.*)$/);
|
||||
}
|
||||
|
||||
system "sh config" if (! -f "Makefile");
|
||||
|
||||
if (open(IN,"<Makefile")) {
|
||||
while (<IN>) {
|
||||
$version=$1 if (/^VERSION=(.*)$/);
|
||||
$platform=$1 if (/^PLATFORM=(.*)$/);
|
||||
$options=$1 if (/^OPTIONS=(.*)$/);
|
||||
$cc=$1 if (/^CC= *(.*)$/);
|
||||
}
|
||||
close(IN);
|
||||
} else {
|
||||
print OUT "Error running config!\n";
|
||||
}
|
||||
|
||||
$cversion=`$cc -v 2>&1`;
|
||||
$cversion=`$cc -V 2>&1` if $cversion =~ "[Uu]sage";
|
||||
$cversion=`$cc -V |head -1` if $cversion =~ "Error";
|
||||
$cversion=`$cc --version` if $cversion eq "";
|
||||
$cversion =~ s/Reading specs.*\n//;
|
||||
$cversion =~ s/usage.*\n//;
|
||||
$cversion =~ s|\R$||;
|
||||
|
||||
if (open(IN,"<CHANGES")) {
|
||||
while(<IN>) {
|
||||
if (/\*\) (.{0,55})/ && !/applies to/) {
|
||||
$last=$1;
|
||||
last;
|
||||
}
|
||||
}
|
||||
close(IN);
|
||||
}
|
||||
|
||||
print OUT "OpenSSL version: $version\n";
|
||||
print OUT "Last change: $last...\n";
|
||||
print OUT "Options: $options\n" if $options ne "";
|
||||
print OUT "OS (uname): $uname";
|
||||
print OUT "OS (config): $os\n";
|
||||
print OUT "Target (default): $platform0\n";
|
||||
print OUT "Target: $platform\n";
|
||||
print OUT "Compiler: $cversion\n";
|
||||
print OUT "\n";
|
||||
|
||||
print "Checking compiler...\n";
|
||||
if (open(TEST,">cctest.c")) {
|
||||
print TEST "#include <stdio.h>\n#include <stdlib.h>\n#include <errno.h>\nmain(){printf(\"Hello world\\n\");}\n";
|
||||
close(TEST);
|
||||
system("$cc -o cctest cctest.c");
|
||||
if (`./cctest` !~ /Hello world/) {
|
||||
print OUT "Compiler doesn't work.\n";
|
||||
print OUT $not_our_fault;
|
||||
goto err;
|
||||
}
|
||||
system("ar r cctest.a /dev/null");
|
||||
if (not -f "cctest.a") {
|
||||
print OUT "Check your archive tool (ar).\n";
|
||||
print OUT $not_our_fault;
|
||||
goto err;
|
||||
}
|
||||
} else {
|
||||
print OUT "Can't create cctest.c\n";
|
||||
}
|
||||
if (open(TEST,">cctest.c")) {
|
||||
print TEST "#include <stdio.h>\n#include <stdlib.h>\n#include <openssl/opensslv.h>\nmain(){printf(OPENSSL_VERSION_TEXT);}\n";
|
||||
close(TEST);
|
||||
system("$cc -o cctest -Iinclude cctest.c");
|
||||
$cctest = `./cctest`;
|
||||
if ($cctest !~ /OpenSSL $version/) {
|
||||
if ($cctest =~ /OpenSSL/) {
|
||||
print OUT "#include uses headers from different OpenSSL version!\n";
|
||||
} else {
|
||||
print OUT "Can't compile test program!\n";
|
||||
}
|
||||
print OUT $not_our_fault;
|
||||
goto err;
|
||||
}
|
||||
} else {
|
||||
print OUT "Can't create cctest.c\n";
|
||||
}
|
||||
|
||||
print "Running make...\n";
|
||||
if (system("make 2>&1 | tee make.log") > 255) {
|
||||
|
||||
print OUT "make failed!\n";
|
||||
if (open(IN,"<make.log")) {
|
||||
print OUT $sep;
|
||||
while (<IN>) {
|
||||
print OUT;
|
||||
}
|
||||
close(IN);
|
||||
print OUT $sep;
|
||||
} else {
|
||||
print OUT "make.log not found!\n";
|
||||
}
|
||||
goto err;
|
||||
}
|
||||
|
||||
# Not sure why this is here. The tests themselves can detect if their
|
||||
# particular feature isn't included, and should therefore skip themselves.
|
||||
# To skip *all* tests just because one algorithm isn't included is like
|
||||
# shooting mosquito with an elephant gun...
|
||||
# -- Richard Levitte, inspired by problem report 1089
|
||||
#
|
||||
#$_=$options;
|
||||
#s/no-asm//;
|
||||
#s/no-shared//;
|
||||
#s/no-krb5//;
|
||||
#if (/no-/)
|
||||
#{
|
||||
# print OUT "Test skipped.\n";
|
||||
# goto err;
|
||||
#}
|
||||
|
||||
print "Running make test...\n";
|
||||
if (system("make test 2>&1 | tee maketest.log") > 255)
|
||||
{
|
||||
print OUT "make test failed!\n";
|
||||
} else {
|
||||
$ok=1;
|
||||
}
|
||||
|
||||
if ($ok and open(IN,"<maketest.log")) {
|
||||
while (<IN>) {
|
||||
$ok=2 if /^platform: $platform/;
|
||||
}
|
||||
close(IN);
|
||||
}
|
||||
|
||||
if ($ok != 2) {
|
||||
print OUT "Failure!\n";
|
||||
if (open(IN,"<make.log")) {
|
||||
print OUT $sep;
|
||||
while (<IN>) {
|
||||
print OUT;
|
||||
}
|
||||
close(IN);
|
||||
print OUT $sep;
|
||||
} else {
|
||||
print OUT "make.log not found!\n";
|
||||
}
|
||||
if (open(IN,"<maketest.log")) {
|
||||
while (<IN>) {
|
||||
print OUT;
|
||||
}
|
||||
close(IN);
|
||||
print OUT $sep;
|
||||
} else {
|
||||
print OUT "maketest.log not found!\n";
|
||||
}
|
||||
} else {
|
||||
print OUT "Test passed.\n";
|
||||
}
|
||||
err:
|
||||
close(OUT);
|
||||
|
||||
print "\n";
|
||||
open(IN,"<$report") or die;
|
||||
while (<IN>) {
|
||||
if (/$sep/) {
|
||||
print "[...]\n";
|
||||
last;
|
||||
}
|
||||
print;
|
||||
}
|
||||
print "\nTest report in file $report\n";
|
||||
|
||||
die if $ok != 2;
|
||||
@@ -1,25 +1,5 @@
|
||||
#!/bin/sh
|
||||
|
||||
# To test this OpenSSL version's applications against another version's
|
||||
# shared libraries, simply set
|
||||
#
|
||||
# OPENSSL_REGRESSION=/path/to/other/OpenSSL/build/tree
|
||||
if [ -n "$OPENSSL_REGRESSION" ]; then
|
||||
shlibwrap="$OPENSSL_REGRESSION/util/shlib_wrap.sh"
|
||||
if [ -x "$shlibwrap" ]; then
|
||||
# We clear OPENSSL_REGRESSION to avoid a loop, should the shlib_wrap.sh
|
||||
# we exec also support that mechanism...
|
||||
OPENSSL_REGRESSION= exec "$shlibwrap" "$@"
|
||||
else
|
||||
if [ -f "$shlibwrap" ]; then
|
||||
echo "Not permitted to run $shlibwrap" >&2
|
||||
else
|
||||
echo "No $shlibwrap, perhaps OPENSSL_REGRESSION isn't properly set?" >&2
|
||||
fi
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
|
||||
[ $# -ne 0 ] || set -x # debug mode without arguments:-)
|
||||
|
||||
THERE="`echo $0 | sed -e 's|[^/]*$||' 2>/dev/null`.."
|
||||
|
||||
+1
-1
@@ -108,7 +108,7 @@ sub structureData {
|
||||
if($inbrace) {
|
||||
if($item eq "}") {
|
||||
$inbrace --;
|
||||
|
||||
|
||||
if(!$inbrace) {
|
||||
$substruc = structureData($dataitem);
|
||||
$dataitem = $substruc;
|
||||
|
||||
Reference in New Issue
Block a user