On Thursday 30 September 2004 10:15 am, Tony Ly wrote: > Theo nmap output tre^n thi`: > 68/tcp open dhcpclient - co' the^? ko ca^`n > 631/tcp open ipp - internet printing: cha('c ko ca^`n luo^n > > Ba'c co' the^? ba('t ddaa^`u tu+` file na`y: /etc/inetd.conf. Coi > trong ddo' co' ca'i na`o lie^n quan dde^'n dhcpclient va` ipp thi` > comment it out (du`ng text editor, bo? da^'u # tru+o+'c ca'i line
Sau khi cha.y ca'i script /sbin/myfile, go~ : [EMAIL PROTECTED]:/home/knoppix# nmap -v localhost Starting nmap 3.55 ( http://www.insecure.org/nmap/ ) at 2004-10-02 05:06 EDT Host box (127.0.0.1) appears to be up ... good. Initiating SYN Stealth Scan against box (127.0.0.1) at 05:06 Adding open port 631/tcp Adding open port 68/tcp The SYN Stealth Scan took 1 second to scan 1660 ports. Interesting ports on box (127.0.0.1): (The 1658 ports scanned but not shown below are in state: closed) PORT STATE SERVICE 68/tcp open dhcpclient 631/tcp open ipp Nhu+ng trong /etc/inetd.conf ta^'t ca? ca'c do`ng dde^`u dda~ # ca? ro^`i (file attach). Va^.y sao khi cha.y nmap -v localhost no' co`n ba'o 2 ca'i PORT? Hie^.n ta.i, khi vu+`a boot ma'y le^n, chu+a cha.y /sbin/myfile thi` cu~ng dda~ va`o net ddu+o+.c ro^`i. Cha.y ca'i /sbin/myfile la` dde^? ta(ng cu+o+`ng ma^'y ca'i o^? khoa' Yale pha?i kho^ng? -- m k h _ s g n
#<off># # /etc/inetd.conf: see inetd(8) for further informations. # #<off># # Internet server configuration database # # #<off># # Lines starting with "#:LABEL:" or "#<off>#" should not #<off># # be changed unless you know what you are doing! # #<off># # If you want to disable an entry so it isn't touched during #<off># # package updates just comment it out with a single '#' character. # #<off># # Packages should modify this file by using update-inetd(8) # # <service_name> <sock_type> <proto> <flags> <user> <server_path> <args> # #<off># #:INTERNAL: Internal services #<off># #echo stream tcp nowait root internal #<off># #echo dgram udp wait root internal #<off># #chargen stream tcp nowait root internal #<off># #chargen dgram udp wait root internal #<off># discard stream tcp nowait root internal #<off># discard dgram udp wait root internal #<off># daytime stream tcp nowait root internal #<off># #daytime dgram udp wait root internal #<off># time stream tcp nowait root internal #<off># #time dgram udp wait root internal #<off># #:STANDARD: These are standard services. #<off># ftp stream tcp nowait root /usr/sbin/tcpd /usr/sbin/in.ftpd #<off># #:BSD: Shell, login, exec and talk are BSD protocols. #<off># #:MAIL: Mail, news and uucp services. #<off># #:INFO: Info services #<off># #:BOOT: Tftp service is provided primarily for booting. Most sites #<off># # run this only on machines acting as "boot servers." #<off># tftp dgram udp wait root /usr/sbin/in.tftpd in.tftpd /boot #<off># #:RPC: RPC based services #:HAM-RADIO: amateur-radio services #<off># #:OTHER: Other services #<off># #<off># netbios-ssn stream tcp nowait root /usr/sbin/tcpd /usr/sbin/smbd #<off># printer stream tcp nowait lp /usr/lib/cups/daemon/cups-lpd cups-lpd #<off># vboxd stream tcp nowait root /usr/sbin/tcpd /usr/sbin/vboxd #<off># saft stream tcp nowait root /usr/sbin/tcpd /usr/sbin/sendfiled #<off># #<off># 3632 stream tcp nowait.100 distccd /usr/sbin/tcpd /usr/bin/distccd --inetd --log-file=/var/log/distccd.log --nice=10 #<off># xtel stream tcp nowait root /usr/sbin/tcpd /usr/sbin/xteld #<off># #<off># https stream tcp nowait sslwrap.sslwrap /usr/sbin/tcpd /usr/sbin/sslwrap -nocert -addr 127.0.0.1 -port 80 #<off># #<off># ssmtp stream tcp nowait sslwrap.sslwrap /usr/sbin/tcpd /usr/sbin/sslwrap -nocert -addr 127.0.0.1 -port 25 #<off># #<off># nntps stream tcp nowait sslwrap.sslwrap /usr/sbin/tcpd /usr/sbin/sslwrap -nocert -addr 127.0.0.1 -port 119 #<off># #<off># telnets stream tcp nowait sslwrap.sslwrap /usr/sbin/tcpd /usr/sbin/sslwrap -nocert -addr 127.0.0.1 -port 23 #<off># imaps stream tcp nowait sslwrap.sslwrap /usr/sbin/tcpd /usr/sbin/sslwrap -nocert -addr 127.0.0.1 -port 143 #<off># #<off># ircs stream tcp nowait sslwrap.sslwrap /usr/sbin/tcpd /usr/sbin/sslwrap -nocert -addr 127.0.0.1 -port 194 #<off># pop3s stream tcp nowait sslwrap.sslwrap /usr/sbin/tcpd /usr/sbin/sslwrap -nocert -addr 127.0.0.1 -port 110 #<off># #<off># ftps-data stream tcp nowait sslwrap.sslwrap /usr/sbin/tcpd /usr/sbin/sslwrap -nocert -addr 127.0.0.1 -port 20 #<off># #<off># ftps stream tcp nowait sslwrap.sslwrap /usr/sbin/tcpd /usr/sbin/sslwrap -nocert -addr 127.0.0.1 -port 21 #<off># #<off># ldaps stream tcp nowait sslwrap.sslwrap /usr/sbin/tcpd /usr/sbin/sslwrap -nocert -addr 127.0.0.1 -port 389 #<off># amanda dgram udp wait backup /usr/sbin/tcpd /usr/lib/amanda/amandad