rhymejerky has asked for the wisdom of the Perl Monks concerning the following question:

I have a script that sends msg to an INN server. I am using Net::NNTP for this connection and uses the authinfo( ) to login to the INN server. I think authinfo( ) is sending the username and pwd in clear text. Is there a way to set up a SSL connection for the username and pwd? I don't really need to encrypt the msg content, but just the username and pwd only. Thanks

Replies are listed 'Best First'.
Re: NNTP over SSL
by sgifford (Prior) on Jun 08, 2004 at 04:34 UTC
    stunnel is a quick and fairly easy way to interface with an SSL protocol, or to add SSL support to an existing application without modifying it.
Re: NNTP over SSL
by drewbie (Chaplain) on Jun 08, 2004 at 02:32 UTC
    What I know about the NNTP protocol can fit in a thimble, but it seems the NNTP server software would have to first support such a login. I don't remember seeing an SSL option in my newsreader software, although there is a "Login w/ Secure Password Authentication" option. A quick look over the Net::NNTP docs did not find any mentions to a secure authentication method, so I think you might be out of luck.

    One possible option (if you have a login on the news server) is to use stunnel or ssh to port forward the NNTP port, which would then be a secure connection. YYMV.

      I have control over the INN server. In fact, it is an internal local news server. So, I can build it with the openssl option. What is port forward? NNTP runs on port 119. If I use port forward, do I first set up an openssl connection with port say 2345 with the news server, and then send news article that way? Thanks
        Essentially you are setting up a new secure communications channel, and telling the OS that any connections to port A should really go over the new channel. I forget the syntax for the ssh commandline client, but the various ssh gui clients generally make it easy to setup as well. There are 2 parts to it: the local and remote end. You say for localhost port X, really use port Y which maps to IP & Port Z. I'm saying this badly so here's some example docs:

        Onlamp.com, Linux Journal, User written

        An example:
        workstation uses port 119 for nntp
        portforward localhost:9119 for localhost:119 to your.news.server:119

Re: NNTP over SSL
by baruch (Beadle) on Jun 08, 2004 at 02:45 UTC

    I think you might need to check the RFC's to see whether any such mechanism even exists for NNTP. Try Sunsite.


    בּרוּך