Skip to content

Revert #123 Useless cert_text #230

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 16, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 18 additions & 1 deletion lib/Net/SAML2/Binding/POST.pm
Original file line number Diff line number Diff line change
Expand Up @@ -41,13 +41,27 @@ Arguments:

path to the CA certificate for verification

=item B<cert>

path to a certificate that is added to the signed XML. It needs to be the
certificate that includes the public key related to the B<key>

=item B<cert_text>

text form of the certificate in FORMAT_ASN1 or FORMAT_PEM that is used to
verify the signed XML.

=item B<key>

path to a key used to sign the XML.

=back

=cut

has 'cacert' => (isa => 'Maybe[Str]', is => 'ro');

has 'cert' => (isa => 'Str', is => 'ro', required => 0, predicate => 'has_cert');
has 'cert_text' => (isa => 'Str', is => 'ro');
has 'key' => (isa => 'Str', is => 'ro', required => 0, predicate => 'has_key');

=head2 handle_response( $response )
Expand All @@ -68,6 +82,9 @@ sub handle_response {
$self->verify_xml(
$xml,
no_xml_declaration => 1,
$self->cert_text ? (
cert_text => $self->cert_text
) : (),
$self->cacert ? (
cacert => $self->cacert
) : (),
Expand Down