Simba
Simba

Reputation: 1651

Linux not accepting connections to port 25

I am working on a simple smtp server, but am stuck on accepting TCP connections on port 25.

I tried running to server and using telnet from localhost and it works. From a separate computer it says trying (ip)...

When sending email's from GMail to my smtp server it does not see any connection

relevant code in Golang

func main() {
    listener, err := net.Listen("tcp", ":25")
    checkError(err)
    for {
        conn, err := listener.Accept()
        checkError(err)
        go handleConnection(conn)
    }
}

It is a Ubuntu server running on Digital Ocean

I know port 25 is not being used and I have file descriptors remaining

Upvotes: 0

Views: 325

Answers (1)

Simba
Simba

Reputation: 1651

Tried it on a different port and it worked. Seems to be a Digital Ocean thing.

Upvotes: 1

Related Questions