Postini-SAML

 view release on metacpan or  search on metacpan

lib/Postini/SAML.pm  view on Meta::CPAN

}

sub _load_rsa_key {
    my ($self, $key_file, $cert_file) = @_;

    # load the keyfile and prepare a context for signing
    open my $key_fh, '<', $key_file or croak "couldn't open $key_file for reading: $!";
    my $key_text = do { local $/; <$key_fh> };
    close $key_fh;

    my $key = Crypt::OpenSSL::RSA->new_private_key( $key_text );
    if ( not $key )
    {
        croak "failed to instantiate Crypt::OpenSSL::RSA object from $key_file";
    }

    $key->use_pkcs1_padding();
    $self->{'key'} = $key;

    # we need to include the certificate without headers in the signed XML, so
    # extract it

 view all matches for this distribution
 view release on metacpan -  search on metacpan

( run in 0.622 second using v1.00-cache-2.02-grep-82fe00e-cpan-2cc899e4a130 )