Result:
found more than 950 distributions - search limited to the first 2001 files matching your query ( run in 1.205 )


Cpanel-JSON-XS

 view release on metacpan or  search on metacpan

XS.pm  view on Meta::CPAN

codeset range. Neither of these flags conflict with each other, although
some combinations make less sense than others.

Care has been taken to make all flags symmetrical with respect to
C<encode> and C<decode>, that is, texts encoded with any combination of
these flag values will be correctly decoded when the same flags are used
- in general, if you use different flag settings while encoding vs. when
decoding you likely have a bug somewhere.

Below comes a verbose discussion of these flags. Note that a "codeset" is
simply an abstract set of character-codepoint pairs, while an encoding

XS.pm  view on Meta::CPAN

=item C<utf8> flag disabled

When C<utf8> is disabled (the default), then C<encode>/C<decode> generate
and expect Unicode strings, that is, characters with high ordinal Unicode
values (> 255) will be encoded as such characters, and likewise such
characters are decoded as-is, no changes to them will be done, except
"(re-)interpreting" them as Unicode codepoints or Unicode characters,
respectively (to Perl, these are the same thing in strings unless you do
funny/weird/dumb stuff).

This is useful when you want to do the encoding yourself (e.g. when you

 view all matches for this distribution


CracTools

 view release on metacpan or  search on metacpan

lib/CracTools/Utils.pm  view on Meta::CPAN

# Decode base 64 error list
sub decodePosListInBase64 {
  my $encoded_str = shift;

  my @encoded_list = split "", $encoded_str;
  my (@index,@decoded_list);

  #Looking for index of each char
  foreach my $j (@encoded_list) {
    my @ind = grep { $Base64_ENCODING[$_] eq $j } 0 .. $#Base64_ENCODING;
    push(@index,$ind[0]);

lib/CracTools/Utils.pm  view on Meta::CPAN

  # Convert into list position
  for (my $e = 0; $e < (0+@encoded_list);$e++) {
    for(my $i=0; $i<$Base64_BITNESS; $i++) {
      if ($index[$e] & (1 << $i)) {
        my $pos = (int($i+$Base64_BITNESS*$e));
        push(@decoded_list,$pos);
      }
    }
  }

  return @decoded_list;
}




lib/CracTools/Utils.pm  view on Meta::CPAN


Encode a (0-based) list of increasing position to a string using Base64
encoding scheme : ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/

  my $encoded_list = CracTools::Utils::encodePosListToBase64(1,3,5,8,12,32);
  my @decoded_list = CracTools::Utils::decodePosListInBase64($encoded_list);

=head2 decodePosListInBase64

Decode position list encoded by encodePosListToBase64.

 view all matches for this distribution


Crypt-Argon2

 view release on metacpan or  search on metacpan

src/encoding.c  view on Meta::CPAN

}

/*
 * Decode Base64 chars into bytes. The '*dst_len' value must initially
 * contain the length of the output buffer '*dst'; when the decoding
 * ends, the actual number of decoded bytes is written back in
 * '*dst_len'.
 *
 * Decoding stops when a non-Base64 character is encountered, or when
 * the output buffer capacity is exceeded. If an error occurred (output
 * buffer is too small, invalid last characters leading to unprocessed

 view all matches for this distribution


Crypt-Bear

 view release on metacpan or  search on metacpan

lib/Crypt/Bear/AEAD.pm  view on Meta::CPAN

 my $tag = $aead->get_tag;

 $aead->reset($iv);
 $aead->aad_inject($aad);
 $aead->flip;
 my $decoded = $aead->run($ciphertext, 0);

=head1 DESCRIPTION

This is a base-class for Authenticated encryption with additional data, such as L<GCM|Crypt::Bear::GCM>, L<CCM|Crypt::Bear::CCM> and L<EAX|Crypt::Bear::EAX>. These are typtically used with a block cipher such as C<AES>.

 view all matches for this distribution


Crypt-CBC

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN

2.32    Fri Dec 14 14:20:17 EST 2012
	- Fix "Taint checks are turned on and your key is tainted" error when autogenerating salt and IV.

2.31    Tue Oct 30 07:03:40 EDT 2012
	- Fixes to regular expressions to avoid rare failures to
          correctly strip padding in decoded messages.
        - Add padding type = "none".
        - Both fixes contributed by Bas van Sisseren.

2.29	 Tue Apr 22 10:22:37 EDT 2008
	 - Fixed errors that occurred when encrypting/decrypting utf8 strings

 view all matches for this distribution


Crypt-CipherSaber

 view release on metacpan or  search on metacpan

lib/Crypt/CipherSaber.pm  view on Meta::CPAN


  use Crypt::CipherSaber;
  my $cs = Crypt::CipherSaber->new('my sad secret key');

  my $coded   = $cs->encrypt('Here is a secret message for you');
  my $decoded = $cs->decrypt($coded);

  # encrypt from and to a file
  open my $in,       'secretletter.txt' or die "Can't open infile: $!";
  open my $out, '>', 'secretletter.cs1' or die "Can't open outfile: $!";
  binmode $in;

 view all matches for this distribution


Crypt-FNA

 view release on metacpan or  search on metacpan

lib/Crypt/FNA.pm  view on Meta::CPAN


  
  $krypto->decrypt_file($name_encrypted_file, $name_decrypted_file)
  

The input file is read and decoded through the curve (F), the output file.

=head2 encrypt_scalar

The method encrypt_scalar digit strings: the result of encryption is a vector containing the cryptogram.
The syntax is:

 view all matches for this distribution


Crypt-Format

 view release on metacpan or  search on metacpan

t/004_custom_base64.t  view on Meta::CPAN

        'der2pem() (encode())',
    );

    is(
        Crypt::Format::pem2der($faux_pem),
        'decoded',
        'pem2der() (decode())',
    );
}

#----------------------------------------------------------------------

package BadBase64;

sub encode { "encoded\n" }

sub decode { 'decoded' }

1;

 view all matches for this distribution


Crypt-HSXKPasswd

 view release on metacpan or  search on metacpan

lib/Crypt/HSXKPasswd/RNG/RandomDotOrg.pm  view on Meta::CPAN

    if($response->is_error()){
        _error('failed to retrieve numbers from Random.Org web service with error code '.$response->code().' ('.$response->message.')');
    }
    
    # parse the result
    my $raw_numbers = $response->decoded_content();
    my @ans = ();
    RESPONSE_LINE:
    foreach my $line (split /\n/sx, $raw_numbers){
        # validate the line
        unless($line && $line =~ m/^\d+$/sx){

 view all matches for this distribution


Crypt-Hill

 view release on metacpan or  search on metacpan

lib/Crypt/Hill.pm  view on Meta::CPAN

    use strict; use warnings;
    use Crypt::Hill;

    my $crypt   = Crypt::Hill->new({ key => 'DDCF' });
    my $encoded = $crypt->encode('HELP');
    my $decoded = $crypt->decode($encoded);

    print "Encoded: [$encoded]\n";
    print "Decoded: [$decoded]\n";

=cut

sub decode {
    my ($self, $message) = @_;

 view all matches for this distribution


Crypt-JWT

 view release on metacpan or  search on metacpan

lib/Crypt/JWT.pm  view on Meta::CPAN


  return if $args{ignore_claims};

  if (ref($payload) ne 'HASH') {
    # https://github.com/DCIT/perl-Crypt-JWT/issues/31
    # payload needs to be decoded into a HASH for checking any verify_XXXX
    for my $claim (qw(exp nbf iat iss sub aud jti)) {
      if (defined $args{"verify_$claim"} && $args{"verify_$claim"} != 0) {
        croak "JWT: cannot check verify_$claim (payload not decoded JSON/HASH)";
      }
    }
    return; # nothing to check
  }

lib/Crypt/JWT.pm  view on Meta::CPAN


C<undef> (default) - if possible decode payload from JSON string, if decode_json fails return payload as a raw string (octets).

=item decode_header

C<0> (default) - do not return decoded header as a return value of decode_jwt()

C<1> - return decoded header as a return value of decode_jwt()

 my $payload = decode_jwt(token=>$t, key=>$k);
 #or
 my ($header, $payload) = decode_jwt(token=>$t, key=>$k, decode_header=>1);

 view all matches for this distribution


Crypt-License

 view release on metacpan or  search on metacpan

README  view on Meta::CPAN

Crypt::License

Read INSTALL for information about missing module Crypt::LockTite

This module set provides tools to effectively obfuscate perl source
code and allow it to be decoded and executed based on host server, user,
expiration date and other parameters. Further, decoding and execution can be
set for a system wide key as well as a unique user key.

In addition, there are a set of utilities that provide email notification of
License expiration and indirect use of the encrypted modules by other

 view all matches for this distribution


Crypt-MagicSignatures-Envelope

 view release on metacpan or  search on metacpan

lib/Crypt/MagicSignatures/Envelope.pm  view on Meta::CPAN

      my $temp;

      # Add data type if given
      $self->data_type( $temp ) if $temp = $data->attr->{type};

      # Add decoded data
      $self->data( b64url_decode( $data->text ) );

      # The envelope is empty
      unless ($self->data) {
        carp 'No data payload defined';

lib/Crypt/MagicSignatures/Envelope.pm  view on Meta::CPAN

=head2 data

  my $data = $me->data;
  $me->data('Hello world!');

The decoded data folded in the MagicEnvelope.


=head2 data_type

  my $data_type = $me->data_type;

lib/Crypt/MagicSignatures/Envelope.pm  view on Meta::CPAN

  $me->data_type('application/atom+xml');

  print $me->dom->at('author > uri')->text;
  # alice@example.com

The L<Mojo::DOM> object of the decoded data,
in the case the MagicEnvelope contains XML.

B<This attribute is experimental and may change without warnings!>


 view all matches for this distribution


Crypt-MagicSignatures-Key

 view release on metacpan or  search on metacpan

lib/Crypt/MagicSignatures/Key.pm  view on Meta::CPAN

  $v =~ s/\=+$// unless (defined $_[1] ? $_[1] : 1);
  $v;
};


# Returns the b64 urlsafe decoded string
sub b64url_decode {
  my $v = shift;
  return '' unless $v;

  $v =~ tr{-_}{+/};

 view all matches for this distribution


Crypt-MatrixSSL

 view release on metacpan or  search on metacpan

MatrixSSL.pm  view on Meta::CPAN

    0+constant('SSL_SUCCESS')       => 'SSL_SUCCESS	Generic success',
    0+constant('SSL_ERROR')         => 'SSL_ERROR	generic ssl error, see error code',
    0+constant('SSL_FULL')          => 'SSL_FULL	must call sslRead before decoding',
    0+constant('SSL_PARTIAL')       => 'SSL_PARTIAL	more data reqired to parse full msg',
    0+constant('SSL_SEND_RESPONSE') => 'SSL_SEND_RESPONSE	decode produced output data',
    0+constant('SSL_PROCESS_DATA')  => 'SSL_PROCESS_DATA	succesfully decoded application data',
    0+constant('SSL_ALERT')         => 'SSL_ALERT	weve decoded an alert',
    0+constant('SSL_FILE_NOT_FOUND')=> 'SSL_FILE_NOT_FOUND	File not found',
    0+constant('SSL_MEM_ERROR')     => 'SSL_MEM_ERROR	Memory allocation failure',
);


MatrixSSL.pm  view on Meta::CPAN


=item B<matrixSslDecode>( $ssl, $inBuf, $outBuf, $error, $alertLevel, $alertDescription )

$inBuf and $outBuf are usual string scalars, not (sslBuf_t *) as in C interface.

After succesfull decoding one packet, matrixSslDecode() will cut decoded
packet from $inBuf's beginning.

Reply SSL packets or application data will be appended to $outBuf, if any.

To convert error/alert codes into text use exported hashes:

 view all matches for this distribution


Crypt-MatrixSSL3

 view release on metacpan or  search on metacpan

t/06.client_server.t  view on Meta::CPAN

ok length $tmp < length $client2server,
    'outbuf grow (client)';

is undef, _decode($Server_SSL, $client2server, $server2client, $buf);
is $buf, $s.$s,
    'decoded ok (server)';
ok !length $client2server,
    'outbuf empty (client)';
ok !length $server2client,
    'outbuf empty (server)';

t/06.client_server.t  view on Meta::CPAN

while (length $client2server) {
    is undef, _decode($Server_SSL, $client2server, $server2client, $buf),
        'decoding';
}
ok $buf eq $s,
    'string split into SSL_MAX_PLAINTEXT_LEN chains decoded ok';
ok !length $client2server,
    'outbuf empty (client)';
ok !length $server2client,
    'outbuf empty (server)';

 view all matches for this distribution


Crypt-Nettle

 view release on metacpan or  search on metacpan

Nettle.xs  view on Meta::CPAN

    retout = SvPV_nolen(ret);
    base16_decode_init(&armor);
    if (0 == base16_decode_update(&armor, &retlen, retout, sz, buf))
       croak("Failed to decode mpz_t");
    if (retlen != sz/2)
       croak("size of decoded mpz_t was unexpected");
    if (0 == base16_decode_final(&armor))
       croak("Failed to finalize mpz_t decoding");
    Safefree(buf);

    return ret;

 view all matches for this distribution


Crypt-OOEnigma

 view release on metacpan or  search on metacpan

lib/Crypt/OOEnigma.pm  view on Meta::CPAN

first rotor rotates once for every letter that is encoded, the second rotor
once every 26 letters, the third rotor every 26 squared letters and so on.

The Enigma is configured by selecting several rotors from a larger set, placing
them in a particular order and a particular start position.  Received messages
are decoded by setting the Enigma to the same state as the encoding Enigma and
processing the message again.  The result is clear text with the letter X
instead of spaces.

For a good description of the Enigma, including some interesting exercises, see
Part IV of "The Pleasures of Counting" by T W Korner, Cambridge University

 view all matches for this distribution


Crypt-OpenPGP

 view release on metacpan or  search on metacpan

lib/Crypt/OpenPGP/Armour.pm  view on Meta::CPAN

                                         Version => '0.57',
                                         Comment => 'FooBar',
                                      },
                     );

    my $decoded = Crypt::OpenPGP::Armour->unarmour( $armoured ) or
        die Crypt::OpenPGP::Armour->errstr;

=head1 DESCRIPTION

This module converts arbitrary-length strings of binary octets into

 view all matches for this distribution


Crypt-OpenSSL-Cloner

 view release on metacpan or  search on metacpan

lib/Crypt/OpenSSL/Cloner.pm  view on Meta::CPAN

        my $oid = $ext->{extnID};
        my $extname = $oid_2_ext{$oid};
        next if !$extname;
        my $der = $ext->{extnValue};
        my $parser = $PARSERS{$extname};
        my $decoded = $parser->decode($der);
        if ($extname eq 'SubjectKeyIdentifier') {
            $new_cert->set_extension(
                "subjectKeyIdentifier", unpack('H*', $decoded));
        } elsif ($extname eq 'KeyUsage') {
            #Then try to figure that out, too..
            #Apparently this module has a different way of doing things...
            # Our sample cert doesn't seem to conform to this.. and using
            # A parse of another module, seems to be using OIDs for

lib/Crypt/OpenSSL/Cloner.pm  view on Meta::CPAN

                iPAddress                   => "IP",
                registeredID                => "RID",
            );
            my @altnames;
            my $altname = "";
            foreach my $h (@$decoded) {
                my ($k,$v) = (%$h);
                my $new_k = $asn2openssl{$k};
                if (!$new_k) {
                    warn "Found ASN.1 X509 field $k which doesn't have an OpenSSL mapping";
                    next;

 view all matches for this distribution


Crypt-OpenSSL-RSA

 view release on metacpan or  search on metacpan

t/rsa.t  view on Meta::CPAN

}

sub _Test_Encrypt_And_Decrypt {
    my ( $p_plaintext_length, $p_rsa, $p_check_private_encrypt ) = @_;

    my ( $ciphertext, $decoded_text );
    my $plaintext = pack(
        "C${p_plaintext_length}",
        (
            1, 255, 0, 128, 4,    # Make sure these characters work
            map { int( rand 256 ) } ( 1 .. $p_plaintext_length - 5 )
        )
    );
    ok( $ciphertext   = $p_rsa->encrypt($plaintext) );
    ok( $decoded_text = $p_rsa->decrypt($ciphertext) );
    ok( $decoded_text eq $plaintext );

    if ($p_check_private_encrypt) {
        ok( $ciphertext   = $p_rsa->private_encrypt($plaintext) );
        ok( $decoded_text = $p_rsa->public_decrypt($ciphertext) );
        ok( $decoded_text eq $plaintext );
    }
}

sub _Test_Sign_And_Verify {
    my ( $plaintext, $rsa, $rsa_pub, $hash ) = @_;

 view all matches for this distribution


Crypt-OpenSSL3

 view release on metacpan or  search on metacpan

examples/ciphers.pl  view on Meta::CPAN

$context2->init($cipher, $key, $iv, 0) or die;

my $dec1 = $context2->update($ciphertext) // die;
my $dec2 = $context2->final // die;

my $decoded = $dec1 . $dec2;

say $decoded;

say "Padding was ", $context->get_param('padding');
$context->set_params({ padding => 1 });
say "Padding is now ", $context->get_param('padding');

 view all matches for this distribution


Crypt-OpenToken

 view release on metacpan or  search on metacpan

lib/Crypt/OpenToken.pm  view on Meta::CPAN

    # fixup: convert "_" to "/" (PingId PHP bindings encode this way)
    # fixup: convert "-" to "+" (PingId PHP bindings encode this way)
    $token_str =~ tr{_-}{/+};

    # Base64 decode it, and we're done.
    my $decoded = decode_base64($token_str);
    return $decoded;
}

# Custom Base64 encoding; OTK has some oddities in how they encode things
# using Base64.
sub _base64_encode {

 view all matches for this distribution


Crypt-PKCS10

 view release on metacpan or  search on metacpan

lib/Crypt/PKCS10.pm  view on Meta::CPAN

    return $pkinfo;
}

# OIDs requiring some sort of special handling
#
# Called with decoded value, returns updated value.
# Key is ASN macro name

my %special;
%special =
(

lib/Crypt/PKCS10.pm  view on Meta::CPAN

sub _convert_extensionRequest {
    my $self = shift;
    my( $extensionRequest ) = @_;

    my $parser = $self->_init('extensionRequest');
    my $decoded = $parser->decode($extensionRequest) or return [];

    foreach my $entry (@{$decoded}) {
	my $name = $oids{ $entry->{extnID} };
	$name = $variantNames{$name} if( defined $name && exists $variantNames{$name} );
        if (defined $name) {
	    my $asnName = $name;
	    $asnName =~ tr/ //d;

lib/Crypt/PKCS10.pm  view on Meta::CPAN

		$dec = $action->( $self, $dec, $asnName, $entry );
	    }
	    $entry->{extnValue} = $dec;
        }
    }
    @{$decoded} = grep { defined } @{$decoded};
    return $decoded;
}

sub _convert_rdn {
    my $self = shift;
    my $typeandvalue = shift;

lib/Crypt/PKCS10.pm  view on Meta::CPAN


    my( $tlen, undef, $tag ) = asn_decode_tag2( $self->{signatureAlgorithm}{parameters} );
    if( $tlen != 0 && $tag != ASN_NULL ) {
        return $self->{signatureAlgorithm}{parameters}
    }
    # Known algorithm's parameters MAY return a hash of decoded fields.
    # For now, leaving that to the caller...

    return;
}

lib/Crypt/PKCS10.pm  view on Meta::CPAN

=head1 SYNOPSIS

    use Crypt::PKCS10;

    Crypt::PKCS10->setAPIversion( 1 );
    my $decoded = Crypt::PKCS10->new( $csr ) or die Crypt::PKCS10->error;

    print $decoded;

    @names = $decoded->extensionValue('subjectAltName' );
    @names = $decoded->subject unless( @names );

    %extensions = map { $_ => $decoded->extensionValue( $_ ) } $decoded->extensions

=head1 DESCRIPTION

C<Crypt::PKCS10> parses PKCS #10 certificate requests (CSRs) and provides accessor methods to extract the data in usable form.

lib/Crypt/PKCS10.pm  view on Meta::CPAN


=head1 METHODS

Access methods may exist for subject name components that are not listed here.  To test for these, use code of the form:

  $locality = $decoded->localityName if( $decoded->can('localityName') );

If a name component exists in a CSR, the method will be present.  The converse is not (always) true.

=head2 class method setAPIversion( $version )

lib/Crypt/PKCS10.pm  view on Meta::CPAN


The request may be PEM or binary DER encoded.  Only one request is processed.

If PEM, other data (such as mail headers) may precede or follow the CSR.

    my $decoded = Crypt::PKCS10->new( $csr ) or die Crypt::PKCS10->error;

Returns C<undef> if there is an I/O error or the request can not be parsed successfully.

Call C<error()> to obtain more detail.

lib/Crypt/PKCS10.pm  view on Meta::CPAN


=head3 commonName

Returns the common name(s) from the subject.

    my $cn = $decoded->commonName();

=head3 organizationalUnitName

Returns the organizational unit name(s) from the subject

lib/Crypt/PKCS10.pm  view on Meta::CPAN

=head2 signatureParams

Returns the parameters associated with the B<signatureAlgorithm> as binary.
Returns B<undef> if none, or if B<NULL>.

Note: In the future, some B<signatureAlgorithm>s may return a hashref of decoded fields.

Callers are advised to check for a ref before decoding...

=head2 signature( $format )

The CSR's signature is returned.

If C<$format> is B<1>, in binary.

If C<$format> is B<2>, decoded as an ECDSA signature - returns hashref to C<r> and C<s>.

Otherwise, in its hexadecimal representation.

=head2 attributes( $name )

lib/Crypt/PKCS10.pm  view on Meta::CPAN


Special characters are escaped as described in options.

In array context, the value(s) are returned as a list of items, which may be references.

 print( " $_: ", scalar $decoded->attributes($_), "\n" )
                                   foreach ($decoded->attributes);


=for readme stop

See the I<Table of known OID names> below for a list of names.

lib/Crypt/PKCS10.pm  view on Meta::CPAN


The names vary depending on the API version; however, the returned names are acceptable to C<extensionValue>, C<extensionPresent>, and C<name2oid>.

The values of extensions vary, however the following code fragment will dump most extensions and their value(s).

 print( "$_: ", $decoded->extensionValue($_,1), "\n" ) foreach ($decoded->extensions);


The sample code fragment is not guaranteed to handle all cases.
Production code needs to select the extensions that it understands and should respect
the B<critical> boolean.  B<critical> can be obtained with extensionPresent.

 view all matches for this distribution


Crypt-PQClean-Sign

 view release on metacpan or  search on metacpan

pqclean/crypto_kem/hqc-128/clean/reed_muller.c  view on Meta::CPAN

 * @brief Decodes the received word
 *
 * Decoding uses fast hadamard transform, for a more complete picture on Reed-Muller decoding, see MacWilliams, Florence Jessie, and Neil James Alexander Sloane.
 * The theory of error-correcting codes codes @cite macwilliams1977theory
 *
 * @param[out] msg Array of size VEC_N1_SIZE_64 receiving the decoded message
 * @param[in] cdw Array of size VEC_N1N2_SIZE_64 storing the received word
 */
void PQCLEAN_HQC128_CLEAN_reed_muller_decode(uint8_t *msg, const uint64_t *cdw) {
    uint16_t expanded[128];
    uint16_t transform[128];

 view all matches for this distribution


Crypt-Passphrase

 view release on metacpan or  search on metacpan

lib/Crypt/Passphrase.pm  view on Meta::CPAN


If your application is deployed by different people than it's developed by it may be helpful to have the configuration for C<Crypt::Passphrase> part of your application configuration file and not be hardcoded so that your users can choose the right s...

=head2 Unicode

C<Crypt::Passphrase> considers passwords to be text, and as such you should ensure any password input is decoded if it contains any non-ascii characters. C<Crypt::Passphrase> will take care of both normalizing and encoding such input.

=head2 DOS attacks

Hashing passwords is by its nature a heavy operations. It can be abused by malignant actors who want to try to DOS your application. It may be wise to do some form of DOS protection such as a proof-of-work scheme or a captcha.

 view all matches for this distribution


Crypt-Perl

 view release on metacpan or  search on metacpan

t/Crypt-Perl-RSA-PKCS1_v1_5.t  view on Meta::CPAN

$_->[0] =~ tr<.><>d for values %strs;

for my $hash_alg (sort keys %strs) {
    my $binary = pack 'H*', $strs{$hash_alg}[0];

    my $decoded;

    lives_ok(
        sub {
            $decoded = Crypt::Perl::RSA::PKCS1_v1_5::decode($binary, $hash_alg);
        },
        "decode() succeeds ($hash_alg)",
    );

    is(
        sprintf('%v.02x', $decoded),
        $strs{$hash_alg}[1],
        "decoded $hash_alg payload",
    );
}

done_testing();

 view all matches for this distribution


Crypt-RNCryptor

 view release on metacpan or  search on metacpan

t/90_rncryptor.t  view on Meta::CPAN

    };

TODO: {
    local $TODO = q{
The length of encryption/hmac key have to be 32,
but the length of the data decoded each value of "enc_key_hex"/"hmac_key_hex"
is only 16. Maybe this is mistake of the test vector.
Thus, The following tests are failed because I cannot guess the real value.
    };
    subtest 'key' => sub {
        my $vp = t::assets::VectorParser->load(3, 'key');

 view all matches for this distribution


Crypt-RSA

 view release on metacpan or  search on metacpan

lib/Crypt/RSA.pm  view on Meta::CPAN

    my $key              = $params{Key}; 

    return $self->error ($key->errstr, \%params, $key) unless $key->check();

    if ($params{Armour} || $params{Armor}) { 
        my $decoded = $self->{pp}->unarmour ($cyphertext) ||
            return $self->error ($self->{pp}->errstr());
        $cyphertext = $$decoded{Content}{Cyphertext}
    }

    my $plaintext;
    my $blocksize = blocksize ( $$self{es}->decryptblock (Key => $key),
                                length($cyphertext)

lib/Crypt/RSA.pm  view on Meta::CPAN

sub verify { 

    my ($self, %params) = @_;

    if ($params{Armour} || $params{Armor}) { 
        my $decoded  = $self->{pp}->unarmour ($params{Signature}) ||
            return $self->error ($self->{pp}->errstr());
        $params{Signature} = $$decoded{Content}{Signature}
    }

    my $verify = $self->{ss}->verify (%params) || 
        return $self->error ($self->{ss}->errstr, $params{Key}, \%params);

 view all matches for this distribution


Crypt-Rijndael

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN


1.14 - 2019-06-14
    * Fix UINT32 and UINT8 for musl libc

1.13 - 2015-05-23
    * Correctly null-terminate encoded/decoded strings (RT 769/#5)

1.12 - 2014-01-03
	* Get rid of MYMETA

1.11 - 2012-07-28

 view all matches for this distribution


( run in 1.205 second using v1.01-cache-2.11-cpan-9383018d099 )