Article View: rocksolid.nodes
Article #247Re: hey, what do know ? vichan supports nntp
From: Retro Guy
Date: Fri, 15 May 2020 07:04
Date: Fri, 15 May 2020 07:04
50 lines
2629 bytes
2629 bytes
anonymous wrote:
> and here is where the hacking starts:
>
> function nntp_publish($msg, $id) {
> global $config;
> $server = $config["nntpchan"]["server"];
> $s = fsockopen("tcp://$server");
> fgets($s);
> fputs($s, "MODE STREAMrn");
> fgets($s);
> fputs($s, "TAKETHIS $idrn");
> fputs($s, $msg);
> fputs($s, "rn.rn");
> fgets($s);
> fputs($s, "QUITrn");
> fclose($s);
> }
>
>
> they have no auth in this, and i seem to remember that this was solved by
> some ssl certificates or other (in the case of overchan). so if i just
> replace this function with the appropriate counterpart from
> rslight/post.php, that should be it.
Yeah, no auth at all. It's a simple function it seems, so adding auth
shouldn't be difficult at all:
fputs($s,"AUTHINFO USER $server_auth_user\r\n");
$weg=line_read($s);
fputs($s,"AUTHINFO PASS $server_auth_pass\r\n");
$weg=line_read($s);
if (substr($weg,0,3) != "281" {
AUTH FAILED
can't do stuff...
} else {
IT DIDN"T FAIL, YAY!
do stuff...
}
> I have an instance of vichan running on the same machine as rslight now,
> and it should be possible to just use the rslight news server directly.
Do you know if this is sending one message at a time? If so, STREAM isn't
really necessary and could easily be MODE READER. If it's more than one
message, then I can add STREAM to nntp.php
rslight news server doesn't currently support MODE STREAM (I didn't need
it), but it can be added.
Retro Guy
Technical Details
Message-ID:
<154276e6dcdb76f64a817816fa16fe6f$1@rslight.i2p>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!i2pn2.pugleaf.net!archive.newsdeef.eu!archive!apf9.newsdeef.eu!i2pn2.org!.POSTED!not-for-mailReferences:
<d1faafa624cda10417914a17419af431@def4> <a390a213fa3e1af81b3d8c884f62ef13@def4> <a4458e95f3eff77a31ee126a7152c46a$1@z5bqfv5v75kxy7pj.onion>Show Full Headers
Complete Article Headers
Message-ID: <154276e6dcdb76f64a817816fa16fe6f$1@rslight.i2p> Subject: Re: hey, what do know ? vichan supports nntp Date: Fri, 15 May 2020 00:04:09 -0700 From: Retro Guy <retroguy@retrobbs.rocksolidbbs.com> References: <d1faafa624cda10417914a17419af431@def4> <a390a213fa3e1af81b3d8c884f62ef13@def4> <a4458e95f3eff77a31ee126a7152c46a$1@z5bqfv5v75kxy7pj.onion> Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!i2pn2.pugleaf.net!archive.newsdeef.eu!archive!apf9.newsdeef.eu!i2pn2.org!.POSTED!not-for-mail Newsgroups: rocksolid.nodes Organization: Rocksolid Lines: 49 Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7Bit Injection-Info: i2pn2.org; posting-account="retrobbs1"; logging-data="13783"; mail-complaints-to="usenet@i2pn2.org" User-Agent: KNode/4.14.1 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on novabbs.com