How to check ports without telnet or netcat in #linux

Home β€Ί News, Other Content, Tech β€Ί How to check ports without telnet or netcat in #linux
How to check ports without telnet or netcat in #linux
How to check ports without telnet or netcat in #linux
There are several reasons why it is recommended to remove Telnet and Netcat from Linux servers, but the main concern is:

Security issues: Telnet and Netcat use plain text to transmit data, making them vulnerable to eavesdropping and data theft. They do not encrypt transmitted data, making it easy for attackers to intercept sensitive information such as passwords.

If your server is offline and you need to check on the remote server if the port is open but telnet, netcat and curl are not installed for security reasons.

If you are using Bash, you can try using the bash /dev/tcp pseudo-device file.

The syntax for accessing a network socket via /dev/tcp is /dev/tcp/ip_address/port_number

Where ip_address is the IP address of the target machine and port_number is the port number on the target machine to connect to.

It is important to note that /dev/tcp is not a standardized feature and is not present on all Unix-like operating systems. Its use is discouraged in modern systems, as it is considered a security risk and unreliable.

To determine if the port specified on the target IP address is open and accepting connections, we can use this command

echo [angle brackets] /dev/tcp/db.lazy/3306 && echo /"Port is open/"

The echo command is used to write data to this network socket. The && operator is used to execute the second command only if the first command completes successfully.

If the port is not open, the first echo command will fail and the second echo command will not be executed. Hope this helps though.

PLEASE Subscribe πŸ™‚
PLEASE LIKE IF THIS HELPED πŸ™‚

GIVE SUPPORT – https://www.patreon.com/lazysysad
BUY ME A COFFEE – https://www.buymeacoffee.com/lazysysad
PAYPAL – https://www.paypal.com/donate/?hosted_button_idK4RQ3LAWHGVS6

Leave me your feedback and comments.

That's all for the moment.

If this video helped you in any way, please like, share and subscribe!

THANKS!!!

Please take the opportunity to connect and share this video with your friends and family if you find it useful.

No Comments

Leave a Reply

Your email address will not be published. Required fields are marked *