Thread View: news.software.nntp
6 messages
6 total messages
Started by David Jonsson
Wed, 25 Sep 1996 00:00
news-proxy
Author: David Jonsson
Date: Wed, 25 Sep 1996 00:00
Date: Wed, 25 Sep 1996 00:00
20 lines
1109 bytes
1109 bytes
Hello
I have a central server called origo that has news access to a remote
NNTP-server. I want all the workstations on the lan to have origo as their
NNTP-server. Origo is just going to forward each call to the remote
NNTP-server and deliver the result back to the workstation.
Do you know any software that does this job? It can be called a
news-proxyserver.
David
--
David Jonsson Phone +46-18-24 51 52 Fax +46-8-681 20 66
GSM +46-706-339487 E-mail david@bahnhof.se
Uppsala, Sweden Web: http://bahnhof.se/~david Postgiro 499 40 54-7
Re: news-proxy
Author: Harrie Overdijk
Date: Thu, 26 Sep 1996 00:00
Date: Thu, 26 Sep 1996 00:00
26 lines
1583 bytes
1583 bytes
Hello David,
In article <52bgp9$r8e@funny.bahnhof.se>, david@sunny.bahnhof.se says...
>I have a central server called origo that has news access to a remote
>NNTP-server. I want all the workstations on the lan to have origo as their
>NNTP-server. Origo is just going to forward each call to the remote
>NNTP-server and deliver the result back to the workstation.
>
>Do you know any software that does this job? It can be called a
>news-proxyserver.
What you need is a firewall application that 'plugs' the newsreaders
to another server. I'm doing that right now, writing this letter.
You could have a look at the firewall toolkit (fwtk) from TIS (Trusted
Information Systems). You can find it at the following address:
ftp://ftp.tis.com/pub/firewalls/toolkit/
Please read the README file for information how to obtain the toolkit.
You can use the plug-gw application for your purpose.
Greetings,
Harrie Overdijk.
Re: news-proxy
Author: Hugo Voerman
Date: Thu, 26 Sep 1996 00:00
Date: Thu, 26 Sep 1996 00:00
24 lines
1284 bytes
1284 bytes
In article <52bgp9$r8e@funny.bahnhof.se>, david@sunny.bahnhof.se says... > > >Hello > >I have a central server called origo that has news access to a remote >NNTP-server. I want all the workstations on the lan to have origo as their >NNTP-server. Origo is just going to forward each call to the remote >NNTP-server and deliver the result back to the workstation. > >Do you know any software that does this job? It can be called a >news-proxyserver. Take a look at nntp-cache or dnews. dnews can do the proxying (with caching) but can also run as a full-featured news server. nntp-cache is what the name says... Hope this helps. Best regards, Hugo
Re: news-proxy
Author: Hans Morten Kind
Date: Thu, 26 Sep 1996 00:00
Date: Thu, 26 Sep 1996 00:00
17 lines
1097 bytes
1097 bytes
In article <52bgp9$r8e@funny.bahnhof.se>, David Jonsson wrote: >Do you know any software that does this job? It can be called a >news-proxyserver. Well, I dont know about any �news-proxyserver�, but you could use ssh to tunnel all trafic from port 119 on the �proxy� to port 119 on the real newsserver. As a matter of fact, ssh can do all sorts of nice and funny stuff. Read about ssh at <URL:http://www.cs.hut.fi/ssh/> hmk
Re: news-proxy
Author: Scott Barker
Date: Thu, 26 Sep 1996 00:00
Date: Thu, 26 Sep 1996 00:00
219 lines
5638 bytes
5638 bytes
David Jonsson (david@sunny.bahnhof.se) wrote:
> Do you know any software that does this job? It can be called a
> news-proxyserver.
Use the following code, and invoke it from inetd on your news port (this is
taken from the INN rcompress sources):
/* $Revision: 1.7 $
**
** TCP forwarder. Connect to a server on a host. Send our stdin to the
** server, and send server's output down our stdout. Low-cost version
** of rsh. Can also be spawned out of inetd, e.g., to do forwarding.
** Descended from code written by Jim Thompson <Jim.Thompson@central.sun.com>.
** For example, when doing an "rcompress", add this to /etc/services:
** compress 2001/tcp
** and add this to /etc/inetd.conf on the server:
** compress stream tcp nowait root /usr/ucb/compress in.compressd -c
*/
#include <stdio.h>
#include <ctype.h>
#include <netdb.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#define BUFFER_SIZE 8192
#define DEFAULT_HOST "my.newsserver.com"
#define DEFAULT_SERVICE "nntp"
#define DEFAULT_INETLOSS 1
extern int optind;
extern char *optarg;
extern char *malloc();
extern char *memcpy();
extern char *memset();
extern unsigned long inet_addr();
extern struct servent *getservbyname();
extern struct hostent *gethostbyname();
extern void exit();
extern void perror();
/*
** Open a socket to the specified service.
*/
int
OpenConnection(host, service)
char *host;
char *service;
{
char **ap;
char *fakelist[2];
register int i;
struct servent *sp;
struct hostent *hp;
struct hostent fakehp;
struct in_addr quadaddr;
struct sockaddr_in server;
if ((sp = getservbyname(service, "tcp")) == NULL) {
perror("Unknown service");
return -1;
}
/* Get the host's address. */
quadaddr.s_addr = inet_addr(host);
if (quadaddr.s_addr != (unsigned long)-1) {
/* Host was specified as a dotted-quad internet address. Fill in
* the parts of the hostent struct that we need. */
fakehp.h_length = sizeof quadaddr;
fakehp.h_addrtype = AF_INET;
hp = &fakehp;
fakelist[0] = (char *)&quadaddr;
fakelist[1] = NULL;
ap = fakelist;
}
else if ((hp = gethostbyname(host)) != NULL) {
/* Symbolic host name. */
#if defined(h_addr)
ap = hp->h_addr_list;
#else
/* Fake up an address list for old systems. */
fakelist[0] = (char *)hp->h_addr;
fakelist[1] = NULL;
ap = fakelist;
#endif /* defined(h_addr) */
}
else {
perror("Unknown host");
return -1;
}
/* Set up the socket address. */
(void)memset((char *)&server, 0, sizeof server);
server.sin_family = hp->h_addrtype;
server.sin_port = sp->s_port;
/* Loop through the address list, trying to connect. */
for (; ap && *ap; ap++) {
/* Make a socket and try to connect. */
if ((i = socket(hp->h_addrtype, SOCK_STREAM, 0)) < 0)
break;
(void)memcpy((char *)&server.sin_addr, (char *)*ap, (int)hp->h_length);
if (connect(i, (struct sockaddr *)&server, sizeof server) == 0)
return i;
(void)close(i);
}
perror("Can't connect");
return -1;
}
/*
** Loop until the entire buffer is written.
*/
int
xwrite(fd, p, i)
register int fd;
register char *p;
register int i;
{
register int count;
for ( ; i > 0; p += count, i -= count)
if ((count = write(fd, p, i)) < 0)
return -1;
return 0;
}
int
main(ac, av)
int ac;
char *av[];
{
static char USAGE[] = "Usage error\n";
int s;
int inetdloss;
register int i;
char *host;
char *service;
char *p;
/* Set defaults. */
host = DEFAULT_HOST;
service = DEFAULT_SERVICE;
inetdloss = DEFAULT_INETLOSS;
/* Parse JCL. */
while ((i = getopt(ac, av, "h:is:")) != EOF)
switch (i) {
default:
(void)write(1, USAGE, sizeof USAGE - 1);
exit(1);
case 'h':
host = optarg;
break;
case 'i':
inetdloss = 1;
break;
case 's':
service = optarg;
break;
}
ac -= optind;
if (ac) {
(void)write(1, USAGE, sizeof USAGE - 1);
exit(1);
}
if (inetdloss) {
/* Work around broken inetd's. */
(void)close(1);
(void)dup(0);
}
/* Get a connection. */
if ((s = OpenConnection(host, service)) < 0)
exit(1);
/* Get a buffer. */
if ((p = malloc(BUFFER_SIZE)) == NULL) {
perror("can't allocate buffer");
exit(1);
}
switch (fork()) {
case -1:
perror("Can't fork");
exit(1);
case 0:
/* Child -- send server output to our stdout. */
while ((i = read(s, p, BUFFER_SIZE)) > 0)
if (xwrite(1, p, i) < 0) {
perror("Can't write to client");
break;
}
break;
default:
/* Parent -- send our stdin to server. */
while ((i = read(0, p, BUFFER_SIZE)) > 0)
if (xwrite(s, p, i) < 0) {
perror("Can't write to server");
break;
}
(void)shutdown(s, 1);
break;
}
exit(0);
/* NOTREACHED */
}
Re: news-proxy
Author: Frank Smith
Date: Fri, 27 Sep 1996 00:00
Date: Fri, 27 Sep 1996 00:00
31 lines
1885 bytes
1885 bytes
In article <52bgp9$r8e@funny.bahnhof.se>, David Jonsson <david@sunny.bahnhof.se> wrote: > >I have a central server called origo that has news access to a remote >NNTP-server. I want all the workstations on the lan to have origo as their >NNTP-server. Origo is just going to forward each call to the remote >NNTP-server and deliver the result back to the workstation. > >Do you know any software that does this job? It can be called a >news-proxyserver. > There is a package called dnntpd that proxies and can also merge more than one remote server into a single local port. I believe it is free, Also, nntpcache does the same thing but can also be configured to locally cache active files, headers, and articles. This can vastly speed up local access if you have a slow link (or a slow remote server). This may still be free beta, but their plan is to charge based on the number of users. There are probably others as well. frank -- Frank Smith -- System Administrator E-mail: fsmith@spec.com Systems & Processes Engineering Corp. (SPEC) Voice:(512) 306-1100 x154 401 Camp Craft Road Fax: (512) 306-1122 Austin, TX 78746-6558 Web: http://www.spec.com
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