Both IO::Socket::IP and IO::Socket::INET6 are capable of doing IPv4 and IPv6. And since you are explicitly giving a IPv4 address as target and even set AF_INET as domain your problem is not the use of IPv6 and you will have the same problem when disabling it.

If you look at the error it clearly says what the real problem is:

SSL accept attempt failed because of handshake problems error:14094418
+:SSL routines:SSL3_READ_BYTES:tlsv1 alert unknown ca

This means, that the certificate is not signed by a trusted CA. And I guess the name in the certificate will not match the name you gave in the client (i.e. the IP address). And since it complains about the certificate from the server it means that it successfully created a TCP connection to the server and got the certificate inside the SSL handshake. If IPv4 vs. IPv6 would be the problem it would already fail in establishing the TCP connection, so use of IPv6 is not your problem here.


In reply to Re: IO::Socket::SSL as IPV4 by noxxi
in thread IO::Socket::SSL as IPV4 by Bodger

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.