This repository has been archived by the owner on Dec 30, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 166
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Test for Perl compatibility with TLSv1.2. (#31)
- Loading branch information
Showing
2 changed files
with
46 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
# Perl | ||
|
||
To ensure that the Perl PayflowPro module will work with TLSv1.2, we | ||
need to verify that the underlying LWP::UserAgent module will support | ||
TLSv1.2. It requires OpenSSL 1.0.1c or later. | ||
|
||
The simplest test is to run this command line on your *production* | ||
server: | ||
|
||
``` | ||
lwp-request https://tlstest.paypal.com/ | ||
``` | ||
|
||
It should output `PayPal_Connection_OK` on success, or an error | ||
message on failure. | ||
|
||
If your system does not have lwp-request command line program | ||
installed as part of the LWP package, you can run the `pfp-test.perl` | ||
program. It will output `PayPal_Connection_OK` on success, or an error | ||
message on failure. | ||
|
||
Sample output: | ||
|
||
``` | ||
Perl: 5.024001 | ||
LWP: 6.22 | ||
PayPal_Connection_OK | ||
``` | ||
|
||
You don't need to run both tests as they are equivalent. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
#!/usr/local/bin/perl | ||
use strict; | ||
|
||
use LWP::UserAgent; | ||
|
||
my $ua = LWP::UserAgent->new; | ||
my $response = $ua->get('https://tlstest.paypal.com/'); | ||
|
||
print "Perl: $]\nLWP: $LWP::UserAgent::VERSION\n"; | ||
|
||
if ($response->is_success) { | ||
print $response->decoded_content,"\n"; | ||
} | ||
else { | ||
die $response->status_line; | ||
} |