Solved

Changing SSH port

Posted on 2000-03-06
4
263 Views
Last Modified: 2013-12-16
Hello,

Can anyone tell me how to change my SSH configuration to listen on another port (preferably 23)?

I want to connect to my home box from work via SSH, but my company's proxy blocks 22.  Telnet (23), web (80) and maybe some others I do not know about are allowed.

I want to use RSA authentication.  If I understand the SSH manpage, I need to keep the port number low.

I tried modifying 'sshd_config' and 'ssh_config' to no avail.

Any ideas?

Thanks in advance,
CubeDweller
0
Comment
Question by:cubedweller
  • 2
4 Comments
 

Expert Comment

by:karwoski
ID: 2590061
If you're using SSH2 you can change the port number in the /etc/ssh2/ssh2_config file.  In that file there's a line:

Port      22

and you can change that to whatever you want. If you have SSH1 and you don't have a SSH subdir in /etc just poke around in /etc for a file name with something to the effect of sshconfig.
0
 
LVL 40

Accepted Solution

by:
jlevie earned 50 total points
ID: 2590071
You can't do it by just changing SSH. Port 23 is already owned by telnet and ssh won't be able to listen on that port as long as inetd thinks it belongs to telnet. If you change inetd so that ssh will use 23 you'll prevent telnet from working on that system.

Why don't you try talking to the network administrators about enabling port 22 for ssh? They may have the others disabled for security reasons, but may not view ssh as being a significant risk.
0
 

Author Comment

by:cubedweller
ID: 2592588
Karwoski, thank you for your answer.

Jlevie is more correct though, since I had to disable telnet first to free up port 23.
0
 

Author Comment

by:cubedweller
ID: 2592619
Thank you again, jlevie.
0

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
App holding yum lock unable to update my rpm package 1 54
route 2 traffic streams on single NIC 6 49
linux 13 50
Linux mount of Windows Shared Now Fails 8 39
Setting up Secure Ubuntu server on VMware 1.      Insert the Ubuntu Server distribution CD or attach the ISO of the CD which is in the “Datastore”. Note that it is important to install the x64 edition on servers, not the X86 editions. 2.      Power on th…
The purpose of this article is to demonstrate how we can use conditional statements using Python.
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question