Page 1 of 2 12 LastLast
Results 1 to 10 of 12

Thread: Port 25 is magically open

  1. #1

    Question Port 25 is magically open

    I just installed openSUSE 13.1, and I executed nmap on my local host
    Code:
    nmap localhost
    and I found open the port 25. I have no SMTP service running, I mean, I got one, but I don't know why, I didn't setup any. By the way, it can only be accessed locally.

    Running netstat -p doesn't show the name of the listening application.

    How can I disable the service?.

  2. #2
    Join Date
    Jun 2008
    Location
    Netherlands
    Posts
    29,840

    Default Re: Port 25 is magically open

    You better SHOW us in stead of only telling what you saw. Post prompt, command, output, next prompt by copy/pasting from the terminal window into a post between CODE tags.

    Like this:
    Code:
    henk@boven:~> nmap localhost
    
    Starting Nmap 6.01 ( http://nmap.org ) at 2014-01-12 12:45 CET
    Nmap scan report for localhost (127.0.0.1)
    Host is up (0.00041s latency).
    Not shown: 992 closed ports
    PORT     STATE SERVICE
    21/tcp   open  ftp
    25/tcp   open  smtp
    80/tcp   open  http
    111/tcp  open  rpcbind
    631/tcp  open  ipp
    873/tcp  open  rsync
    2049/tcp open  nfs
    3306/tcp open  mysql
    
    Nmap done: 1 IP address (1 host up) scanned in 0.15 seconds
    henk@boven:~>
    And
    Code:
    henk@boven:~> netstat -tulpn | grep ':25'
    (Not all processes could be identified, non-owned process info
     will not be shown, you would have to be root to see it all.)
    tcp        0      0 127.0.0.1:25            0.0.0.0:*               LISTEN      -                   
    tcp        0      0 ::1:25                  :::*                    LISTEN      -                   
    henk@boven:~> su -
    Wachtwoord: 
    boven:~ # netstat -tulpn | grep ':25'
    tcp        0      0 127.0.0.1:25            0.0.0.0:*               LISTEN      2532/master         
    tcp        0      0 ::1:25                  :::*                    LISTEN      2532/master         
    boven:~ #
    And this illustrates why we ask this. Not being root does not give you the PID and process name (as the warning states). And doing as we ask, will show if you were root or not (and other information that migh t be usefull for helpers).
    Henk van Velden

  3. #3

    Default Re: Port 25 is magically open

    Code:
    $nmap localhost
    
    Starting Nmap 6.40 ( http://nmap.org ) at 2014-01-12 08:56 ART
    Nmap scan report for localhost (127.0.0.1)
    Host is up (0.00019s latency).
    Not shown: 998 closed ports
    PORT   STATE SERVICE
    22/tcp open  ssh
    25/tcp open  smtp
    port 25 is intentionally open.

    Code:
    #sudo netstat -tulpn | grep ':25'
    harry's password:
    tcp        0      0 127.0.0.1:25            0.0.0.0:*               LISTEN      1460/master         
    tcp        0      0 ::1:25                  :::*                    LISTEN      1460/master
    master?, what is that?. I don't want a smtp server running.

  4. #4
    Join Date
    Jun 2008
    Location
    Netherlands
    Posts
    29,840

    Default Re: Port 25 is magically open

    Quote Originally Posted by ninioArg View Post
    master?, what is that?. I don't want a smtp server running.
    What about starting with:
    Code:
    man master
    Henk van Velden

  5. #5
    Join Date
    Feb 2009
    Location
    Spain
    Posts
    25,547

    Default Re: Port 25 is magically open

    On 2014-01-12 13:06, ninioArg wrote:

    > master?, what is that?. I don't want a smtp server running.


    Yes, you do. >:-)

    --
    Cheers / Saludos,

    Carlos E. R.
    (from 12.3 x86_64 "Dartmouth" at Telcontar)

  6. #6
    Join Date
    Jun 2008
    Location
    Netherlands
    Posts
    29,840

    Default Re: Port 25 is magically open

    Quote Originally Posted by robin_listas View Post
    On 2014-01-12 13:06, ninioArg wrote:

    > master?, what is that?. I don't want a smtp server running.


    Yes, you do. >:-)

    --
    Cheers / Saludos,

    Carlos E. R.
    (from 12.3 x86_64 "Dartmouth" at Telcontar)
    Very informative answer indeed
    Henk van Velden

  7. #7
    Join Date
    Feb 2009
    Location
    Spain
    Posts
    25,547

    Default Re: Port 25 is magically open

    On 2014-01-12 15:36, hcvv wrote:
    >
    > robin_listas;2615316 Wrote:
    >> On 2014-01-12 13:06, ninioArg wrote:
    >>
    >>> master?, what is that?. I don't want a smtp server running.

    >>
    >> Yes, you do. >:-)


    > Very informative answer indeed


    It is, isn’t? :-)

    Well, he can ask me why. I'm waiting for that step, as a matter of fact.

    --
    Cheers / Saludos,

    Carlos E. R.
    (from 12.3 x86_64 "Dartmouth" at Telcontar)

  8. #8

    Default [Solved] Re: Port 25 is magically open

    Well, it's done. The master starts a Postfix daemon. So, just remove the execution permission:
    Code:
    #chmod -x /etc/init.d/postfix
    And if you want stop it for this session, it is not enough stopping the daemon:
    Code:
    #sh /etc/init.d/postfix stop
    you need to kill the process :S
    Code:
    #kill -9 PID
    ---------------------------------
    Quote Originally Posted by robin_listas
    It is, isn’t? :-)
    Well, he can ask me why. I'm waiting for that step, as a matter of fact.
    Please, avoid trying to help people, you don't.

  9. #9

    Default Re: Port 25 is magically open

    Btw, you can also avoid postfix starts by editing /etc/postfix/master.cf.

  10. #10
    Join Date
    Jun 2008
    Location
    Auckland, NZ
    Posts
    23,711
    Blog Entries
    1

    Default Re: Port 25 is magically open

    Quote Originally Posted by ninioArg View Post
    Btw, you can also avoid postfix starts by editing /etc/postfix/master.cf.
    Or use systemd to do it
    Code:
    systemctl status postfix.service
    Code:
    systemctl stop postfix.service
    Code:
    systemctl disable postfix.service

Page 1 of 2 12 LastLast

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •