Forwarding traffic from Mikrotik to a SSH server

I want to configure the mikrotik router to send traffic to a SSH server that is listening on port 2222 and I tried the /system ssh commands but they are for connection in client terminal mode. I have set forwarding-enabled both=yes to allow forwarding in both directions but I can’t find out how to forward the mikrotik traffic to the listening server at ip address 192.168.43.1 port:2222 user:guest . Can anyone who has done this describe to me how they have configured the mikrotik?

What do you mean by forward?

Are you asking about port forwarding???

First, give me a minute as I am getting over the seizure induced by the colours of the previous poster, thank god they were not shimmering too.
(Note: the poster does not have the rare and exalted MTUNA designation - rule 34 states avoid excessive misleading or arrogant use of colour :stuck_out_tongue_winking_eye: )

If you have an SSH server behind the router are you looking to
a. forward internet traffic to the server,
b. forward LAN traffic to the server via the WANIP of your ISP.

Both are port forwarding with case b., being a loopback (hairpin nat) scenario.
In either case, the setup is also predicated on what type of ISP connection you have, fixed/static wanip or dynamic wanip.
The requirements are basically a working source nat rule, the specific destination nat rule and a general forward filter chain rule allowing destination nat traffic (included in default rules).

I explain better what I intend to do with a drawing that I have uploaded to Drive accessible through the url= https://drive.google.com/file/d/1RfzhOYi1WOVRmz6s6RUc9p4JhYzOCRzf/view?usp=sharing

The drawing explains the problem of connecting the mikrotik router via ssh to an access point that has an ssh server listening at the address 192.168.43.1:2222. For which I suppose that it would be necessary to activate an SSH client in the Mikrotik router to link it to the address 192.168.43.1:2222 but I don’t know how to do it. If you have an example it would help me a lot to solve it

The diagram is mildly helpful.

A. Is your ISP a wisp, seems to me you are getting internet via wifi.
B. Who owns the Access point and it is just an access point or an access/point router??
C. Where is the modem?
B. Is your ISP also providing the router functionality (you are getting a fixed WANIP)
I) not a public IP
ii) simply a private net (lanip on WISP subnet).

Unless the provider gives you
a. a public IP
b. a private IP but forwards a particular port your IP,

Port forwarding will not be possible.

Hi Anav,

Sorry that my Signature colors were bothering your eyes… (I never though about people having color blindness :laughing: )
Well I have Changed colors now :smiley:

That is much better, the colour clashing was the real problem… now they flow together well. '-P

Thanks :smiley:

I don’t understand what you’re doing to accomplish. Are you trying to ssh to the access point from a workstation connected to the router? Or, having already connected via ssh or Winbox to the router, you then want to ssh to the access point?

If you’re using an ssh client from 192.168.88.214, then you could try the following on the Mikrotik router:

/ip firewall nat add action=dst-nat chain=dstnat comment="Forward SSH for access point on port 2222" dst-address=192.168.88.1 dst-port=2222 protocol=tcp to-addresses=192.168.43.1 to-ports=2222

Then use your ssh client and set the user/password accordingly to connect.