cancel
Showing results for 
Search instead for 
Did you mean: 

How to change the port of dropbear SSH

take_4
Associate

Hi

I'm using the OpenSTlinux starter package.

I want to change the SSH port communicated by dropbear from 22.

Setting a file in the device and rebooted, but it doesn't change from SSH port 22.

file:  /etc/default/dropbear

DROPBEAR_PORT=10022    *line added

"DROPBEAR_EXTRA_ARGS" setting will take effect after the change.

Is it possible to change the SSH port in dropbear settings?​

Best regards,

1 ACCEPTED SOLUTION

Accepted Solutions
Christophe Guibout
ST Employee

Hello @take_4,

 

To change Dropbear SSH port from 22 to 10022, you need to update the following file : /lib/systemd/system/dropbear.socket:

-ListenStream=22
+ListenStream=10022

This file is also available as a symbolic link in etc folder: /etc/systemd/system/sockets.target.wants/dropbear.socket

 

BR,

Christophe

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.

View solution in original post

1 REPLY 1
Christophe Guibout
ST Employee

Hello @take_4,

 

To change Dropbear SSH port from 22 to 10022, you need to update the following file : /lib/systemd/system/dropbear.socket:

-ListenStream=22
+ListenStream=10022

This file is also available as a symbolic link in etc folder: /etc/systemd/system/sockets.target.wants/dropbear.socket

 

BR,

Christophe

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.