logo

Database

Go Unencrypted Telnet Connection

Description

Detects the use of unencrypted Telnet connections through the go-telnet library in Go applications. Telnet transmits data in plaintext, which can expose sensitive information to network eavesdropping and man-in-the-middle attacks.

Weakness:

151 - Use of an insecure channel - Telnet

Category: Information Collection

Detection Strategy

    Check if the 'github.com/reiver/go-telnet' library is imported in the Go source code

    Look for function calls or expressions that use Telnet-related operations from this library

    Report a vulnerability if Telnet connection functions are used, since they represent an insecure communication channel

Vulnerable code example

package main

import (
    "log"
    "github.com/reiver/go-telnet"
)

func main() {...

✅ Secure code example

package main

import (
    "crypto/tls"
    "log"
    "github.com/reiver/go-telnet"
)
...