I don't think so, it does make use of shell_exec().
However apache is run as nobody, but the logged in user is me 'philip'. And in my first post I logged in on tty2 and made sure no one was logged in on tty1 and it still showed me logged in on tty1.
For reference the bit of php is simply
PHP Code:
echo shell_exec("uptime");
Edit:
If this script was making a terminal, then surely it would be pts/n type terminal?
Another Edit:
I shutdown X and logged out, so that no one at all was logged in, I then logged in on tty2. The output of who showed that I was also logged in on tty1. The log in time was correct - the system just hasn't recognised that I was no longer logged in on tty1. The output of `ps aux` whilst only being logged in on tty2 is:
Code:
USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND
root 1 0.0 0.0 588 228 ? S Oct13 0:00 init [3]
root 2 0.0 0.0 0 0 ? SN Oct13 0:02 [ksoftirqd/0]
root 3 0.0 0.0 0 0 ? S< Oct13 0:00 [events/0]
root 4 0.0 0.0 0 0 ? S< Oct13 0:00 [khelper]
root 19 0.0 0.0 0 0 ? S< Oct13 0:02 [kblockd/0]
root 32 0.0 0.0 0 0 ? S Oct13 0:00 [khubd]
root 75 0.0 0.0 0 0 ? S Oct13 0:00 [kapmd]
root 104 0.0 0.0 0 0 ? S< Oct13 0:00 [aio/0]
root 103 0.0 0.0 0 0 ? S Oct13 0:07 [kswapd0]
root 693 0.0 0.0 0 0 ? S Oct13 0:00 [kseriod]
root 822 0.0 0.0 0 0 ? S< Oct13 0:01 [reiserfs/0]
root 873 0.0 0.0 1384 352 ? S<s Oct13 0:00 udevd
root 1847 0.0 0.0 1576 600 ? Ss Oct13 0:00 /usr/sbin/syslogd
root 1850 0.0 0.0 1532 456 ? Ss Oct13 0:00 /usr/sbin/klogd -c 3 -x
root 2006 0.0 0.0 0 0 ? S Oct13 0:00 [khpsbpkt]
root 2094 0.0 0.0 0 0 ? S Oct13 0:00 [knodemgrd_0]
root 2166 0.0 0.0 0 0 ? S Oct13 0:00 [shpchpd_event]
root 2208 0.0 0.0 0 0 ? S Oct13 0:00 [pciehpd_event]
root 2257 0.0 0.0 0 0 ? S< Oct13 0:00 [ata/0]
root 2279 0.0 0.0 0 0 ? S Oct13 0:00 [scsi_eh_0]
root 2280 0.0 0.0 0 0 ? S Oct13 0:00 [scsi_eh_1]
root 2295 0.0 0.0 0 0 ? S Oct13 0:00 [scsi_eh_2]
root 2296 0.0 0.0 0 0 ? S Oct13 0:00 [scsi_eh_3]
root 5349 0.0 0.0 1436 516 ? Ss Oct13 0:00 /usr/sbin/inetd
root 5352 0.0 0.1 3280 1472 ? Ss Oct13 0:00 /usr/sbin/sshd
root 5366 0.0 0.1 4952 2028 ? Ss Oct13 0:00 /usr/sbin/cupsd
root 5379 0.0 0.0 1724 628 ? S Oct13 0:00 /usr/sbin/crond -l10
root 5428 0.0 0.0 2416 952 ? Ss Oct13 0:00 /usr/libexec/postfix/master
root 5430 0.0 0.0 1392 520 ? Ss Oct13 0:00 /usr/sbin/apmd
postfix 5433 0.0 0.0 2472 1036 ? S Oct13 0:00 qmgr -l -t fifo -u
root 5567 0.0 0.1 6576 2060 ? Ss Oct13 0:00 /usr/sbin/smbd -D
root 5569 0.0 0.1 3444 1424 ? Ss Oct13 0:00 /usr/sbin/nmbd -D
root 5571 0.0 0.0 1448 472 ? Ss Oct13 0:00 /usr/sbin/gpm -m /dev/mouse -t ps2
root 5575 0.0 0.1 6576 2048 ? S Oct13 0:00 /usr/sbin/smbd -D
root 5576 0.0 0.1 3024 1060 ? Ss Oct13 0:55 /usr/sbin/dovecot
root 5578 0.0 0.3 3696 3692 ? SLs Oct13 0:00 /usr/sbin/ntpd
root 5581 0.0 0.0 1400 484 tty3 Ss+ Oct13 0:00 /sbin/agetty 38400 tty3 linux
root 5582 0.0 0.0 1400 484 tty4 Ss+ Oct13 0:00 /sbin/agetty 38400 tty4 linux
root 5583 0.0 0.0 1400 484 tty5 Ss+ Oct13 0:00 /sbin/agetty 38400 tty5 linux
root 5584 0.0 0.0 1400 484 tty6 Ss+ Oct13 0:00 /sbin/agetty 38400 tty6 linux
root 5655 0.0 0.1 3136 1168 ? S Oct13 0:02 dovecot-auth
root 20554 0.0 0.0 0 0 ? S Oct15 0:01 [pdflush]
root 20558 0.0 0.0 0 0 ? S Oct15 0:03 [pdflush]
root 25336 0.0 0.5 15840 5844 ? Ss 08:42 0:00 /usr/local/apache/bin/httpd -k start -DSSL
nobody 25337 0.0 0.5 15988 5956 ? S 08:42 0:00 /usr/local/apache/bin/httpd -k start -DSSL
nobody 25338 0.0 0.5 15988 6036 ? S 08:42 0:00 /usr/local/apache/bin/httpd -k start -DSSL
nobody 25339 0.0 0.5 15840 5880 ? S 08:42 0:00 /usr/local/apache/bin/httpd -k start -DSSL
nobody 25340 0.0 0.5 15840 5876 ? S 08:42 0:00 /usr/local/apache/bin/httpd -k start -DSSL
nobody 25341 0.0 0.5 15840 5876 ? S 08:42 0:00 /usr/local/apache/bin/httpd -k start -DSSL
philip 25356 0.0 0.1 3376 1920 tty2 Ss 08:43 0:00 -bash
dovecot 25612 0.0 0.1 3024 1452 ? S 09:27 0:00 imap-login
dovecot 25614 0.0 0.1 3024 1452 ? S 09:27 0:00 imap-login
postfix 25619 0.0 0.0 2440 912 ? S 09:27 0:00 pickup -l -t fifo -u
dovecot 25627 0.0 0.1 3024 1452 ? S 09:28 0:00 imap-login
root 25646 0.0 0.0 1400 484 tty1 Ss+ 09:30 0:00 /sbin/agetty 38400 tty1 linux
philip 25658 0.0 0.0 2536 852 tty2 R+ 09:31 0:00 ps aux
I run `chkrootkit` and `rkhunter` every day via cron and have done since the system was first setup and there have been no breaches. I also regularly check the logs and nothing untoward has been happening