HTTP-Request-FromCurl
view release on metacpan or search on metacpan
0.11 2019-02-26
* Properly handle POST data. The data was previously quoted
as if it were to be interpolated into Perl code even when it was
handed to ->as_request.
Reported by Choroba at https://perlmonks.org/?node_id=1230538
0.10 2019-02-02
* Handle -k, --insecure
This is the easy way out of encryption
* Minimum Perl version is now 5.8.8
Earlier versions are unsupported by IO::Socket::SSL
0.09 2018-12-19
* Sequence expansion
Curl and this module now support specifying sequences of URLs such as
C< https://example.com/[1-100] > , which expands to
C< https://example.com/1 >, C< https://example.com/2 > ...
C< https://example.com/100 >
Such sequences are expanded in-memory at this time, courtesy of
Cartesian Products
"perl" : "5.020"
}
},
"test" : {
"requires" : {
"Capture::Tiny" : "0",
"Data::Dumper" : "0",
"HTTP::CookieJar" : "0",
"HTTP::CookieJar::LWP" : "0",
"HTTP::Tiny" : "0",
"IO::Socket::SSL" : "0",
"LWP::UserAgent" : "0",
"Path::Tiny" : "0",
"Test2::V0" : "0",
"Test::HTTP::LocalServer" : "0.67",
"WWW::Mechanize" : "0"
}
}
},
"release_status" : "stable",
"resources" : {
abstract: 'create a HTTP::Request from a curl command line'
author:
- 'Max Maischein <corion@cpan.org>'
build_requires:
Capture::Tiny: '0'
Data::Dumper: '0'
ExtUtils::MakeMaker: '0'
HTTP::CookieJar: '0'
HTTP::CookieJar::LWP: '0'
HTTP::Tiny: '0'
IO::Socket::SSL: '0'
LWP::UserAgent: '0'
Path::Tiny: '0'
Test2::V0: '0'
Test::HTTP::LocalServer: '0.67'
WWW::Mechanize: '0'
configure_requires:
ExtUtils::MakeMaker: '0'
dynamic_config: 0
generated_by: 'ExtUtils::MakeMaker version 7.64, CPAN::Meta::Converter version 2.150010'
license: perl
Makefile.PL view on Meta::CPAN
'File::Basename' => 0, # core anyway
},
TEST_REQUIRES => {
'Test2::V0' => '0',
'Data::Dumper' => 0,
'Capture::Tiny' => 0,
'Path::Tiny' => 0,
'HTTP::Tiny' => 0,
'WWW::Mechanize' => 0,
'LWP::UserAgent' => 0,
'IO::Socket::SSL' => 0, # for allowing -k to compile
#'HTTP::Cookies::Netscape' => 0, # this can't cope with the Netscape cookie files that curl writes :(
'HTTP::CookieJar' => 0, # this one doesn't have an adapter to save/load at all :(
'HTTP::CookieJar::LWP' => 0, # this one doesn't have an adapter to save/load at all :(
'Test::HTTP::LocalServer' => 0.67, # we want ->server_url()
},
dist => { COMPRESS => 'gzip -9f', SUFFIX => 'gz', },
clean => { FILES => "$distbase-*" },
test => { TESTS => join( ' ', @tests ) },
lib/HTTP/Request/CurlParameters.pm view on Meta::CPAN
$self->_pairlist([
maybe ':content_file', $self->output
], '')
;
my $init_cookie_jar = $self->_init_cookie_jar_lwp();
if( my $p = $init_cookie_jar->{preamble}) {
push @preamble, @{$p}
};
if( $self->insecure ) {
push @preamble, 'use IO::Socket::SSL;';
$ssl_options{ SSL_verify_mode } = \'IO::Socket::SSL::SSL_VERIFY_NONE';
$ssl_options{ SSL_hostname } = '';
$ssl_options{ verify_hostname } = '';
};
if( $self->cert ) {
push @preamble, 'use IO::Socket::SSL;';
$ssl_options{ SSL_ca_file } = $self->cert;
};
if( $self->capath ) {
push @preamble, 'use IO::Socket::SSL;';
$ssl_options{ SSL_ca_path } = $self->capath;
};
my $constructor_args = join ",",
$self->_pairlist([
send_te => 0,
maybe local_address => $self->local_address,
maybe max_size => $self->max_filesize,
maybe timeout => $self->timeout,
maybe cookie_jar => $init_cookie_jar->{code},
maybe SSL_opts => keys %ssl_options ? \%ssl_options : undef,
lib/HTTP/Request/CurlParameters.pm view on Meta::CPAN
if( my $p = $init_cookie_jar->{preamble}) {
push @preamble, @{$p}
};
my @ssl;
if( $self->insecure ) {
} else {
push @ssl, verify_SSL => 1;
};
if( $self->cert ) {
push @preamble, 'use IO::Socket::SSL;';
$ssl_options{ SSL_cert_file } = $self->cert;
};
if( $self->show_error ) {
push @postamble,
' die $res->{reason} if !$res->{success};',
} elsif( $self->fail ) {
push @postamble,
' exit 1 if !$res->{success};',
};
my $constructor_args = join ",",
( run in 1.028 second using v1.01-cache-2.11-cpan-fd5d4e115d8 )