Skip Menu |

This queue is for tickets about the Net-IMAP-Client CPAN distribution.

Report information
The Basics
Id: 84309
Status: patched
Priority: 0/
Queue: Net-IMAP-Client

People
Owner: Nobody in particular
Requestors: yanick+cpan [...] babyl.dyndns.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: 0.9503



Subject: add 'ssl_options' argument
was useful for me to modify the ssl_verify_mode of IO::Socket::SSL. Patch also available at https://github.com/yanick/Net-IMAP-Client
Subject: 0001-add-ssl_options-argument-for-new.patch
From 4781364b829fa309a7bf1ab91d798db54253b95a Mon Sep 17 00:00:00 2001 From: Yanick Champoux <yanick@babyl.dyndns.org> Date: Sat, 30 Mar 2013 12:18:11 -0400 Subject: [PATCH] add 'ssl_options' argument for new() in my case, it was necessary to convince IO::Socket::SSL to have its SSL_verify_mode set to NONE. --- lib/Net/IMAP/Client.pm | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/Net/IMAP/Client.pm b/lib/Net/IMAP/Client.pm index dc2f2e8..b9669a7 100644 --- a/lib/Net/IMAP/Client.pm +++ b/lib/Net/IMAP/Client.pm @@ -26,6 +26,7 @@ my %DEFAULT_ARGS = ( ssl => 0, socket => undef, _cmd_id => 0, + ssl_options => {}, ); sub new { @@ -622,6 +623,7 @@ sub _get_server { sub _get_socket { my ($self) = @_; my $socket = $self->{socket} ||= ($self->{ssl} ? 'IO::Socket::SSL' : 'IO::Socket::INET')->new( + ( ( %{$self->{ssl_options}} ) x !!$self->{ssl} ), PeerAddr => $self->_get_server, PeerPort => $self->_get_port, Timeout => $self->_get_timeout, @@ -1171,6 +1173,10 @@ Password Pass a true value if you want to use IO::Socket::SSL +=item - B<ssl_options> (HASHREF, optional) + +Optional arguments to be passed to the L<IO::Socket::SSL> object. + =item - B<uid_mode> (BOOL, optional, default TRUE) Whether to use UID command (see RFC3501). Recommended. -- 1.7.9.5
On Sat Mar 30 12:22:22 2013, YANICK wrote: Show quoted text
> was useful for me to modify the ssl_verify_mode of IO::Socket::SSL. > > Patch also available at > > https://github.com/yanick/Net-IMAP-Client
I applied this. Thank you.
Subject: Re: [rt.cpan.org #84309] add 'ssl_options' argument
Date: Sun, 19 Jan 2014 16:33:34 -0500
To: "bug-Net-IMAP-Client [...] rt.cpan.org" <bug-Net-IMAP-Client [...] rt.cpan.org>
From: Yanick Champoux <yanick.champoux [...] gmail.com>
Woohoo! You're quite welcome. :-) Sent from my iPhone Show quoted text
> On Jan 18, 2014, at 4:58 PM, "Joel Roth via RT" <bug-Net-IMAP-Client@rt.cpan.org> wrote: > > <URL: https://rt.cpan.org/Ticket/Display.html?id=84309 > >
>> On Sat Mar 30 12:22:22 2013, YANICK wrote: >> was useful for me to modify the ssl_verify_mode of IO::Socket::SSL. >> >> Patch also available at >> >> https://github.com/yanick/Net-IMAP-Client
> > I applied this. Thank you.