castaglia / proftpd-mod_autohost Goto Github PK
View Code? Open in Web Editor NEWProFTPD module supporting large numbers of vhosts
ProFTPD module supporting large numbers of vhosts
The mod_autohost
module should support IPv6 addresses, at least for the %0
and %p
variables.
This is using 1.3.7a, but as far as I can tell the issue existed in previous versions.
1: Do a simple configure setup:
./configure --enable-ipv6 --enable-openssl --with-libraries=/usr/lib64/mysql:/usr/include/openssl --with-includes=contrib/:/usr/include/openssl --prefix=/usr --sysconfdir=/etc --disable-ident --disable-sendfile
2: Make and start with proftpd -nd9
3: Using separate shell, kill -HUP `cat /var/run/proftpd/proftpd.pid`
4: Debug output
2021-06-18 09:04:31,089 c7 proftpd[14708] 192.168.100.120: received SIGHUP -- master server reparsing configuration file
2021-06-18 09:04:31,089 c7 proftpd[14708] 192.168.100.120: scrubbing scoreboard
2021-06-18 09:04:31,089 c7 proftpd[14708] 192.168.100.120: ROOT PRIVS at scoreboard.c:1433
2021-06-18 09:04:31,089 c7 proftpd[14708] 192.168.100.120: RELINQUISH PRIVS at scoreboard.c:1436
2021-06-18 09:04:31,089 c7 proftpd[14708] 192.168.100.120: ROOT PRIVS at scoreboard.c:1477
2021-06-18 09:04:31,089 c7 proftpd[14708] 192.168.100.120: RELINQUISH PRIVS at scoreboard.c:1586
2021-06-18 09:04:31,089 c7 proftpd[14708] 192.168.100.120: finished scrubbing scoreboard
2021-06-18 09:04:31,089 c7 proftpd[14708]: using TCP receive buffer size of 87380 bytes
2021-06-18 09:04:31,089 c7 proftpd[14708]: using TCP send buffer size of 16384 bytes
2021-06-18 09:04:31,089 c7 proftpd[14708]: ROOT PRIVS at main.c:1015
2021-06-18 09:04:31,089 c7 proftpd[14708]: disabling runtime support for IPv6 connections
2021-06-18 09:04:31,089 c7 proftpd[14708]: ROOT PRIVS at mod_core.c:377
2021-06-18 09:04:31,089 c7 proftpd[14708]: RELINQUISH PRIVS at mod_core.c:379
2021-06-18 09:04:31,089 c7 proftpd[14708]: ROOT PRIVS at mod_core.c:386
2021-06-18 09:04:31,089 c7 proftpd[14708]: ROOT PRIVS at parser.c:1186
2021-06-18 09:04:31,089 c7 proftpd[14708]: ROOT PRIVS at mod_core.c:377
2021-06-18 09:04:31,089 c7 proftpd[14708]: RELINQUISH PRIVS at mod_core.c:379
2021-06-18 09:04:31,089 c7 proftpd[14708]: ROOT PRIVS at mod_core.c:386
2021-06-18 09:04:31,089 c7 proftpd[14708]: ROOT PRIVS at parser.c:1186
2021-06-18 09:04:31,089 c7 proftpd[14708]: ROOT PRIVS at trace.c:377
2021-06-18 09:04:31,089 c7 proftpd[14708]: RELINQUISH PRIVS at trace.c:380
2021-06-18 09:04:31,089 c7 proftpd[14708]: RELINQUISH PRIVS at parser.c:1189
2021-06-18 09:04:31,089 c7 proftpd[14708]: RELINQUISH PRIVS at mod_core.c:389
2021-06-18 09:04:31,089 c7 proftpd[14708]: RELINQUISH PRIVS at parser.c:1189
2021-06-18 09:04:31,089 c7 proftpd[14708]: RELINQUISH PRIVS at mod_core.c:389
2021-06-18 09:04:31,089 c7 proftpd[14708]: RELINQUISH PRIVS at main.c:1032
2021-06-18 09:04:31,090 c7 proftpd[14708] 192.168.100.120:
2021-06-18 09:04:31,090 c7 proftpd[14708] 192.168.100.120: Config for server:
2021-06-18 09:04:31,090 c7 proftpd[14708] 192.168.100.120: ServerIdent
2021-06-18 09:04:31,090 c7 proftpd[14708] 192.168.100.120: DefaultServer
2021-06-18 09:04:31,090 c7 proftpd[14708] 192.168.100.120: MultilineRFC2228
2021-06-18 09:04:31,090 c7 proftpd[14708] 192.168.100.120: UserID
2021-06-18 09:04:31,090 c7 proftpd[14708] 192.168.100.120: UserName
2021-06-18 09:04:31,090 c7 proftpd[14708] 192.168.100.120: GroupID
2021-06-18 09:04:31,090 c7 proftpd[14708] 192.168.100.120: GroupName
2021-06-18 09:04:31,090 c7 proftpd[14708] 192.168.100.120: LogFormat
2021-06-18 09:04:31,090 c7 proftpd[14708] 192.168.100.120: TransferLog
2021-06-18 09:04:31,090 c7 proftpd[14708] 192.168.100.120: ScoreboardScrub
2021-06-18 09:04:31,090 c7 proftpd[14708] 192.168.100.120: TimeoutLogin
2021-06-18 09:04:31,090 c7 proftpd[14708] 192.168.100.120: DelayEngine
2021-06-18 09:04:31,090 c7 proftpd[14708] 192.168.100.120: ROOT PRIVS at mod_rlimit.c:555
2021-06-18 09:04:31,090 c7 proftpd[14708] 192.168.100.120: RELINQUISH PRIVS at mod_rlimit.c:558
2021-06-18 09:04:31,090 c7 proftpd[14708] 192.168.100.120: set core resource limits for daemon
Now, add autohost into the mix
1: Do a configure setup with autohost:
./configure --enable-ipv6 --enable-openssl --with-libraries=/usr/lib64/mysql:/usr/include/openssl --with-modules=mod_autohost --with-includes=contrib/:/usr/include/openssl --prefix=/usr --sysconfdir=/etc --disable-ident --disable-sendfile
2: Make and start with proftpd -nd9
3: Using separate shell, kill -HUP `cat /var/run/proftpd/proftpd.pid`
4: Debug output
2021-06-18 09:19:27,869 c7 proftpd[32759] 192.168.100.120: received SIGHUP -- master server reparsing configuration file
2021-06-18 09:19:27,869 c7 proftpd[32759] 192.168.100.120: scrubbing scoreboard
2021-06-18 09:19:27,869 c7 proftpd[32759] 192.168.100.120: ROOT PRIVS at scoreboard.c:1433
2021-06-18 09:19:27,869 c7 proftpd[32759] 192.168.100.120: RELINQUISH PRIVS at scoreboard.c:1436
2021-06-18 09:19:27,869 c7 proftpd[32759] 192.168.100.120: ROOT PRIVS at scoreboard.c:1477
2021-06-18 09:19:27,869 c7 proftpd[32759] 192.168.100.120: RELINQUISH PRIVS at scoreboard.c:1586
2021-06-18 09:19:27,869 c7 proftpd[32759] 192.168.100.120: finished scrubbing scoreboard
2021-06-18 09:19:27,869 c7 proftpd[32759]: using TCP receive buffer size of 87380 bytes
2021-06-18 09:19:27,869 c7 proftpd[32759]: using TCP send buffer size of 16384 bytes
2021-06-18 09:19:27,869 c7 proftpd[32759]: ROOT PRIVS at main.c:1015
2021-06-18 09:19:27,869 c7 proftpd[32759]: disabling runtime support for IPv6 connections
2021-06-18 09:19:27,869 c7 proftpd[32759]: ROOT PRIVS at mod_core.c:377
2021-06-18 09:19:27,869 c7 proftpd[32759]: RELINQUISH PRIVS at mod_core.c:379
2021-06-18 09:19:27,869 c7 proftpd[32759]: ROOT PRIVS at mod_core.c:386
2021-06-18 09:19:27,869 c7 proftpd[32759]: ROOT PRIVS at parser.c:1186
2021-06-18 09:19:27,869 c7 proftpd[32759]: ROOT PRIVS at mod_core.c:377
2021-06-18 09:19:27,869 c7 proftpd[32759]: RELINQUISH PRIVS at mod_core.c:379
2021-06-18 09:19:27,869 c7 proftpd[32759]: ROOT PRIVS at mod_core.c:386
2021-06-18 09:19:27,869 c7 proftpd[32759]: ROOT PRIVS at parser.c:1186
2021-06-18 09:19:27,869 c7 proftpd[32759]: ROOT PRIVS at trace.c:377
2021-06-18 09:19:27,869 c7 proftpd[32759]: RELINQUISH PRIVS at trace.c:380
2021-06-18 09:19:27,869 c7 proftpd[32759]: RELINQUISH PRIVS at parser.c:1189
2021-06-18 09:19:27,869 c7 proftpd[32759]: RELINQUISH PRIVS at mod_core.c:389
2021-06-18 09:19:27,869 c7 proftpd[32759]: RELINQUISH PRIVS at parser.c:1189
2021-06-18 09:19:27,869 c7 proftpd[32759]: RELINQUISH PRIVS at mod_core.c:389
2021-06-18 09:19:27,869 c7 proftpd[32759]: RELINQUISH PRIVS at main.c:1032
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120:
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: Config for server:
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: ServerIdent
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: DefaultServer
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: MultilineRFC2228
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: UserID
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: UserName
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: GroupID
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: GroupName
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: LogFormat
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: TransferLog
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: AutoHostEngine
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: AutoHostLog
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: AutoHostPorts
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: AutoHostConfig
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: ScoreboardScrub
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: TimeoutLogin
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: DelayEngine
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: ROOT PRIVS at mod_autohost.c:509
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: RELINQUISH PRIVS at mod_autohost.c:511
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: ROOT PRIVS at inet.c:447
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: RELINQUISH PRIVS at inet.c:506
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: Failed binding to 0.0.0.0, port 21: Address already in use
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: Check the ServerType directive to ensure you are configured correctly
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: Check to see if inetd/xinetd, or another proftpd instance, is already using 0.0.0.0, port 21
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: ROOT PRIVS at inet.c:447
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: RELINQUISH PRIVS at inet.c:506
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: Failed binding to 0.0.0.0, port 22: Address already in use
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: Check the ServerType directive to ensure you are configured correctly
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: Check to see if inetd/xinetd, or another proftpd instance, is already using 0.0.0.0, port 22
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: ROOT PRIVS at inet.c:447
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: RELINQUISH PRIVS at inet.c:506
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: Failed binding to 0.0.0.0, port 991: Address already in use
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: Check the ServerType directive to ensure you are configured correctly
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: Check to see if inetd/xinetd, or another proftpd instance, is already using 0.0.0.0, port 991
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: ROOT PRIVS at inet.c:447
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: RELINQUISH PRIVS at inet.c:506
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: Failed binding to 0.0.0.0, port 990: Address already in use
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: Check the ServerType directive to ensure you are configured correctly
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: Check to see if inetd/xinetd, or another proftpd instance, is already using 0.0.0.0, port 990
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: ROOT PRIVS at mod_rlimit.c:555
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: RELINQUISH PRIVS at mod_rlimit.c:558
2021-06-18 09:19:27,870 c7 proftpd[32759] 192.168.100.120: set core resource limits for daemon
At this point the daemon does not respond to incoming connections and trace log just repeats until the daemon is killed.
2021-06-18 09:19:31,552 [32759] <signal:18>: interrupted system call, delaying for 0 secs, 200000 microsecs
2021-06-18 09:19:31,552 [32759] <signal:5>: signals blocked
2021-06-18 09:19:31,752 [32759] <signal:5>: signals unblocked
2021-06-18 09:19:31,752 [32759] <signal:9>: handling SIGALRM (signal 14)
2021-06-18 09:19:36,753 [32759] <signal:18>: interrupted system call, delaying for 0 secs, 200000 microsecs
2021-06-18 09:19:36,753 [32759] <signal:5>: signals blocked
2021-06-18 09:19:36,953 [32759] <signal:5>: signals unblocked
2021-06-18 09:19:36,953 [32759] <signal:9>: handling SIGALRM (signal 14)
Not sure if this is an issue with mod_autohost or with core.
The configuration works fine with 1.3.7a.
Everything looks OK with 1.3.7b, but it will not respond to any connection request. between netstat and lsof it looks like the ports are bound, but not listening (?).
What I've tried...
Changing DefaultServer to off causes 1.3.7a to fail as well.
Using 1.3.7b, with DefaultServer on, setting the Port directive to one of the AutohostPorts results in that single port working, with Autohost, but no answer on the other two ports. Using a single port number on AuthohostPorts makes no differnce.
Starting 1.3.7a, then starting 1.3.7b fails with "Failed binding to 0.0.0.0, port 21: Address already in use".
Starting 1.3.7b, then starting 1.3.7a actually works, with 1.3.7a handling the requests.
Relative configuration directives:
DefaultServer on
Port 0
AutoHostEngine on
AutohostPorts 21 22 990
Using proftpd 1.3.7a with a latest mod_autohost
./proftpd -l
Compiled-in modules:
mod_core.c
mod_xfer.c
mod_rlimit.c
mod_auth_unix.c
mod_auth_file.c
mod_auth.c
mod_ls.c
mod_log.c
mod_site.c
mod_delay.c
mod_facts.c
mod_autohost.c
./proftpd -nd9
2021-08-09 05:00:48,869 dev proftpd[9136]: using TCP receive buffer size of 87380 bytes
2021-08-09 05:00:48,869 dev proftpd[9136]: using TCP send buffer size of 16384 bytes
2021-08-09 05:00:48,870 dev proftpd[9136]: disabling runtime support for IPv6 connections
2021-08-09 05:00:48,870 dev proftpd[9136]: ROOT PRIVS at mod_core.c:377
2021-08-09 05:00:48,870 dev proftpd[9136]: RELINQUISH PRIVS at mod_core.c:379
2021-08-09 05:00:48,870 dev proftpd[9136]: ROOT PRIVS at mod_core.c:386
2021-08-09 05:00:48,870 dev proftpd[9136]: ROOT PRIVS at parser.c:1186
2021-08-09 05:00:48,870 dev proftpd[9136]: ROOT PRIVS at mod_core.c:377
2021-08-09 05:00:48,870 dev proftpd[9136]: RELINQUISH PRIVS at mod_core.c:379
2021-08-09 05:00:48,870 dev proftpd[9136]: ROOT PRIVS at mod_core.c:386
2021-08-09 05:00:48,870 dev proftpd[9136]: ROOT PRIVS at parser.c:1186
2021-08-09 05:00:48,870 dev proftpd[9136]: ROOT PRIVS at trace.c:377
2021-08-09 05:00:48,870 dev proftpd[9136]: RELINQUISH PRIVS at trace.c:380
2021-08-09 05:00:48,870 dev proftpd[9136]: RELINQUISH PRIVS at parser.c:1189
2021-08-09 05:00:48,870 dev proftpd[9136]: RELINQUISH PRIVS at mod_core.c:389
2021-08-09 05:00:48,870 dev proftpd[9136]: RELINQUISH PRIVS at parser.c:1189
2021-08-09 05:00:48,870 dev proftpd[9136]: RELINQUISH PRIVS at mod_core.c:389
2021-08-09 05:00:48,870 dev proftpd[9136] 192.168.100.120:
2021-08-09 05:00:48,870 dev proftpd[9136] 192.168.100.120: Config for ProFTPD:
2021-08-09 05:00:48,870 dev proftpd[9136] 192.168.100.120: DefaultServer
2021-08-09 05:00:48,870 dev proftpd[9136] 192.168.100.120: MultilineRFC2228
2021-08-09 05:00:48,870 dev proftpd[9136] 192.168.100.120: UserID
2021-08-09 05:00:48,870 dev proftpd[9136] 192.168.100.120: UserName
2021-08-09 05:00:48,870 dev proftpd[9136] 192.168.100.120: GroupID
2021-08-09 05:00:48,870 dev proftpd[9136] 192.168.100.120: GroupName
2021-08-09 05:00:48,870 dev proftpd[9136] 192.168.100.120: LogFormat
2021-08-09 05:00:48,870 dev proftpd[9136] 192.168.100.120: TransferLog
2021-08-09 05:00:48,870 dev proftpd[9136] 192.168.100.120: AutoHostEngine
2021-08-09 05:00:48,870 dev proftpd[9136] 192.168.100.120: AutoHostLog
2021-08-09 05:00:48,870 dev proftpd[9136] 192.168.100.120: AutoHostPorts
2021-08-09 05:00:48,870 dev proftpd[9136] 192.168.100.120: AutoHostConfig
2021-08-09 05:00:48,870 dev proftpd[9136] 192.168.100.120: ScoreboardScrub
2021-08-09 05:00:48,870 dev proftpd[9136] 192.168.100.120: TimeoutLogin
2021-08-09 05:00:48,870 dev proftpd[9136] 192.168.100.120: DelayEngine
2021-08-09 05:00:48,870 dev proftpd[9136] 192.168.100.120: ROOT PRIVS at mod_autohost.c:509
2021-08-09 05:00:48,870 dev proftpd[9136] 192.168.100.120: RELINQUISH PRIVS at mod_autohost.c:511
2021-08-09 05:00:48,870 dev proftpd[9136] 192.168.100.120: ROOT PRIVS at inet.c:447
2021-08-09 05:00:48,870 dev proftpd[9136] 192.168.100.120: RELINQUISH PRIVS at inet.c:530
2021-08-09 05:00:48,871 dev proftpd[9136] 192.168.100.120: ROOT PRIVS at inet.c:447
2021-08-09 05:00:48,871 dev proftpd[9136] 192.168.100.120: RELINQUISH PRIVS at inet.c:530
2021-08-09 05:00:48,871 dev proftpd[9136] 192.168.100.120: ROOT PRIVS at inet.c:447
2021-08-09 05:00:48,871 dev proftpd[9136] 192.168.100.120: RELINQUISH PRIVS at inet.c:530
2021-08-09 05:00:48,871 dev proftpd[9136] 192.168.100.120: ROOT PRIVS at mod_rlimit.c:555
2021-08-09 05:00:48,871 dev proftpd[9136] 192.168.100.120: RELINQUISH PRIVS at mod_rlimit.c:558
2021-08-09 05:00:48,871 dev proftpd[9136] 192.168.100.120: set core resource limits for daemon
2021-08-09 05:00:48,871 dev proftpd[9136] 192.168.100.120: ignoring supplemental groups for non-root UID 99
2021-08-09 05:00:48,871 dev proftpd[9136] 192.168.100.120: SETUP PRIVS at main.c:2614
2021-08-09 05:00:48,871 dev proftpd[9136] 192.168.100.120: ROOT PRIVS at main.c:1896
2021-08-09 05:00:48,871 dev proftpd[9136] 192.168.100.120: opening scoreboard '/run/proftpd/proftpd.score'
2021-08-09 05:00:48,871 dev proftpd[9136] 192.168.100.120: RELINQUISH PRIVS at main.c:1923
2021-08-09 05:00:48,871 dev proftpd[9136] 192.168.100.120: ProFTPD 1.3.7a (maint) (built Mon Aug 9 2021 05:00:13 EDT) standalone mode STARTUP
2021-08-09 05:00:48,871 dev proftpd[9136] 192.168.100.120: ROOT PRIVS at pidfile.c:56
2021-08-09 05:00:48,871 dev proftpd[9136] 192.168.100.120: RELINQUISH PRIVS at pidfile.c:59
2021-08-09 05:00:48,871 dev proftpd[9136] 192.168.100.120: ROOT PRIVS at pidfile.c:67
2021-08-09 05:00:48,871 dev proftpd[9136] 192.168.100.120: RELINQUISH PRIVS at pidfile.c:70
cat trace.log
2021-08-09 05:00:48,870 [9136] <fsio:8>: using system read() for path '/etc/proftpd.conf.d/tracelogging.conf' (4096 bytes)
2021-08-09 05:00:48,870 [9136] <fsio:8>: using system close() for path '/etc/proftpd.conf.d/tracelogging.conf'
2021-08-09 05:00:48,870 [9136] <privs:9>: user/root privs count = 0, ignoring PRIVS_RELINQUISH
2021-08-09 05:00:48,870 [9136] <privs:9>: user/root privs count = 0, ignoring PRIVS_RELINQUISH
2021-08-09 05:00:48,870 [9136] <fsio:8>: using system read() for path '/etc/proftpd.conf.d/server.conf' (4096 bytes)
2021-08-09 05:00:48,870 [9136] <fsio:8>: using system close() for path '/etc/proftpd.conf.d/server.conf'
2021-08-09 05:00:48,870 [9136] <privs:9>: user/root privs count = 0, ignoring PRIVS_RELINQUISH
2021-08-09 05:00:48,870 [9136] <privs:9>: user/root privs count = 0, ignoring PRIVS_RELINQUISH
2021-08-09 05:00:48,870 [9136] <fsio:8>: using system read() for path '/etc/proftpd.conf' (4096 bytes)
2021-08-09 05:00:48,870 [9136] <fsio:8>: using system close() for path '/etc/proftpd.conf'
2021-08-09 05:00:48,870 [9136] <dns:10>: resolving name 'dev' to IP address
2021-08-09 05:00:48,870 [9136] <dns:7>: attempting to resolve 'dev' to IPv4 address via DNS
2021-08-09 05:00:48,870 [9136] <dns:7>: resolved 'dev' to IPv4 address 192.168.100.120
2021-08-09 05:00:48,870 [9136] <dns:5>: stashed IP address '192.168.100.120' for name 'dev' in the netaddr IP cache
2021-08-09 05:00:48,870 [9136] <dns:5>: stashed IP address '192.168.100.120' for name '192.168.100.120' in the netaddr IP cache
2021-08-09 05:00:48,870 [9136] <dns:4>: using IP address '192.168.100.120' from netaddr IP cache for name '192.168.100.120'
2021-08-09 05:00:48,870 [9136] <event:8>: dispatching event 'core.postparse' to mod_autohost (at 0x48fe70, use cache = false)
2021-08-09 05:00:48,870 [9136] <event:3>: module 'autohost' (0x6d20c0) registering handler for event 'core.connect' (at 0x490920)
2021-08-09 05:00:48,870 [9136] <event:3>: module 'autohost' (0x6d20c0) registering handler for event 'mod_tls.sni' (at 0x4907f0)
2021-08-09 05:00:48,870 [9136] <privs:9>: root privs count = 0, honoring PRIVS_ROOT
2021-08-09 05:00:48,870 [9136] <signal:5>: signals blocked
2021-08-09 05:00:48,870 [9136] <signal:5>: signals unblocked
2021-08-09 05:00:48,870 [9136] <privs:9>: root privs count = 1, user privs count = 0, honoring PRIVS_RELINQUISH
2021-08-09 05:00:48,870 [9136] <signal:5>: signals blocked
2021-08-09 05:00:48,870 [9136] <signal:5>: signals unblocked
2021-08-09 05:00:48,870 [9136] <binding:8>: created IP binding for 192.168.100.120#21, server 0x915618
2021-08-09 05:00:48,870 [9136] <inet:17>: enabling SO_KEEPALIVE on socket fd 4
2021-08-09 05:00:48,870 [9136] <signal:5>: signals blocked
2021-08-09 05:00:48,870 [9136] <privs:9>: root privs count = 0, honoring PRIVS_ROOT
2021-08-09 05:00:48,870 [9136] <signal:9>: signals already blocked (block count = 1)
2021-08-09 05:00:48,870 [9136] <signal:9>: signals already unblocked (block count = 2)
2021-08-09 05:00:48,870 [9136] <privs:9>: root privs count = 1, user privs count = 0, honoring PRIVS_RELINQUISH
2021-08-09 05:00:48,870 [9136] <signal:9>: signals already blocked (block count = 1)
2021-08-09 05:00:48,870 [9136] <signal:9>: signals already unblocked (block count = 2)
2021-08-09 05:00:48,871 [9136] <signal:5>: signals unblocked
2021-08-09 05:00:48,871 [9136] <binding:4>: bound address 0.0.0.0, port 21 to socket fd 4
2021-08-09 05:00:48,871 [9136] <binding:8>: created IP binding for 192.168.100.120#22, server 0x915618
2021-08-09 05:00:48,871 [9136] <inet:17>: enabling SO_KEEPALIVE on socket fd 5
2021-08-09 05:00:48,871 [9136] <signal:5>: signals blocked
2021-08-09 05:00:48,871 [9136] <privs:9>: root privs count = 0, honoring PRIVS_ROOT
2021-08-09 05:00:48,871 [9136] <signal:9>: signals already blocked (block count = 1)
2021-08-09 05:00:48,871 [9136] <signal:9>: signals already unblocked (block count = 2)
2021-08-09 05:00:48,871 [9136] <privs:9>: root privs count = 1, user privs count = 0, honoring PRIVS_RELINQUISH
2021-08-09 05:00:48,871 [9136] <signal:9>: signals already blocked (block count = 1)
2021-08-09 05:00:48,871 [9136] <signal:9>: signals already unblocked (block count = 2)
2021-08-09 05:00:48,871 [9136] <signal:5>: signals unblocked
2021-08-09 05:00:48,871 [9136] <binding:4>: bound address 0.0.0.0, port 22 to socket fd 5
2021-08-09 05:00:48,871 [9136] <binding:8>: created IP binding for 192.168.100.120#990, server 0x915618
2021-08-09 05:00:48,871 [9136] <inet:17>: enabling SO_KEEPALIVE on socket fd 7
2021-08-09 05:00:48,871 [9136] <signal:5>: signals blocked
2021-08-09 05:00:48,871 [9136] <privs:9>: root privs count = 0, honoring PRIVS_ROOT
2021-08-09 05:00:48,871 [9136] <signal:9>: signals already blocked (block count = 1)
2021-08-09 05:00:48,871 [9136] <signal:9>: signals already unblocked (block count = 2)
2021-08-09 05:00:48,871 [9136] <privs:9>: root privs count = 1, user privs count = 0, honoring PRIVS_RELINQUISH
2021-08-09 05:00:48,871 [9136] <signal:9>: signals already blocked (block count = 1)
2021-08-09 05:00:48,871 [9136] <signal:9>: signals already unblocked (block count = 2)
2021-08-09 05:00:48,871 [9136] <signal:5>: signals unblocked
2021-08-09 05:00:48,871 [9136] <binding:4>: bound address 0.0.0.0, port 990 to socket fd 7
2021-08-09 05:00:48,871 [9136] <event:8>: dispatching event 'core.postparse' to mod_delay (at 0x48a9f0, use cache = false)
2021-08-09 05:00:48,871 [9136] <event:8>: dispatching event 'core.postparse' to mod_log (at 0x486a80, use cache = false)
2021-08-09 05:00:48,871 [9136] <event:8>: dispatching event 'core.postparse' to mod_rlimit (at 0x473910, use cache = false)
2021-08-09 05:00:48,871 [9136] <privs:9>: root privs count = 0, honoring PRIVS_ROOT
2021-08-09 05:00:48,871 [9136] <signal:5>: signals blocked
2021-08-09 05:00:48,871 [9136] <signal:5>: signals unblocked
2021-08-09 05:00:48,871 [9136] <privs:9>: root privs count = 1, user privs count = 0, honoring PRIVS_RELINQUISH
2021-08-09 05:00:48,871 [9136] <signal:5>: signals blocked
2021-08-09 05:00:48,871 [9136] <signal:5>: signals unblocked
2021-08-09 05:00:48,871 [9136] <privs:9>: PRIVS_SETUP called, resetting user/root privs count
2021-08-09 05:00:48,871 [9136] <signal:5>: signals blocked
2021-08-09 05:00:48,871 [9136] <signal:5>: signals unblocked
2021-08-09 05:00:48,871 [9136] <privs:9>: root privs count = 0, honoring PRIVS_ROOT
2021-08-09 05:00:48,871 [9136] <signal:5>: signals blocked
2021-08-09 05:00:48,871 [9136] <signal:5>: signals unblocked
2021-08-09 05:00:48,871 [9136] <scoreboard:7>: reading scoreboard header
2021-08-09 05:00:48,871 [9136] <lock:9>: attempt #1 to write-lock scoreboard mutex fd 9
2021-08-09 05:00:48,871 [9136] <lock:9>: write-lock of scoreboard mutex fd 9 successful after 1 attempt
2021-08-09 05:00:48,871 [9136] <scoreboard:7>: writing scoreboard header
2021-08-09 05:00:48,871 [9136] <lock:9>: attempt #1 to unlock-lock scoreboard mutex fd 9
2021-08-09 05:00:48,871 [9136] <lock:9>: unlock-lock of scoreboard mutex fd 9 successful after 1 attempt
2021-08-09 05:00:48,871 [9136] <privs:9>: root privs count = 1, user privs count = 0, honoring PRIVS_RELINQUISH
2021-08-09 05:00:48,871 [9136] <signal:5>: signals blocked
2021-08-09 05:00:48,871 [9136] <signal:5>: signals unblocked
2021-08-09 05:00:48,871 [9136] <scoreboard:4>: closing scoreboard fd 8
2021-08-09 05:00:48,871 [9136] <event:8>: dispatching event 'core.startup' to mod_core (at 0x467c70, use cache = false)
2021-08-09 05:00:48,871 [9136] <timer:7>: added timer ID 1024 ('scoreboard scrubbing', for module 'core'), triggering in 7200 seconds
2021-08-09 05:00:48,871 [9136] <binding:8>: created IP binding for 192.168.100.120#0, server 0x915618
2021-08-09 05:00:48,871 [9136] <privs:9>: root privs count = 0, honoring PRIVS_ROOT
2021-08-09 05:00:48,871 [9136] <signal:5>: signals blocked
2021-08-09 05:00:48,871 [9136] <signal:5>: signals unblocked
2021-08-09 05:00:48,871 [9136] <privs:9>: root privs count = 1, user privs count = 0, honoring PRIVS_RELINQUISH
2021-08-09 05:00:48,871 [9136] <signal:5>: signals blocked
2021-08-09 05:00:48,871 [9136] <signal:5>: signals unblocked
2021-08-09 05:00:48,871 [9136] <privs:9>: root privs count = 0, honoring PRIVS_ROOT
2021-08-09 05:00:48,871 [9136] <signal:5>: signals blocked
2021-08-09 05:00:48,871 [9136] <signal:5>: signals unblocked
2021-08-09 05:00:48,871 [9136] <privs:9>: root privs count = 1, user privs count = 0, honoring PRIVS_RELINQUISH
2021-08-09 05:00:48,871 [9136] <signal:5>: signals blocked
2021-08-09 05:00:48,871 [9136] <signal:5>: signals unblocked
netstat -tulpn | grep LISTEN | grep proftpd
tcp 0 0 0.0.0.0:990 0.0.0.0:* LISTEN 9136/proftpd: (acce
tcp 0 0 0.0.0.0:21 0.0.0.0:* LISTEN 9136/proftpd: (acce
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 9136/proftpd: (acce
lsof | grep proftpd | grep 0t0
proftpd 9136 nobody 2u CHR 136,2 0t0 5 /dev/pts/2
proftpd 9136 nobody 4u IPv4 1699038 0t0 TCP *:ftp (LISTEN)
proftpd 9136 nobody 5u IPv4 1699039 0t0 TCP *:ssh (LISTEN)
proftpd 9136 nobody 7u IPv4 1699040 0t0 TCP *:ftps (LISTEN)
Using proftpd 1.3.7b with a latest mod_autohost
./proftpd -l
Compiled-in modules:
mod_core.c
mod_xfer.c
mod_rlimit.c
mod_auth_unix.c
mod_auth_file.c
mod_auth.c
mod_ls.c
mod_log.c
mod_site.c
mod_delay.c
mod_facts.c
mod_autohost.c
./proftpd -nd9
2021-08-09 07:28:32,118 dev proftpd[20665]: using TCP receive buffer size of 87380 bytes
2021-08-09 07:28:32,118 dev proftpd[20665]: using TCP send buffer size of 16384 bytes
2021-08-09 07:28:32,118 dev proftpd[20665]: disabling runtime support for IPv6 connections
2021-08-09 07:28:32,118 dev proftpd[20665]: ROOT PRIVS at mod_core.c:377
2021-08-09 07:28:32,118 dev proftpd[20665]: RELINQUISH PRIVS at mod_core.c:379
2021-08-09 07:28:32,118 dev proftpd[20665]: ROOT PRIVS at mod_core.c:386
2021-08-09 07:28:32,119 dev proftpd[20665]: ROOT PRIVS at parser.c:1186
2021-08-09 07:28:32,119 dev proftpd[20665]: ROOT PRIVS at mod_core.c:377
2021-08-09 07:28:32,119 dev proftpd[20665]: RELINQUISH PRIVS at mod_core.c:379
2021-08-09 07:28:32,119 dev proftpd[20665]: ROOT PRIVS at mod_core.c:386
2021-08-09 07:28:32,119 dev proftpd[20665]: ROOT PRIVS at parser.c:1186
2021-08-09 07:28:32,119 dev proftpd[20665]: ROOT PRIVS at trace.c:377
2021-08-09 07:28:32,119 dev proftpd[20665]: RELINQUISH PRIVS at trace.c:380
2021-08-09 07:28:32,119 dev proftpd[20665]: RELINQUISH PRIVS at parser.c:1189
2021-08-09 07:28:32,119 dev proftpd[20665]: RELINQUISH PRIVS at mod_core.c:389
2021-08-09 07:28:32,119 dev proftpd[20665]: RELINQUISH PRIVS at parser.c:1189
2021-08-09 07:28:32,119 dev proftpd[20665]: RELINQUISH PRIVS at mod_core.c:389
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120:
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: Config for ProFTPD:
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: DefaultServer
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: MultilineRFC2228
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: UserID
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: UserName
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: GroupID
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: GroupName
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: LogFormat
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: TransferLog
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: AutoHostEngine
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: AutoHostLog
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: AutoHostPorts
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: AutoHostConfig
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: ScoreboardScrub
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: TimeoutLogin
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: DelayEngine
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: ROOT PRIVS at mod_autohost.c:527
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: RELINQUISH PRIVS at mod_autohost.c:529
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: ROOT PRIVS at inet.c:432
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: RELINQUISH PRIVS at inet.c:515
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: ROOT PRIVS at inet.c:432
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: RELINQUISH PRIVS at inet.c:515
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: ROOT PRIVS at inet.c:432
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: RELINQUISH PRIVS at inet.c:515
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: ROOT PRIVS at mod_rlimit.c:555
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: RELINQUISH PRIVS at mod_rlimit.c:558
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: set core resource limits for daemon
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: ignoring supplemental groups for non-root UID 99
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: SETUP PRIVS at main.c:2619
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: ROOT PRIVS at main.c:1897
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: opening scoreboard '/run/proftpd/proftpd.score'
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: RELINQUISH PRIVS at main.c:1924
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: ProFTPD 1.3.7b (git) (built Mon Aug 9 2021 05:31:31 EDT) standalone mode STARTUP
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: ROOT PRIVS at pidfile.c:56
2021-08-09 07:28:32,119 dev proftpd[20665] 192.168.100.120: RELINQUISH PRIVS at pidfile.c:59
2021-08-09 07:28:32,120 dev proftpd[20665] 192.168.100.120: ROOT PRIVS at pidfile.c:67
2021-08-09 07:28:32,120 dev proftpd[20665] 192.168.100.120: RELINQUISH PRIVS at pidfile.c:70
cat trace.log
2021-08-09 07:28:32,119 [20665] <fsio:8>: using system read() for path '/etc/proftpd.conf.d/tracelogging.conf' (4096 bytes)
2021-08-09 07:28:32,119 [20665] <fsio:8>: using system close() for path '/etc/proftpd.conf.d/tracelogging.conf'
2021-08-09 07:28:32,119 [20665] <privs:9>: user/root privs count = 0, ignoring PRIVS_RELINQUISH
2021-08-09 07:28:32,119 [20665] <privs:9>: user/root privs count = 0, ignoring PRIVS_RELINQUISH
2021-08-09 07:28:32,119 [20665] <fsio:8>: using system read() for path '/etc/proftpd.conf.d/server.conf' (4096 bytes)
2021-08-09 07:28:32,119 [20665] <fsio:8>: using system close() for path '/etc/proftpd.conf.d/server.conf'
2021-08-09 07:28:32,119 [20665] <privs:9>: user/root privs count = 0, ignoring PRIVS_RELINQUISH
2021-08-09 07:28:32,119 [20665] <privs:9>: user/root privs count = 0, ignoring PRIVS_RELINQUISH
2021-08-09 07:28:32,119 [20665] <fsio:8>: using system read() for path '/etc/proftpd.conf' (4096 bytes)
2021-08-09 07:28:32,119 [20665] <fsio:8>: using system close() for path '/etc/proftpd.conf'
2021-08-09 07:28:32,119 [20665] <dns:10>: resolving name 'dev' to IP address
2021-08-09 07:28:32,119 [20665] <dns:7>: attempting to resolve 'dev' to IPv4 address via DNS
2021-08-09 07:28:32,119 [20665] <dns:7>: resolved 'dev' to IPv4 address 192.168.100.120
2021-08-09 07:28:32,119 [20665] <dns:5>: stashed IP address '192.168.100.120' for name 'dev' in the netaddr IP cache
2021-08-09 07:28:32,119 [20665] <dns:5>: stashed IP address '192.168.100.120' for name '192.168.100.120' in the netaddr IP cache
2021-08-09 07:28:32,119 [20665] <dns:4>: using IP address '192.168.100.120' from netaddr IP cache for name '192.168.100.120'
2021-08-09 07:28:32,119 [20665] <event:8>: dispatching event 'core.postparse' to mod_autohost (at 0x490b50, use cache = false)
2021-08-09 07:28:32,119 [20665] <event:3>: module 'autohost' (0x6d30a0) registering handler for event 'core.connect' (at 0x491660)
2021-08-09 07:28:32,119 [20665] <event:3>: module 'autohost' (0x6d30a0) registering handler for event 'mod_tls.sni' (at 0x491530)
2021-08-09 07:28:32,119 [20665] <privs:9>: root privs count = 0, honoring PRIVS_ROOT
2021-08-09 07:28:32,119 [20665] <signal:5>: signals blocked
2021-08-09 07:28:32,119 [20665] <signal:5>: signals unblocked
2021-08-09 07:28:32,119 [20665] <privs:9>: root privs count = 1, user privs count = 0, honoring PRIVS_RELINQUISH
2021-08-09 07:28:32,119 [20665] <signal:5>: signals blocked
2021-08-09 07:28:32,119 [20665] <signal:5>: signals unblocked
2021-08-09 07:28:32,119 [20665] <binding:8>: created ipbind 0xa0fda8 for 192.168.100.120#21, server 0x9f7618
2021-08-09 07:28:32,119 [20665] <inet:17>: enabling SO_KEEPALIVE on socket fd 4
2021-08-09 07:28:32,119 [20665] <signal:5>: signals blocked
2021-08-09 07:28:32,119 [20665] <privs:9>: root privs count = 0, honoring PRIVS_ROOT
2021-08-09 07:28:32,119 [20665] <signal:9>: signals already blocked (block count = 1)
2021-08-09 07:28:32,119 [20665] <signal:9>: signals already unblocked (block count = 2)
2021-08-09 07:28:32,119 [20665] <privs:9>: root privs count = 1, user privs count = 0, honoring PRIVS_RELINQUISH
2021-08-09 07:28:32,119 [20665] <signal:9>: signals already blocked (block count = 1)
2021-08-09 07:28:32,119 [20665] <signal:9>: signals already unblocked (block count = 2)
2021-08-09 07:28:32,119 [20665] <signal:5>: signals unblocked
2021-08-09 07:28:32,119 [20665] <binding:4>: bound address 0.0.0.0, port 21 to socket fd 4
2021-08-09 07:28:32,119 [20665] <binding:8>: created ipbind 0xa16f40 for 192.168.100.120#22, server 0x9f7618
2021-08-09 07:28:32,119 [20665] <binding:19>: found existing ipbind 0xa0fda8 (server 0x9f7618) at index 0 in iptable table, adding to 0xa16f40
2021-08-09 07:28:32,119 [20665] <inet:17>: enabling SO_KEEPALIVE on socket fd 5
2021-08-09 07:28:32,119 [20665] <signal:5>: signals blocked
2021-08-09 07:28:32,119 [20665] <privs:9>: root privs count = 0, honoring PRIVS_ROOT
2021-08-09 07:28:32,119 [20665] <signal:9>: signals already blocked (block count = 1)
2021-08-09 07:28:32,119 [20665] <signal:9>: signals already unblocked (block count = 2)
2021-08-09 07:28:32,119 [20665] <privs:9>: root privs count = 1, user privs count = 0, honoring PRIVS_RELINQUISH
2021-08-09 07:28:32,119 [20665] <signal:9>: signals already blocked (block count = 1)
2021-08-09 07:28:32,119 [20665] <signal:9>: signals already unblocked (block count = 2)
2021-08-09 07:28:32,119 [20665] <signal:5>: signals unblocked
2021-08-09 07:28:32,119 [20665] <binding:4>: bound address 0.0.0.0, port 22 to socket fd 5
2021-08-09 07:28:32,119 [20665] <binding:8>: created ipbind 0xa16f78 for 192.168.100.120#990, server 0x9f7618
2021-08-09 07:28:32,119 [20665] <binding:19>: found existing ipbind 0xa16f40 (server 0x9f7618) at index 0 in iptable table, adding to 0xa16f78
2021-08-09 07:28:32,119 [20665] <inet:17>: enabling SO_KEEPALIVE on socket fd 7
2021-08-09 07:28:32,119 [20665] <signal:5>: signals blocked
2021-08-09 07:28:32,119 [20665] <privs:9>: root privs count = 0, honoring PRIVS_ROOT
2021-08-09 07:28:32,119 [20665] <signal:9>: signals already blocked (block count = 1)
2021-08-09 07:28:32,119 [20665] <signal:9>: signals already unblocked (block count = 2)
2021-08-09 07:28:32,119 [20665] <privs:9>: root privs count = 1, user privs count = 0, honoring PRIVS_RELINQUISH
2021-08-09 07:28:32,119 [20665] <signal:9>: signals already blocked (block count = 1)
2021-08-09 07:28:32,119 [20665] <signal:9>: signals already unblocked (block count = 2)
2021-08-09 07:28:32,119 [20665] <signal:5>: signals unblocked
2021-08-09 07:28:32,119 [20665] <binding:4>: bound address 0.0.0.0, port 990 to socket fd 7
2021-08-09 07:28:32,119 [20665] <event:8>: dispatching event 'core.postparse' to mod_delay (at 0x48b6d0, use cache = false)
2021-08-09 07:28:32,119 [20665] <event:8>: dispatching event 'core.postparse' to mod_log (at 0x487750, use cache = false)
2021-08-09 07:28:32,119 [20665] <event:8>: dispatching event 'core.postparse' to mod_rlimit (at 0x473e70, use cache = false)
2021-08-09 07:28:32,119 [20665] <privs:9>: root privs count = 0, honoring PRIVS_ROOT
2021-08-09 07:28:32,119 [20665] <signal:5>: signals blocked
2021-08-09 07:28:32,119 [20665] <signal:5>: signals unblocked
2021-08-09 07:28:32,119 [20665] <privs:9>: root privs count = 1, user privs count = 0, honoring PRIVS_RELINQUISH
2021-08-09 07:28:32,119 [20665] <signal:5>: signals blocked
2021-08-09 07:28:32,119 [20665] <signal:5>: signals unblocked
2021-08-09 07:28:32,119 [20665] <privs:9>: PRIVS_SETUP called, resetting user/root privs count
2021-08-09 07:28:32,119 [20665] <signal:5>: signals blocked
2021-08-09 07:28:32,119 [20665] <signal:5>: signals unblocked
2021-08-09 07:28:32,119 [20665] <privs:9>: root privs count = 0, honoring PRIVS_ROOT
2021-08-09 07:28:32,119 [20665] <signal:5>: signals blocked
2021-08-09 07:28:32,119 [20665] <signal:5>: signals unblocked
2021-08-09 07:28:32,119 [20665] <scoreboard:7>: reading scoreboard header
2021-08-09 07:28:32,119 [20665] <lock:9>: attempt #1 to write-lock scoreboard mutex fd 9
2021-08-09 07:28:32,119 [20665] <lock:9>: write-lock of scoreboard mutex fd 9 successful after 1 attempt
2021-08-09 07:28:32,119 [20665] <scoreboard:7>: writing scoreboard header
2021-08-09 07:28:32,119 [20665] <lock:9>: attempt #1 to unlock-lock scoreboard mutex fd 9
2021-08-09 07:28:32,119 [20665] <lock:9>: unlock-lock of scoreboard mutex fd 9 successful after 1 attempt
2021-08-09 07:28:32,119 [20665] <privs:9>: root privs count = 1, user privs count = 0, honoring PRIVS_RELINQUISH
2021-08-09 07:28:32,119 [20665] <signal:5>: signals blocked
2021-08-09 07:28:32,119 [20665] <signal:5>: signals unblocked
2021-08-09 07:28:32,119 [20665] <scoreboard:4>: closing scoreboard fd 8
2021-08-09 07:28:32,119 [20665] <event:8>: dispatching event 'core.startup' to mod_core (at 0x468190, use cache = false)
2021-08-09 07:28:32,119 [20665] <timer:7>: added timer ID 1024 ('scoreboard scrubbing', for module 'core'), triggering in 7200 seconds
2021-08-09 07:28:32,119 [20665] <binding:8>: created ipbind 0xa16fb0 for 192.168.100.120#0, server 0x9f7618
2021-08-09 07:28:32,119 [20665] <privs:9>: root privs count = 0, honoring PRIVS_ROOT
2021-08-09 07:28:32,119 [20665] <signal:5>: signals blocked
2021-08-09 07:28:32,119 [20665] <signal:5>: signals unblocked
2021-08-09 07:28:32,119 [20665] <privs:9>: root privs count = 1, user privs count = 0, honoring PRIVS_RELINQUISH
2021-08-09 07:28:32,119 [20665] <signal:5>: signals blocked
2021-08-09 07:28:32,119 [20665] <signal:5>: signals unblocked
2021-08-09 07:28:32,120 [20665] <privs:9>: root privs count = 0, honoring PRIVS_ROOT
2021-08-09 07:28:32,120 [20665] <signal:5>: signals blocked
2021-08-09 07:28:32,120 [20665] <signal:5>: signals unblocked
2021-08-09 07:28:32,120 [20665] <privs:9>: root privs count = 1, user privs count = 0, honoring PRIVS_RELINQUISH
2021-08-09 07:28:32,120 [20665] <signal:5>: signals blocked
2021-08-09 07:28:32,120 [20665] <signal:5>: signals unblocked
netstat -tulpn | grep LISTEN | grep proftpd
lsof | grep proftpd | grep 0t0
proftpd 20665 nobody 2u CHR 136,1 0t0 4 /dev/pts/1
proftpd 20665 nobody 4u sock 0,7 0t0 1688167 protocol: TCP
proftpd 20665 nobody 5u sock 0,7 0t0 1688168 protocol: TCP
proftpd 20665 nobody 7u sock 0,7 0t0 1688169 protocol: TCP
Some sites may wish to host large numbers of vhosts on the same IP address. One way that mod_autohost
could handle these, in addition to (or related to) [HOST
] (see Issue #1) could be to look up the vhost config based on TLS SNI.
Given that the TLS handshake for FTPS connections happens sometime after the initial TCP connection, where any number of commands might happen, supporting SNI will not be as straightforward as destination IP-based lookups. There might be an "initial" config for use such connections, until such time as they provide an SNI via TLS handshake (and/or HOST
command).
Now that proftpd (as of 1.3.6rc1) supports the HOST command, we need to handle name-based vhosts, not just address-based vhosts.
Declaration of pr_namebind_create changed between 1.3.7a and 1.3.7b:
1.3.7a
int pr_namebind_create(server_rec *server, const char *name,
const pr_netaddr_t *addr, unsigned int port);
1.3.7b
int pr_namebind_create(server_rec *server, const char *name,
pr_ipbind_t *ipbind, const pr_netaddr_t *addr, unsigned int port);
This causes make to fail:
mod_autohost.c: In function ‘process_serveralias’:
mod_autohost.c:138:5: warning: passing argument 3 of ‘pr_namebind_create’ from incompatible pointer type [enabled by default]
res = pr_namebind_create(s, c->argv[0], s->addr, s->ServerPort);
^
In file included from ../include/conf.h:86:0,
from mod_autohost.c:28:
../include/bindings.h:160:5: note: expected ‘struct pr_ipbind_t *’ but argument is of type ‘const struct pr_netaddr_t *’
int pr_namebind_create(server_rec *server, const char *name,
^
mod_autohost.c:138:5: warning: passing argument 4 of ‘pr_namebind_create’ makes pointer from integer without a cast [enabled by default]
res = pr_namebind_create(s, c->argv[0], s->addr, s->ServerPort);
^
In file included from ../include/conf.h:86:0,
from mod_autohost.c:28:
../include/bindings.h:160:5: note: expected ‘const struct pr_netaddr_t *’ but argument is of type ‘unsigned int’
int pr_namebind_create(server_rec *server, const char *name,
^
mod_autohost.c:138:5: error: too few arguments to function ‘pr_namebind_create’
res = pr_namebind_create(s, c->argv[0], s->addr, s->ServerPort);
^
In file included from ../include/conf.h:86:0,
from mod_autohost.c:28:
../include/bindings.h:160:5: note: declared here
int pr_namebind_create(server_rec *server, const char *name,
^
make[1]: *** [mod_autohost.o] Error 1
I tested with a simple configuration on Centos 7:
./configure --enable-ipv6 --enable-openssl --with-libraries=/usr/lib64/mysql:/usr/include/openssl --with-includes=contrib/:/usr/include/openssl --with-modules=mod_autohost --prefix=/usr --sysconfdir=/etc --disable-auth-pam --disable-ident --disable-auth-file --disable-sendfile
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.