Mailing List Archive

Support open source code!


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

tlug: qpopper vs. tcpd



>>>>> "Dave" == Dave Gutteridge <dave@example.com> writes:

    Dave> If i look in the inetd.conf file for information on my POP
    Dave> server, it tells me that something called "tcpd" is handling
    Dave> it.

tcpd is a wrapper program.  First it does some stuff, then it passes
its resources to some other program, and closes up shop itself,
leaving the other program to do its business.

You know how shell redirection works, right?  For example, `cat' is a
program that takes "standard input" and writes it to "standard output" 
when no files are available.

Type "cat" (just "cat") to your command prompt.  Then type something
followed by a <RETURN>.  Repeat until bored, and type Ctrl-D (means
end-of-file in Unix).  Back to prompt.

Now if you use "cat >file" instead, it won't echo to your screen;
instead it will echo to "file".  Go ahead, try it; then type "cat
file" to see what's in "file".  The shell, which normally handles both
key input and screen output, has redirected screen output away from
the screen and into "file".  And "cat <file1 >file2" has the same
effect as "cp file1 file2".  You knew all that, right?

OK, tcpd does the same thing, but with internet connections.  That's
all you need to know.  "tcpd prog args..." works just like "sh prog
args..." except that the resources that tcpd manages are TCP sockets,
and the resources that [ba]sh manages are file descriptors.

Why do this?  Well, actually, before handing off the internet
connection to qpopper or whatever, it can check the source address and
some other stuff (lots of stuff, actually) and deny access.  (Just
like the shell can set environment variables, search the path for
prog, etc.)  So if you know that you're only going to use POP3 from a
few IP addresses, or some specific domain, you can use tcpd to enforce
those restrictions for you.

see man tcpd, man hosts.allow for more details.

-- 
University of Tsukuba                Tennodai 1-1-1 Tsukuba 305-8573 JAPAN
Institute of Policy and Planning Sciences       Tel/fax: +81 (298) 53-5091
__________________________________________________________________________
__________________________________________________________________________
What are those two straight lines for?  "Free software rules."
----------------------------------------------------------------
Next Technical Meeting: 12 December, 12:30 HSBC Securities Office
Next Nomikai: 15 January 1999, 19:30 Tengu TokyoEkiMae 03-3275-3691
----------------------------------------------------------------
more info: http://tlug.linux.or.jp Sponsors: PHT, HSBC Securities


Home | Main Index | Thread Index

Home Page Mailing List Linux and Japan TLUG Members Links