view release on metacpan or search on metacpan
doc/large-subset/tools/large-subset-env-affects-shell.tsv view on Meta::CPAN
NB:12482 one unchanged msg-own msg-own msg-own msg-own msg-own
NB:12484 one unchanged =dash =dash =dash =dash =dash vars:read:EDITOR
NB:12485 several changed same same same msg=dash msg=dash same same msg=dash msg=dash msg=dash msg=dash vars:read:aliascmd
NB:12489 one changed same same same same =bash tilde:tilde:~/src
NB:1251 several unchanged same same same same same
NB:12569 one unchanged msg-own msg-own msg-own msg-own msg-own tilde:tilde:~/.vagrant.d/less_insecure_private_key
NB:12573 several unchanged same same
NB:12605 one changed same same same same =bash
NB:1298 one changed same same same same =bash tilde:tilde:~/mydir
NB:1305 several unchanged same same same same same
NB:132 one unchanged msg-own msg-own msg-own msg-own msg-own tilde:tilde:~/src/
doc/large-subset/tools/large-subset-env-affects-shell.tsv view on Meta::CPAN
TL:common/read.md:28 one unchanged same same same same same input:stdin:
TL:common/read.md:8 one unchanged same same same same same input:stdin:
TL:common/regex.md:22 one unchanged msg-own msg-own msg-own msg-own msg-own msg-own msg-own msg-own msg-own msg-own msg-own files:glob:a*
TL:common/regex.md:34 one unchanged msg-own msg-own msg-own msg-own msg-own msg-own msg-own msg-own msg-own msg-own msg-own files:glob:[^a]
TL:common/runit.md:12 one unchanged =bash =bash =bash =bash =bash
TL:common/scp.md:33 one unchanged msg-own msg-own msg-own msg-own msg-own tilde:tilde:~/.ssh/private_key
TL:common/shift.md:8 one changed =dash =dash same same same args:arg:@
TL:common/source.md:24 one changed =dash =dash same same =dash files:dot:path/to/file
TL:common/ssh-agent.md:10 several unchanged msg-own msg-own msg-own msg-own msg-own
TL:common/ssh-keygen.md:13 one unchanged msg-own msg-own msg-own msg-own msg-own tilde:tilde:~/.ssh/filename
TL:common/ssh-keygen.md:25 one unchanged msg-own msg-own msg-own msg-own msg-own tilde:tilde:~/.ssh/filename
TL:common/ssh-keygen.md:29 one unchanged msg-own msg-own msg-own msg-own msg-own tilde:tilde:~/.ssh/filename
TL:common/ssh-keygen.md:33 one unchanged msg-own msg-own msg-own msg-own msg-own tilde:tilde:~/.ssh/OpenSSH_private_key
TL:common/ssh-keygen.md:37 one unchanged msg-own msg-own msg-own msg-own msg-own tilde:tilde:~/.ssh/OpenSSH_private_key
TL:common/ssh-keyscan.md:20 one changed =dash =dash =dash =dash =dash =dash =dash =dash =dash =dash =dash msg-own =dash =dash tilde:tilde:~/.ssh/known_hosts files:>>:~/.ssh/known_hosts
TL:common/starship-init.md:12 one changed msg-own msg-own =dash =dash =dash =dash =dash =dash =dash =dash =dash msg-own =dash =dash tilde:tilde:~/.bashrc files:>>:~/.bashrc
TL:common/starship-init.md:16 one changed msg-own msg-own =dash =dash =dash =dash =dash =dash =dash =dash =dash msg-own =dash =dash tilde:tilde:~/.zshrc files:>>:~/.zshrc
TL:common/time.md:10 one unchanged =dash =dash =dash =dash =dash
TL:common/time.md:14 one unchanged =dash =dash =dash =dash =dash
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Protocol/ACME.pm view on Meta::CPAN
"Protocol::ACME object. This will use a native openssl binary instead.";
}
eval
{
$key = Crypt::OpenSSL::RSA->new_private_key($keystring);
};
if ( $@ )
{
_throw( "Error creating a key structure from the account key" );
}
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Protocol/OTR.pm view on Meta::CPAN
use Protocol::OTR qw( :constants );
my $otr = Protocol::OTR->new(
{
privkeys_file => "otr.private_key",
contacts_file => "otr.fingerprints",
instance_tags_file => "otr.instance_tags",
}
);
lib/Protocol/OTR.pm view on Meta::CPAN
=head2 new
my $otr = Protocol::OTR->new(
{
privkeys_file => "otr.private_key",
contacts_file => "otr.fingerprints",
instance_tags_file => "otr.instance_tags",
}
);
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Proxy/Impersonate/Cert.pm view on Meta::CPAN
# Use the validated in-memory pair for every handshake.
sub apply_to_ctx {
my ($self, $ctx) = @_;
Net::SSLeay::CTX_use_certificate($ctx, $self->{cert})
&& Net::SSLeay::CTX_use_PrivateKey($ctx, $self->{key})
&& Net::SSLeay::CTX_check_private_key($ctx)
or Carp::croak('Cert: invalid or mismatched certificate/key pair');
}
sub _spew {
my ($path, $data, $mode) = @_;
view all matches for this distribution
view release on metacpan or search on metacpan
example/Notify/lib/Notify.pm view on Meta::CPAN
# the old one would be undeliverable in silence. `punk push keys` prints a
# pair; bin/seed.pl puts one in var/ for the demo.
plugin 'Push' => {
subject => $ENV{PUSH_SUBJECT} || 'mailto:demo@example.com',
public_key => $ENV{VAPID_PUBLIC} || '',
private_key => $ENV{VAPID_PRIVATE} || '',
};
get '/' => 'Web::Root#index', { name => 'home' };
get '/login' => 'Web::Root#login_form', { name => 'login' };
post '/login' => 'Web::Root#login';
view all matches for this distribution
view release on metacpan or search on metacpan
t/1200-config.t view on Meta::CPAN
# These assert the silence, so reintroducing it fails here rather than in
# somebody's boot log.
{
unlink "$dir/punk.local.yml" if -e "$dir/punk.local.yml";
for my $key (qw(password passwd secret token api_key private_key
credentials auth)) {
write_file('punk.yml', "thing:\n $key: something\n");
my @warned;
{
local $SIG{__WARN__} = sub { push @warned, $_[0] };
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Puppet/Classify.pm view on Meta::CPAN
my $uri = "https://".$self->server_name.":".$self->server_port."/classifier-api/v1/groups/$id";
my $ssl_opts = { verify_hostname => 1, SSL_ca_file => $self->puppet_ssl_path."/certs/ca.pem" };
if( $self->cert_name ){
$ssl_opts->{SSL_cert_file} = $self->puppet_ssl_path."/certs/".$self->cert_name.".pem";
$ssl_opts->{SSL_key_file} = $self->puppet_ssl_path."/private_keys/".$self->cert_name.".pem";
} else {
%headers = ( 'X-Authentication' => $self->access_token );
}
my $ua = LWP::UserAgent->new( timeout => $self->timeout, ssl_opts => $ssl_opts );
lib/Puppet/Classify.pm view on Meta::CPAN
my $uri = "https://".$self->server_name.":".$self->server_port."/classifier-api/v1/$action";
my $req = HTTP::Request->new( $type, $uri );
my $ssl_opts = { verify_hostname => 1, SSL_ca_file => $self->puppet_ssl_path."/certs/ca.pem" };
if( $self->cert_name ){
$ssl_opts->{SSL_cert_file} = $self->puppet_ssl_path."/certs/".$self->cert_name.".pem";
$ssl_opts->{SSL_key_file} = $self->puppet_ssl_path."/private_keys/".$self->cert_name.".pem";
} else {
$req->header( 'X-Authentication' => $self->access_token );
}
my $ua = LWP::UserAgent->new( timeout => $self->timeout, ssl_opts => $ssl_opts );
if( $type eq 'POST' ){
lib/Puppet/Classify.pm view on Meta::CPAN
my $uri = "https://".$self->server_name.":".$self->server_port."/classifier-api/v1/$action";
my $req = HTTP::Request->new( 'GET', $uri );
my $ssl_opts = { verify_hostname => 1, SSL_ca_file => $self->puppet_ssl_path."/certs/ca.pem" };
if( $self->has_cert_name ){
$ssl_opts->{SSL_cert_file} = $self->puppet_ssl_path."/certs/".$self->cert_name.".pem";
$ssl_opts->{SSL_key_file} = $self->puppet_ssl_path."/private_keys/".$self->cert_name.".pem";
} else {
$req->header( 'X-Authentication' => $self->access_token );
}
my $ua = LWP::UserAgent->new( timeout => $self->timeout, ssl_opts => $ssl_opts );
my $response = $ua->request( $req );
lib/Puppet/Classify.pm view on Meta::CPAN
my $uri = "https://".$self->server_name.":".$self->server_port."/classifier-api/v1/$action";
my $req = HTTP::Request->new( 'POST', $uri );
my $ssl_opts = { verify_hostname => 1, SSL_ca_file => $self->puppet_ssl_path."/certs/ca.pem" };
if( $self->has_cert_name ){
$ssl_opts->{SSL_cert_file} = $self->puppet_ssl_path."/certs/".$self->cert_name.".pem";
$ssl_opts->{SSL_key_file} = $self->puppet_ssl_path."/private_keys/".$self->cert_name.".pem";
} else {
$req->header( 'X-Authentication' => $self->access_token );
}
my $ua = LWP::UserAgent->new( timeout => $self->timeout, ssl_opts => $ssl_opts );
$req->header( 'Content-Type' => 'application/json' );
view all matches for this distribution
view release on metacpan or search on metacpan
lib/RDF/Crypt/Decrypter.pm view on Meta::CPAN
sub decrypt_bytes
{
my ($self, $text) = @_;
$text = decode_base64($text);
my $key = $self->private_key;
my $block_size = $key->size - 16;
my $iv = substr($text, 0, $block_size);
my $removal_chars = unpack('n', substr($text, $block_size, 2));
my $scrambled = substr($text, $block_size + 2);
lib/RDF/Crypt/Decrypter.pm view on Meta::CPAN
sub encrypt_bytes
{
my ($self, $text) = @_;
encode_base64(
$self->private_key->private_encrypt($text)
);
}
1;
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Rapi/Blog.pm view on Meta::CPAN
sub _enforce_valid_recaptcha_config {
my $self = shift;
my $cfg = $self->recaptcha_config or return 1; # No config at all is valid
my @valid_keys = qw/public_key private_key verify_url strict_mode/;
my %keys = map {$_=>1} @valid_keys;
for my $k (keys %$cfg) {
$keys{$k} or die join('',
"Unknown recaptcha_config param '$k' - ",
"only valid params are: ",join(', ',@valid_keys)
)
}
die "Invalid recaptcha_config - both 'public_key' and 'private_key' params are required"
unless ($cfg->{public_key} && $cfg->{private_key});
if(exists $cfg->{strict_mode}) {
my $v = $cfg->{strict_mode};
my $disp = defined $v ? "'$v'" : 'undef';
die "Bad value $disp for 'strict_mode' in recaptcha_config - must be either 1 (true) or 0 (false)\n"
lib/Rapi/Blog.pm view on Meta::CPAN
=head3 public_key
Required. The public, or "SITE KEY" provided by the Google reCAPTCHA settings, after being setup in the
Google reCAPTCHA system L<www.google.com/recaptcha/admin|http://www.google.com/recaptcha/admin>
=head3 private_key
Required. The private, or "SECRET KEY" provided by the Google reCAPTCHA settings, after being setup in the
Google reCAPTCHA system L<www.google.com/recaptcha/admin|http://www.google.com/recaptcha/admin>. Both the
C<public_key> and the C<private_key> are provided as a pair and both are required.
=head3 verify_url
Optional URL to use when performing the actual reCAPCTHA validation with Google. Defaults to
C<https://www.google.com/recaptcha/api/siteverify> which should probably never need to be changed.
view all matches for this distribution
view release on metacpan or search on metacpan
deps/hiredis/hiredis_ssl.h view on Meta::CPAN
/* Options to create an OpenSSL context. */
typedef struct {
const char *cacert_filename;
const char *capath;
const char *cert_filename;
const char *private_key_filename;
const char *server_name;
int verify_mode;
} redisSSLOptions;
/**
deps/hiredis/hiredis_ssl.h view on Meta::CPAN
* and use for validation.
*
* capath is an optional directory path where trusted CA certificate files are
* stored in an OpenSSL-compatible structure.
*
* cert_filename and private_key_filename are optional names of a client side
* certificate and private key files to use for authentication. They need to
* be both specified or omitted.
*
* server_name is an optional and will be used as a server name indication
* (SNI) TLS extension.
deps/hiredis/hiredis_ssl.h view on Meta::CPAN
* If error is non-null, it will be populated in case the context creation fails
* (returning a NULL).
*/
redisSSLContext *redisCreateSSLContext(const char *cacert_filename, const char *capath,
const char *cert_filename, const char *private_key_filename,
const char *server_name, redisSSLContextError *error);
/**
* Helper function to initialize an OpenSSL context that can be used
* to initiate SSL connections. This is a more extensible version of redisCreateSSLContext().
view all matches for this distribution
view release on metacpan or search on metacpan
deps/hiredis/README.md view on Meta::CPAN
/* Create SSL context */
redisSSLOptions ssl_options = {
.cacert_filename = "cacertbundle.crt", /* File name of trusted CA/ca bundle file, optional */
.capath = "/path/to/certs", /* Path of trusted certificates, optional */
.cert_filename = "client_cert.pem", /* File name of client certificate file, optional */
.private_key_filename = "client_key.pem", /* File name of client private key, optional */
.server_name = "redis.mydomain.com", /* Server name to request (SNI), optional */
.verify_mode = REDIS_SSL_VERIFY_PEER, /* Verify the peer certificate */
.verify_name = "redis.mydomain.com", /* DNS name or IP the peer certificate must carry */
};
ssl_context = redisCreateSSLContextWithOptions(&ssl_options, &ssl_error);
view all matches for this distribution
view release on metacpan or search on metacpan
eg/hetzner-gpu.pl view on Meta::CPAN
my $key = $ENV{REX_KEY} || "$ENV{HOME}/.ssh/id_ed25519";
my $user = $ENV{REX_USER} || 'root';
set connection => 'LibSSH';
set user => $user;
set private_key => $key;
set public_key => "$key.pub";
set auth => 'key';
group 'avatar' => 'avatar.conflict.industries';
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Rex/Inline.pm view on Meta::CPAN
use_debug => 0
# now you can set default authentication
user => $user, # optional
password => $password, # optional
public_key => $public_key, # optional
private_key => $private_key,# optional
);
# add default authentication
# if you didn't provide authentication in your task, Rex::Inline will use this as default one
# or if your authentication is failed, Rex::Inline will use this retry the ssh connection
lib/Rex/Inline.pm view on Meta::CPAN
sudo => TRUE,
});
$rex_inline->add_auth({
user => $user,
public_key => $public_key,
private_key => $private_key,
});
# data reference like this
$rex_inline->add_task(
{
lib/Rex/Inline.pm view on Meta::CPAN
server => [@server],
# if need password
password => $password,
# optional
public_key => $public_key,
private_key => $private_key,
}
);
# or Rex::Inline::Test is based on Rex::Inline::Base module
# See Rex::Inline::Base Documents
lib/Rex/Inline.pm view on Meta::CPAN
server => [@server],
# if need password
password => $password,
# optional
public_key => $public_key,
private_key => $private_key,
# input param, in any format you want
input => $input,
)
);
lib/Rex/Inline.pm view on Meta::CPAN
=item password
set default ssh connection password
=item private_key
set default private_key filename
=item public_key
set default public_key filename
=cut
has [qw(user password private_key public_key)] => (is => 'ro', predicate => 1);
=item use_debug
set/get debug option (Bool)
lib/Rex/Inline.pm view on Meta::CPAN
server => [@server2],
# if need password
password => $password2,
# optional
public_key => $public_key2,
private_key => $private_key2,
});
...
=cut
lib/Rex/Inline.pm view on Meta::CPAN
sudo => TRUE,
});
$rex_inline->add_auth({
user => $user,
public_key => $public_key,
private_key => $private_key,
});
=cut
has auth => (
lib/Rex/Inline.pm view on Meta::CPAN
### default auth
my @default_auth;
if ($self->{user}) {
@default_auth = ( user => $self->{user} );
for (qw(password public_key private_key)) {
push @default_auth, $_ => $self->{$_} if $self->{$_};
}
}
$self->add_auth({@default_auth}) if @default_auth;
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Rex/JobControl/Helper/Project/Rexfile.pm view on Meta::CPAN
if ( exists $srv_object->{auth}->{public_key} ) {
$ENV{REX_PUBLIC_KEY} = $srv_object->{auth}->{public_key};
}
if ( exists $srv_object->{auth}->{private_key} ) {
$ENV{REX_PRIVATE_KEY} = $srv_object->{auth}->{private_key};
}
if ( exists $srv_object->{auth}->{user} ) {
$ENV{REX_USER} = $srv_object->{auth}->{user};
}
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Rex/Interface/Connection/LibSSH.pm view on Meta::CPAN
my $server = $opt{server};
my $port = $opt{port} || Rex::Config->get_port( server => $server ) || 22;
my $timeout = $opt{timeout} || Rex::Config->get_timeout( server => $server ) || 10;
my $user = $opt{user};
my $password = $opt{password};
my $privkey = $opt{private_key};
my $auth = $opt{auth_type} // 'key';
$self->{server} = $server;
$self->{is_sudo} = $opt{sudo};
$self->{__auth_info__} = \%opt;
view all matches for this distribution
view release on metacpan or search on metacpan
eg/hetzner-gpu.Rexfile view on Meta::CPAN
# --- Connection ---
set connection => 'LibSSH';
set user => ($ENV{REX_USER} || 'root');
set private_key => ($ENV{REX_KEY} || "$ENV{HOME}/.ssh/id_ed25519");
set public_key => ($ENV{REX_KEY} ? "$ENV{REX_KEY}.pub" : "$ENV{HOME}/.ssh/id_ed25519.pub");
set auth => 'key';
# ============================================================
# Main deployment
view all matches for this distribution
view release on metacpan or search on metacpan
Rex::connect(
server => "remotehost",
user => "root",
password => "f00b4r",
private_key => "/path/to/private/key/file",
public_key => "/path/to/public/key/file",
);
if(is_file("/foo/bar")) {
print "Do something...\n";
view all matches for this distribution
view release on metacpan or search on metacpan
lib/SPVM/Net/SSLeay/Constant.pm view on Meta::CPAN
C<static method NID_pkcs9_unstructuredName : int ();>
Returns the value of C<NID_pkcs9_unstructuredName>. If this constant is not defined on the system, an exception is thrown with the error id set to the basic type ID of the L<Error::NotSupported|SPVM::Error::NotSupported> class.
=head2 NID_private_key_usage_period
C<static method NID_private_key_usage_period : int ();>
Returns the value of C<NID_private_key_usage_period>. If this constant is not defined on the system, an exception is thrown with the error id set to the basic type ID of the L<Error::NotSupported|SPVM::Error::NotSupported> class.
=head2 NID_rc2_40_cbc
C<static method NID_rc2_40_cbc : int ();>
view all matches for this distribution
view release on metacpan or search on metacpan
lib/STIX/Observable/Type/X509V3Extensions.pm view on Meta::CPAN
'http://raw.githubusercontent.com/oasis-open/cti-stix2-json-schemas/stix2.1/schemas/observables/x509-certificate.json#/definitions/x509-v3-extensions-type';
use constant PROPERTIES => (qw(
basic_constraints name_constraints policy_constraints key_usage extended_key_usage subject_key_identifier
authority_key_identifier subject_alternative_name issuer_alternative_name subject_directory_attributes
crl_distribution_points inhibit_any_policy private_key_usage_period_not_before
private_key_usage_period_not_after certificate_policies policy_mappings
));
has basic_constraints => (is => 'rw', isa => Str);
has name_constraints => (is => 'rw', isa => Str);
has policy_constraints => (is => 'rw', isa => Str);
lib/STIX/Observable/Type/X509V3Extensions.pm view on Meta::CPAN
has issuer_alternative_name => (is => 'rw', isa => Str);
has subject_directory_attributes => (is => 'rw', isa => Str);
has crl_distribution_points => (is => 'rw', isa => Str);
has inhibit_any_policy => (is => 'rw', isa => Str);
has private_key_usage_period_not_before => (
is => 'rw',
isa => InstanceOf ['STIX::Common::Timestamp'],
coerce => sub { ref($_[0]) ? $_[0] : STIX::Common::Timestamp->new($_[0]) },
);
has private_key_usage_period_not_after => (
is => 'rw',
isa => InstanceOf ['STIX::Common::Timestamp'],
coerce => sub { ref($_[0]) ? $_[0] : STIX::Common::Timestamp->new($_[0]) },
);
lib/STIX/Observable/Type/X509V3Extensions.pm view on Meta::CPAN
=item $x509_v3_extensions_type->policy_mappings
Specifies one or more pairs of OIDs; each pair includes an
issuerDomainPolicy and a subjectDomainPolicy
=item $x509_v3_extensions_type->private_key_usage_period_not_after
Specifies the date on which the validity period ends for the private key,
if it is different from the validity period of the certificate.
=item $x509_v3_extensions_type->private_key_usage_period_not_before
Specifies the date on which the validity period begins for the private key,
if it is different from the validity period of the certificate.
=item $x509_v3_extensions_type->subject_alternative_name
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Slovo/Controller/Poruchki.pm view on Meta::CPAN
# POST to Econt to create order
my $_order_struct = $c->_order_struct($o);
my $eco_res = $app->ua->request_timeout(5)->post(
$shop->{crupdate_order_endpoint} =>
{'Content-Type' => 'application/json', Authorization => $shop->{private_key}},
json => $_order_struct
)->res;
$c->debug(
'req_url: ' => $shop->{crupdate_order_endpoint},
' $_order_struct:' => $_order_struct
lib/Slovo/Controller/Poruchki.pm view on Meta::CPAN
# $c->debug('Poruchka:' => $o);
# POST to Econt to create order
my $_order_struct = $c->_order_struct($o);
my $eco_res = $c->app->ua->request_timeout(5)->post(
$shop->{create_awb_endpoint} =>
{'Content-Type' => 'application/json', Authorization => $shop->{private_key}},
json => $_order_struct
)->res;
$c->debug(
'req_url: ' => $shop->{create_awb_endpoint},
' $_order_struct:' => $_order_struct
lib/Slovo/Controller/Poruchki.pm view on Meta::CPAN
# TODO: some logic to use the right shop. We may have multiple
# shops(physical stores) from which we send the orders. For example we may
# choose the shop depending on the IP-location of the user. We want to use
# the closest store to the user to minimise delivery expenses.
# Copy data without private_key.
state $shop = {map { $_ eq 'private_key' ? () : ($_ => $c->config->{shop}{$_}) }
keys %{$c->config->{shop}}};
return $c->render(openapi => $shop);
}
# GET /api/gdpr_consent
view all matches for this distribution
view release on metacpan or search on metacpan
xs/sc_ssl/CTX.pod view on Meta::CPAN
=head2 Functions in alphabetical order
=over
L<check_private_key|Socket::Class::SSL::CTX/check_private_key>,
L<enable_compatibility|Socket::Class::SSL::CTX/enable_compatibility>,
L<new|Socket::Class::SSL::CTX/new>,
L<set_certificate|Socket::Class::SSL::CTX/set_certificate>,
L<set_cipher_list|Socket::Class::SSL::CTX/set_cipher_list>,
L<set_client_ca|Socket::Class::SSL::CTX/set_client_ca>,
L<set_private_key|Socket::Class::SSL::CTX/set_private_key>,
L<set_ssl_method|Socket::Class::SSL::CTX/set_ssl_method>,
L<set_verify_locations|Socket::Class::SSL::CTX/set_verify_locations>,
=back
xs/sc_ssl/CTX.pod view on Meta::CPAN
I<thanks to J. Nick Koston>
use Socket::Class::SSL;
%ssl_args = (
'private_key' => '/path/to/server.key.pem',
'certificate' => '/path/to/server.crt.pem',
'cipher_list' => 'ALL:!ADH:+HIGH:+MEDIUM:-LOW:-SSLv2:-EXP'
);
# create shared context
xs/sc_ssl/CTX.pod view on Meta::CPAN
Additional arguments for the constructor.
=for formatter none
certificate Path to certificate file in PEM format
private_key Path to private key file in PEM format
client_ca Path to PEM formatted file with CA certificates
to send to the client
ca_file A file of CA certificates in PEM format
ca_path A directory containing CA certificates in PEM format
ssl_method One of "SSLv2", "SSLv23", "SSLv3" or "TLSv1"
xs/sc_ssl/CTX.pod view on Meta::CPAN
B<Return Values>
Returns a TRUE value on success or UNDEF on failure.
=item B<set_private_key ( $private_key )>
Adds a private key to the socket.
To change a certificate, private key pair the new certificate needs
to be set before setting the private key.
B<Parameters>
=over
=item I<$private_key>
Path to private key file in PEM format.
=back
B<Return Values>
Returns a TRUE value on success or UNDEF on failure.
=item B<check_private_key ()>
Verifies that the private key agrees with the corresponding public key
in the certificate.
Returns a TRUE value on success or UNDEF on failure.
view all matches for this distribution
view release on metacpan or search on metacpan
examples/webservice_example.pl view on Meta::CPAN
use warnings;
use Digest::SHA1 qw(sha1_hex);
use LWP::UserAgent;
my $private_key = '12345';
my $public_id = 'mcrawfor';
my $content = '';
my $host = "http://solstice.washington.edu";
examples/webservice_example.pl view on Meta::CPAN
my $method = "GET";
#build auth key
my $date = localtime;
my $content_sha1 = $content ? sha1_hex($content) : '';
my $to_sign = "$private_key\n$method\n$url\n$date\n$content_sha1";
my $auth_key = "SolAuth $public_id:". sha1_hex($to_sign);
my $ua = LWP::UserAgent->new;
$ua->agent("Solstice Webservices Client/0.1 ");
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Steemit/WsClient.pm view on Meta::CPAN
use Data::Dumper;
has url => 'https://api.steemit.com/';
has ua => sub { Mojo::UserAgent->new };
has posting_key => undef;
has plain_posting_key => \&_transform_private_key;
=head2 all database api methods of the steemit api
L<https://github.com/steemit/steem/blob/master/libraries/app/database_api.cpp>
lib/Steemit/WsClient.pm view on Meta::CPAN
extensions => [],
signatures => [],
};
my $serialized_transaction = $self->_serialize_transaction_message( $transaction );
my $bin_private_key = $self->plain_posting_key;
require Steemit::ECDSA;
my ( $r, $s, $i ) = Steemit::ECDSA::ecdsa_sign( $serialized_transaction, Math::BigInt->from_bytes( $bin_private_key ) );
$i += 4;
$i += 27;
my $signature = join('', map { unpack 'H*', $_ } ( pack("C", $i ), map { $_->as_bytes} ($r,$s )) );
unless( Steemit::ECDSA::is_signature_canonical_canonical( pack "H*", $signature ) ){
lib/Steemit/WsClient.pm view on Meta::CPAN
return $self->{public_posting_key}
}
sub _transform_private_key {
my( $self ) = @_;
die "posting_key missing" unless( $self->posting_key );
my $base58 = $self->posting_key;
require Steemit::Base58;
my $binary = Steemit::Base58::decode_base58( $base58 );
my $version = substr( $binary, 0, 1 );
my $binary_private_key = substr( $binary, 1, -4);
my $checksum = substr( $binary, -4);
die "invalid version in wif ( 0x80 needed ) " unless $version eq pack "H*", '80';
require Digest::SHA;
my $generated_checksum = substr( Digest::SHA::sha256( Digest::SHA::sha256( $version.$binary_private_key )), 0, 4 );
die "invalid checksum " unless $generated_checksum eq $checksum;
return $binary_private_key;
}
sub _serialize_transaction_message {
my ($self,$transaction) = @_;
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Syntax/Highlight/Engine/Kate/PHP_PHP.pm view on Meta::CPAN
'openssl_public_decrypt',
'openssl_public_encrypt',
'openssl_seal',
'openssl_sign',
'openssl_verify',
'openssl_x509_check_private_key',
'openssl_x509_checkpurpose',
'openssl_x509_export',
'openssl_x509_export_to_file',
'openssl_x509_free',
'openssl_x509_parse',
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Syntax/Highlight/Universal/hrc/inet/php-gen.hrc view on Meta::CPAN
<word name="openssl_public_encrypt"/>
<word name="openssl_seal"/>
<word name="openssl_sign"/>
<word name="openssl_verify"/>
<word name="openssl_x509_checkpurpose"/>
<word name="openssl_x509_check_private_key"/>
<word name="openssl_x509_export"/>
<word name="openssl_x509_export_to_file"/>
<word name="openssl_x509_free"/>
<word name="openssl_x509_parse"/>
<word name="openssl_x509_read"/>
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Syntax/Kamelon/XML/php.xml view on Meta::CPAN
<item>openssl_public_decrypt</item>
<item>openssl_public_encrypt</item>
<item>openssl_seal</item>
<item>openssl_sign</item>
<item>openssl_verify</item>
<item>openssl_x509_check_private_key</item>
<item>openssl_x509_checkpurpose</item>
<item>openssl_x509_export</item>
<item>openssl_x509_export_to_file</item>
<item>openssl_x509_free</item>
<item>openssl_x509_parse</item>
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Test/SSH.pm view on Meta::CPAN
Location used to save data bewteen runs (i.e. generated user and host
key pairs).
The default is C<~/.libtest-ssh-perl>
=item private_keys =E<gt> \@key_paths
List of private keys that will be used for login into the remote host.
The default is to look for keys in C<~/.ssh>.
view all matches for this distribution
view release on metacpan or search on metacpan
utils/remote_detect_launcher.pl view on Meta::CPAN
use JSON;
# NOT finished
my $key_path = "$ENV{HOME}/.ssh/id_rsa.pub";
my $private_key = "$ENV{HOME}/.ssh/id_rsa";
# Local folders
my $log_dir = "../remote_logs";
my $output_dir = "../logs";
make_path($log_dir) unless -d $log_dir;
utils/remote_detect_launcher.pl view on Meta::CPAN
);
# Step 1: Ensure SSH key exists
unless (-e $key_path) {
print colored("No SSH key found, generating...\n", 'yellow');
system("ssh-keygen -t rsa -b 4096 -f $private_key -N ''");
}
# Step 2: Loop over each target
for my $host (@targets) {
my ($ip, $user) = ($host->{ip}, $host->{user});
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Tie/Google/Sheets/Client.pm view on Meta::CPAN
scope => SCOPE,
aud => $sa->{token_uri} // TOKEN_URI,
iat => $now,
exp => $now + 3600,
},
key => \$sa->{private_key},
alg => 'RS256',
);
my $body = join '&',
'grant_type=' . uri_escape('urn:ietf:params:oauth:grant-type:jwt-bearer'),
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Twilio/Http/ValidationClient.pm view on Meta::CPAN
use Twilio::Jwt::JWT;
use Twilio::Jwt::Validation::ClientValidationJwt;
our $VERSION = '2.002';
my @REQUIRED = qw(account_sid api_key_sid credential_sid private_key);
my @SIGNED_HEADERS = qw(authorization host);
sub new {
my ($class, $options) = @_;
$options //= {};
lib/Twilio/Http/ValidationClient.pm view on Meta::CPAN
next if length($options->{$name} // q{});
Twilio::Exceptions::ConfigurationException->throw("$name is required for client validation");
}
# A key that can't sign fails here, at start-up, rather than on the first request.
Twilio::Jwt::JWT->sign('key check', $options->{private_key}, 'RS256');
return $class->SUPER::new($options);
}
# Signed after the parent class has added Authorization, so that header is covered too.
lib/Twilio/Http/ValidationClient.pm view on Meta::CPAN
my $http = Twilio::Http::ValidationClient->new({
account_sid => $account_sid, # AC...
api_key_sid => $api_key_sid, # SK...
credential_sid => $credential_sid, # CR..., the public key you gave Twilio
private_key => $private_key_pem,
});
my $client = Twilio->new($api_key_sid, $api_key_secret,
{ account_sid => $account_sid, http_client => $http });
=head1 DESCRIPTION
lib/Twilio/Http/ValidationClient.pm view on Meta::CPAN
=head2 new
my $http = Twilio::Http::ValidationClient->new(\%options);
C<account_sid>, C<api_key_sid>, C<credential_sid> and C<private_key> (in PEM
form) are required. It throws L<Twilio::Exceptions::ConfigurationException>
when one is missing, and L<Twilio::Exceptions::TwilioException> when the key
can't sign.
=head2 prepare_request
view all matches for this distribution