PF Firewall Open FTP Port 21 (PASSIVE Configuration)

Posted on in Categories , , , , , , last updated November 3, 2008

Question: I’ve vsftpd ftp server configured under FreeBSD 7.x and PF firewall. Both PF and FTP server running on a dedicated FreeBSD web server. How do I configure PASSIVE FTP PF firewall configuration so that my vsftpd work? How do I configure PF firewall to protect an FTP server and open port 21?

FTP site at osuosl to download Linux ISO / Software

Posted on in Categories , last updated July 9, 2007

Q. Can you give me FTP site address at osuosl, so that I can download Linux ISO and other software?

A. The Open Source Lab (osuosl) facilitates open source communities and the development and distribution of Open Source Software (OSS). They provide hosting projects and developing software via their web site. The Open Source Lab is a group at Oregon State University dedicated to supporting and developing Open Source software. A wide range of projects are hosted at the lab including Gentoo, Mozilla, Debian, Freenode etc.

osuosl FTP site

Visit ftp site to download Ubuntu, Apache, Slackware, Gentoo, and other OSS software.

Star / Stop FTP server on FreeBSD / OpenBSD

Posted on in Categories , , , last updated June 18, 2007

Q. How do I stop / start default FTP server on FreeBSD or OpenBSD UNIX system?

A. ftpd is the Internet File Transfer Protocol server under BSD and configured via inetd. The ftpd utility is the Internet File Transfer Protocol server process. The server uses the TCP protocol and listens at the port specified or by default at port 21.

The inetd server should be run at boot time by /etc/rc. It then listens for connections on certain internet sockets. When a connection is found on one of its sockets, it decides what service the socket corresponds to, and invokes a program to service the request. The server program is invoked with the service socket as its standard input, output and error descriptors. After the program is finished, inetd continues to listen on the socket.

Task: Disable FTPD

Login as root user.

To disable ftpd open /etc/inetd.conf file:
# vi /etc/inetd.conf

Find line:
ftp stream tcp nowait root /usr/libexec/ftpd ftpd -l

To disable a service, comment it out by prefixing the line with ‘#’.
#ftp stream tcp nowait root /usr/libexec/ftpd ftpd -l

Save and close the file.

Task: Restart inetd

Now just restart inetd, enter:
# /etc/rc.d/inetd restart
OR if you are using OpenBSD:
# kill -HUP `cat /var/run/inetd.pid`

To enable ftp, reverse the step # 1.