🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.nntp
15 messages
15 total messages Started by Gab Tue, 28 Apr 2009 01:11
INND NNTP-Posting-Host
#80783
Author: Gab
Date: Tue, 28 Apr 2009 01:11
27 lines
1854 bytes
Hi all!
I'm trying this script taken here 
https://www.autistici.org/it/stuff/network_howto/newsserver/filter_nnrpd 
which should anonymize users server.
I don't know perl and innd refuses to load the script

root@news:~# su -c "/usr/lib/news/bin/ctlinnd mode" news
Server running
Allowing remote connections
Parameters c 10 i 50 (8) l 1000000 o 1011 t 300 H 2 T 60 X 0 normal 
specified
Not reserved
Readers follow enabled
Perl filtering disabled

root@news:~# su -c "/usr/lib/news/bin/ctlinnd perl y" news
ctlinnd: Perl filter not defined

I'm concerned to keep my users privacy/anonimity and i think this script 
is badly formatted but i don't know where to start from.
Does anyone know a better script ? Is too much if i ask to correct the 
actual ???? :)
Thanks .



Re: INND NNTP-Posting-Host
#80787
Author: Ray Banana
Date: Tue, 28 Apr 2009 04:21
19 lines
2055 bytes
Thus spake noauth@autistici.org (Gab)
 
> Hi all!
> I'm trying this script taken here
> https://www.autistici.org/it/stuff/network_howto/newsserver/filter_nnrpd
> which should anonymize users server.
> I don't know perl and innd refuses to load the script

Please read /usr/share/doc/inn2/hook-perl.gz for a documentation of INN
perl filters and how to install them. If you intend to run an open news
server you might also want to take a look at Paolo Amoroso's Postfilter
that offers some means to prevent abuse of such unrestricted servers.

http://code.google.com/p/postfilter/downloads/list


-- 
Time flies like an arrow, fruit flies like a Banana.
http://news.motzarella.org
Re: INND NNTP-Posting-Host
#80789
Author: Aioe
Date: Tue, 28 Apr 2009 08:15
43 lines
2768 bytes
Gab wrote:

> Hi all!
> I'm trying this script taken here
> https://www.autistici.org/it/stuff/network_howto/newsserver/filter_nnrpd
> which should anonymize users server.

That script simply doesn't work. It's old, unmaintained and highly unsecure. 
IMHO it's  dangerous script that nobody should use with an USENET server 
(btw it was designed for a local server with three groups, no peers and less 
than 50 users, a so extreme level of roughness is understandable under their 
point of view).

Do not use neither their code nor their tutorial if you want to setup an 
*USENET* site. BTW, their tutorial about a way to make the news log 
anonymous with syslog-ng is a folly, do *not* use it on real servers. 

> I don't know perl and innd refuses to load the script

news.err should be your friend. 

BTW $ perl -wc autistici_nnrpd.pl 
Unquoted string "localhost" may clash with future reserved word at 
autistici_nnrpd.pl line 102.
syntax error at autistici_nnrpd.pl line 35, near "/^(.
+?)\@([-\w\d]+\.)*([-\w\d]+)\.([-\w\d]{2,})$/o) "
Missing right curly or square bracket at pp.pl line 105, at end of line
syntax error at autistici_nnrpd.pl line 105, at EOF
autistici_nnrpd.pl had compilation errors.

that script has got three errors in 36 lines (except comments), it's the 
autistici's quality. 

> Does anyone know a better script ? Is too much if i ask to correct the
> actual ???? :)

if you are planning to build an USENET site without authentication, 
postfilter is your best option.

http://code.google.com/p/postfilter/downloads/list

If you need help, write me (i'm the author of postfilter) or here
Re: INND NNTP-Posting-Host
#80791
Author: Gab
Date: Tue, 28 Apr 2009 17:04
157 lines
6238 bytes
This is an OpenPGP/MIME signed message (RFC 2440 and 3156)
--------------enig584BA6ED8494652C9CAD20FB
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

Aioe wrote:
> Gab wrote:
>=20
>> Hi all!
>> I'm trying this script taken here
>> https://www.autistici.org/it/stuff/network_howto/newsserver/filter_nnr=
pd
>> which should anonymize users server.
>=20
> That script simply doesn't work. It's old, unmaintained and highly unse=
cure.=20
> IMHO it's  dangerous script that nobody should use with an USENET serve=
r=20
> (btw it was designed for a local server with three groups, no peers and=
 less=20
> than 50 users, a so extreme level of roughness is understandable under =
their=20
> point of view).
>=20
> Do not use neither their code nor their tutorial if you want to setup a=
n=20
> *USENET* site. BTW, their tutorial about a way to make the news log=20
> anonymous with syslog-ng is a folly, do *not* use it on real servers.=20
>=20
>> I don't know perl and innd refuses to load the script
>=20
> news.err should be your friend.=20
>=20
> BTW $ perl -wc autistici_nnrpd.pl=20
> Unquoted string "localhost" may clash with future reserved word at=20
> autistici_nnrpd.pl line 102.
> syntax error at autistici_nnrpd.pl line 35, near "/^(.
> +?)\@([-\w\d]+\.)*([-\w\d]+)\.([-\w\d]{2,})$/o) "
> Missing right curly or square bracket at pp.pl line 105, at end of line=

> syntax error at autistici_nnrpd.pl line 105, at EOF
> autistici_nnrpd.pl had compilation errors.
>=20
> that script has got three errors in 36 lines (except comments), it's th=
e=20
> autistici's quality.=20
>=20
>> Does anyone know a better script ? Is too much if i ask to correct the=

>> actual ???? :)
>=20
> if you are planning to build an USENET site without authentication,=20
> postfilter is your best option.
>=20
> http://code.google.com/p/postfilter/downloads/list
>=20
> If you need help, write me (i'm the author of postfilter) or here
>=20

Well ... it was rough it was evident to me too , i asked them
explanations and they had no clue either , IMHHHHHO people who says to
support fundamental rights should not be so clearly superficial publicly.=

But let's talk about postfilter :

> # $config{'salt'} -> random string (it's used to add entropy to NNTP-Ho=
sting-Host MD5 sign )

That's what exactly i was looking for and what users asked me to look
after .
I run debian lenny and by apt-cache i searched the perl library needed
for your script hence i have installed :

> libdigest-perl libdigest-sha-perl libdigest-sha1-perl libdigest-md5-fil=
e-perl
> libdigest-hmac-perl libclass-dbi-perl liblogger-syslog-perl libsys-sysl=
og-perl=20
> libtimedate-perl

for
Date::Parse;
Sys::Syslog;
Digest;
Digest::HMAC;
Digest::MD5;
DBI;

Dis i miss anything ?
In postfilter.conf i found reasonable defaults the only important values
i have changed are:

>  'server_status',                          "active",
>   'server_type',                            "public",
>  'allow_mail_headers',                       "true"
It's my will to configure a mail2news
> 'force_default_organization',         "true"
> 'delete_header_sender',               "anon"

We can discuss about the following choice:
> 'block_tor',                               "false",
The tor nodes list is huge and i would feel like some mainstream usenet
provider (i'm not going to mension) , i'll probably learn to pay my
choices on my skin .
Ok i have finished configuring postfilter , i follow last steps in the
INSTALL text .
Fireup slrn , post test article , look at news.err:

news nnrpd: SERVER perl filter not definied

Have i missed to activate perl ? I did restart innd ...

> root@news:~# su -c "/usr/lib/news/bin/ctlinnd perl y" news
> ctlinnd: Perl filter not defined
> root@news:~# su -c "/usr/lib/news/bin/ctlinnd mode" news
> Server running
> Allowing remote connections
> Parameters c 10 i 50 (10) l 1000000 o 1011 t 300 H 2 T 60 X 0 normal sp=
ecified
> Not reserved
> Readers follow enabled
> Perl filtering disabled

Nothing has changed , did  i miss to install some perl library ?
I'm checking inn.conf .

P.S.
Hi Aioe ! Is you aioe.org admin ? You are in my peers list , i don't see
you in my logs since my last stop . I promise i will be more efficient .
I'm getting an ipv6 static address for the purpose here
http://tunnelbroker.net/

happy usenet :)

Gab



--=20
sec   1024D/80231A90 2008-07-01
Key fingerprint =3D 54AC C632 B35E FB9B 6D9F  108D DBE6 5425 8023 1A90



--------------enig584BA6ED8494652C9CAD20FB
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: OpenPGP digital signature
Content-Disposition: attachment; filename="signature.asc"

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)

iEYEAREKAAYFAkn3NzMACgkQ2+ZUJYAjGpDSGgCfbzpR/b79NwLnCrysVN7XjnYF
E4sAn3DHSKjMLbT+oz2wkNTiyCEAFVWz
=X+0L
-----END PGP SIGNATURE-----

--------------enig584BA6ED8494652C9CAD20FB--
Re: INND NNTP-Posting-Host
#80792
Author: Steve Crook
Date: Tue, 28 Apr 2009 17:21
51 lines
2332 bytes
On Tue, 28 Apr 2009 01:11:20 +0000 (UTC), Gab wrote in
Message-Id: <100a1ed66b4e677671a2a84aaedd6c70$1@www.gabrix.ath.cx>:

> Hi all!
> I'm trying this script taken here 
> https://www.autistici.org/it/stuff/network_howto/newsserver/filter_nnrpd 
> which should anonymize users server.
> I don't know perl and innd refuses to load the script

I use this little script.  It doesn't remove the NNTP-Posting-Host
header but does a one-way hash with some added salt.  I prefer this to
completely removing the header as it maintains linkability and hence
filterability.

use strict;
use Digest::MD5;
our (%hdr, $modify_headers);

sub filter_post {

    # Hash the NNTP-Posting-Host header
    my $ctx = Digest::MD5->new;
    $ctx->add($hdr{'NNTP-Posting-Host'});
    $ctx->add("Would you like some salt with that?");
    $hdr{'NNTP-Posting-Host'} = $ctx->hexdigest;
    undef $hdr{'X-Trace'};

    # Refuse these From addresses
    if ($hdr{From} =~ /(
        \@darkshado\.ca
    |   arcturianone\@earthlink\.net
    )/ix) {
        return "Sender address ($1) is blacklisted";
    };

    # Blacklist these groups
    if ($hdr{Newsgroups} =~ /(
        rec\.radio\.amateur\.policy
    |   hr\.alt\.trash
    )/x) {
        return "Posting to $1 is currently blocked";
    };

    $modify_headers = 1;
    return '';
}

-- 
pub   1024D/228761E7 2003-06-04 Steven Crook
      Key fingerprint = 1CD9 95E1 E9CE 80D6 C885  B7EB B471 80D5 2287 61E7
uid                  Steven Crook <steve@mixmin.net>
Re: INND NNTP-Posting-Host
#80794
Author: gabrix
Date: Tue, 28 Apr 2009 18:41
53 lines
2587 bytes
Steve Crook wrote:
> On Tue, 28 Apr 2009 01:11:20 +0000 (UTC), Gab wrote in
> Message-Id: <100a1ed66b4e677671a2a84aaedd6c70$1@www.gabrix.ath.cx>:
> 
>> Hi all!
>> I'm trying this script taken here 
>> https://www.autistici.org/it/stuff/network_howto/newsserver/filter_nnrpd 
>> which should anonymize users server.
>> I don't know perl and innd refuses to load the script
> 
> I use this little script.  It doesn't remove the NNTP-Posting-Host
> header but does a one-way hash with some added salt.  I prefer this to
> completely removing the header as it maintains linkability and hence
> filterability.
> 
> use strict;
> use Digest::MD5;
> our (%hdr, $modify_headers);
> 
> sub filter_post {
> 
>     # Hash the NNTP-Posting-Host header
>     my $ctx = Digest::MD5->new;
>     $ctx->add($hdr{'NNTP-Posting-Host'});
>     $ctx->add("Would you like some salt with that?");
>     $hdr{'NNTP-Posting-Host'} = $ctx->hexdigest;
>     undef $hdr{'X-Trace'};
> 
>     # Refuse these From addresses
>     if ($hdr{From} =~ /(
>         \@darkshado\.ca
>     |   arcturianone\@earthlink\.net
>     )/ix) {
>         return "Sender address ($1) is blacklisted";
>     };
> 
>     # Blacklist these groups
>     if ($hdr{Newsgroups} =~ /(
>         rec\.radio\.amateur\.policy
>     |   hr\.alt\.trash
>     )/x) {
>         return "Posting to $1 is currently blocked";
>     };
> 
>     $modify_headers = 1;
>     return '';
> }
> 

Nop !!!!

> Apr 28 20:40:37 news innd: SERVER perl filter not defined
Re: INND NNTP-Posting-Host
#80803
Author: Kelb tal-Fenek
Date: Tue, 28 Apr 2009 21:21
8 lines
1100 bytes
Steve Crook wrote:
> I use this little script.  It doesn't remove the NNTP-Posting-Host
> header but does a one-way hash with some added salt.  I prefer this to
> completely removing the header as it maintains linkability and hence
> filterability.

I was looking for something like that. Nice and simple. Thank you.
Re: INND NNTP-Posting-Host
#80796
Author: Aioe
Date: Tue, 28 Apr 2009 22:16
116 lines
4057 bytes
Gab wrote:

> But let's talk about postfilter :
> 
>> # $config{'salt'} -> random string (it's used to add entropy to
>> # NNTP-Hosting-Host MD5 sign )
> 
> That's what exactly i was looking for and what users asked me to look
> after .

hint: use a quite long salt

> for
> Date::Parse;
> Sys::Syslog;
> Digest;
> Digest::HMAC;
> Digest::MD5;
> DBI;
> 
> Dis i miss anything ?

use

$ perl -wc src/postfilter.pl

if that command returns "syntax OK", all modules are installed
a future version will include an installer

> In postfilter.conf i found reasonable defaults the only important values
> i have changed are:
> 
>> 'server_status',                          "active",

"active" is the default value and you should keep it

>> 'server_type',                            "public",

if you don't use authentication, it's right

>> 'allow_mail_headers',                       "true"
> It's my will to configure a mail2news

ok

>> 'force_default_organization',         "true"

why do you need this?

>> 'delete_header_sender',               "anon"

if you don't use authentication, this is probably useless because 'Sender' 
isn't added by nnrpd.
If you use some sort of authentication, 'server_type' is set with a wrong 
setting and probably you should delete (with value "true") the sender 
header.

> We can discuss about the following choice:
>> 'block_tor',                               "false",
> The tor nodes list is huge and i would feel like some mainstream usenet
> provider (i'm not going to mension) , i'll probably learn to pay my
> choices on my skin .

imho is a bad idea.
TOR will be quickly used by 'abusers' as weapon against your server and your 
abuse desk will be bombed by people angry with you for messages sent through 
your server. You will probably receive court orders that enforces you to 
provide posting data about your users. This requires skills. 
You're at the beginning, you have to learn before starting a so complex 
task.

> Fireup slrn , post test article , look at news.err:
> 
> news nnrpd: SERVER perl filter not definied

1. Check whether all files are in the right place:

/etc/news/filter/postfilter.pl
/etc/news/filter/modules/*.pm
/etc/news/postfilter/*.conf

2. Try to restart innd

3. Try to post (postfilter logs a lot of data through news.debug)

> P.S.
> Hi Aioe ! Is you aioe.org admin ? 

yes

> You are in my peers list , i don't see
> you in my logs since my last stop . 

my server is not able to establish a connection with your server 

Apr 28 21:00:00 aioe innfeed[2621]: gabrix.ath.cx:0 cxnsleep connect: 
Connection timed out

(firewall troubles?)

Re: INND NNTP-Posting-Host
#80801
Author: Ray Banana
Date: Wed, 29 Apr 2009 03:22
17 lines
2076 bytes
Thus spake Aioe <estasi@aioe.org>
 
>> news nnrpd: SERVER perl filter not definied
> 1. Check whether all files are in the right place:
> /etc/news/filter/postfilter.pl
> /etc/news/filter/modules/*.pm
> /etc/news/postfilter/*.conf

But above all, he should make sure there is a symlink from
/etc/news/filter/postfilter.pl to /etc/news/filter/filter_nnrpd.pl,
which is the name INN is looking for (assuming that pathfilter ist set
to /etc/news/filter/ in inn.conf, which is the default in Debian) or
postfilter.pl is renamed to filter_nnrpd.pl.

-- 
Time flies like an arrow, fruit flies like a Banana.
http://news.motzarella.org
Re: INND NNTP-Posting-Host
#80804
Author: Aioe
Date: Wed, 29 Apr 2009 07:30
11 lines
1505 bytes
Ray Banana wrote:

> But above all, he should make sure there is a symlink from
> /etc/news/filter/postfilter.pl to /etc/news/filter/filter_nnrpd.pl,
> which is the name INN is looking for (assuming that pathfilter ist set
> to /etc/news/filter/ in inn.conf, which is the default in Debian) or
> postfilter.pl is renamed to filter_nnrpd.pl.

yes, it's true
thank you :-)
Re: INND NNTP-Posting-Host
#80806
Author: gabrix
Date: Wed, 29 Apr 2009 18:35
25 lines
2093 bytes
I have installed libbind-dev libnet-ip-perl libnet-dns-perl .
> $ perl -wc src/postfilter.pl
returns null , no error , no syntax OK , i presume is OK.
>>> 'force_default_organization',         "true"
> 
> why do you need this?
>From the postfilter.conf file:
A value of "true" is quite rude (the users have the right to insert
their own organizations) but it's safer.
It's safer ...
> /etc/news/filter/postfilter.pl
> /etc/news/filter/modules/*.pm
> /etc/news/postfilter/*.conf
Files are OK.
root@news:/etc/news/filter# /etc/init.d/inn2 restart
Restarting innd: done.
root@news:/etc/news/filter# tail -f /var/log/news/news.debug
Apr 29 19:22:53 news innd: SERVER perl filter not defined
Apr 29 19:22:53 news innd: SERVER starting

root@news:/etc/news/filter# su -c "/usr/lib/news/bin/ctlinnd perl y"news
ctlinnd: Perl filter not defined
> (firewall troubles?) 
I have an access list to port 119 (only for peers) your server ip is
there ...
Re: INND NNTP-Posting-Host
#80808
Author: Ray Banana
Date: Wed, 29 Apr 2009 18:58
28 lines
2418 bytes
Thus spake gabrix <gabrix@gabrix.ath.cx>
 
> Apr 29 19:22:53 news innd: SERVER perl filter not defined
> Apr 29 19:22:53 news innd: SERVER starting

innd complains about filter_innd.pl. 

> root@news:/etc/news/filter# su -c "/usr/lib/news/bin/ctlinnd perl y"news
> ctlinnd: Perl filter not defined

and here you are trying to activate filter_innd.pl, too. filter_nnrpd.pl
is loaded by nnrpd and you seem to have Postfilter working already on
your server:

| NNTP-Posting-Host: /FJQTvAeo1HePhToZKjA0g.user.news.gabrix.ath.cx
| X-Notice: Filtered by postfilter v. 0.7.7
| Cancel-Lock: sha1:4K41r1x/KNWc35ihbsfZS5S3AOo=

These headers are obviously set by Postfilter running as
filter_nnrpd.pl, filtering articles posted by your own users.

filter_innd.pl is used by innd to filter incoming articles, both from
your peers and from your own users. Typically, Cleanfeed is used for
this purpose.

-- 
Time flies like an arrow, fruit flies like a Banana.
http://news.motzarella.org
Re: INND NNTP-Posting-Host
#80809
Author: gabrix
Date: Wed, 29 Apr 2009 19:31
21 lines
1926 bytes
Ray Banana wrote:
> Thus spake gabrix <gabrix@gabrix.ath.cx>
>  
>> Apr 29 19:22:53 news innd: SERVER perl filter not defined
>> Apr 29 19:22:53 news innd: SERVER starting
> 
> innd complains about filter_innd.pl. 

Yes too right , innd is complaining for filter_innd.pl not nnrpd and
filter_innd.pl is cleanfeed. perl -w filter_innd.pl is OK . There is
something wrong with cleanfeed .

>> root@news:/etc/news/filter# su -c "/usr/lib/news/bin/ctlinnd perl y"news
>> ctlinnd: Perl filter not defined

what's the equivalent command for filter_nnrpd.pl ?

>. Typically, Cleanfeed is used for
> this purpose.

OOOOK !! :)
Re: INND NNTP-Posting-Host
#80810
Author: Ray Banana
Date: Wed, 29 Apr 2009 19:44
12 lines
1854 bytes
Thus spake gabrix <gabrix@gabrix.ath.cx>
 
>>> root@news:/etc/news/filter# su -c "/usr/lib/news/bin/ctlinnd perl y"news
>>> ctlinnd: Perl filter not defined
> what's the equivalent command for filter_nnrpd.pl ?

No need to reload filter_nnrpd.pl, as it is loaded for each new instance
of nnrpd. 

-- 
Time flies like an arrow, fruit flies like a Banana.
http://news.motzarella.org
Re: INND NNTP-Posting-Host
#80811
Author: gabrix
Date: Wed, 29 Apr 2009 19:52
5 lines
1455 bytes
> Apr 29 21:48:03 news innd: SERVER perl filtering enabled
> Apr 29 21:48:03 news innd: SERVER starting

The link i did for cleanfeed pointing to filter_innd.pl was .....
 ... no words to describe the oddness ... i fixed it ! :)
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads