12-07-2012 08:47 AM - edited 03-11-2019 05:34 PM
Hello. We have a ASA5510 and I need to open port 22 for a speacific IP in our LAN outbound only. How do I do that? Thanks.
12-07-2012 09:05 AM
Hello Asif,
Can you clarify, you want to permit ssh access from or to your LAN?
12-07-2012 09:10 AM
I think to my LAN. But just to a speacific IP. There is a company who needs to a remote into a machine that has a static IP for support purposes and they want port 22 to be open for outbound traffic only just for that IP.
12-07-2012 09:16 AM
Asif,
In this case you need to do the following:
1. ASA version before 8.3
If you alredy have access-list attached to the outside interface you can just put this two statements at the beggining:
access-list
access-list
2. ASA version after 8.3
If you alredy have access-list attached to the outside interface you can just put this two statements at the beggining:
access-list
access-list
this will make only one host on the LAN accesible via ssh, all other ssh traffic to your LAN will be denied
Please rate helpful posts
Best Regards,
Eugene
12-07-2012 10:40 AM
My ASA is 8.3(2). So I would use the after 8.3 statements right?
Is the "real ip of the host" the internal static IP?
12-07-2012 10:43 AM
Hi Asif,
Yes, your option is after 8.3, and real ip address - is your internal ip.
Please rate helpful posts
Best Regards,
Eugene
12-07-2012 11:10 AM
OK. Now do I need to have the second statement too. Instead can I include the IP of the company who will be ssh'ing into my internal IP? The reason why I say this is becauce I'm not sure if I want to block all other ssh connections if there are any.
12-07-2012 11:22 AM
If you don't need to block other ssh traffic, then you don't need second statement.
Regarding source ip address, yes you can include it. Access list statement on outside interface in this case will look like:
access-list
Please consider using this variant, in previous post "any" and "host" should be swapped
Please rate helpful posts
Best Regards,
Eugene
12-07-2012 11:35 AM
Great. Thanks for your help. And how do I assign this access-list to the outside interface?
12-07-2012 11:39 AM
You can assign access-list with following command:
access-group
Also access-lists containts explicit "deny any any" at the end.
Please refer to configuration guide:
http://www.cisco.com/en/US/docs/security/asa/asa84/configuration/guide/acl_overview.html
Please rate helpful posts
Best Regards,
Eugene
12-07-2012 11:44 AM
At the end? At the end of my statement?
12-07-2012 11:50 AM
Also, instead of having "ssh" at the end of the statement I could just use "22" right?
12-07-2012 12:21 PM
At the end of the access-lists, and yes you can use 22
Best Regards,
Eugene
12-07-2012 12:26 PM
Now I'm confused. My statement will look like this right?
access-list cary-PCMC extended permit tcp host
access-group cary-PCMC in interface outside
12-07-2012 12:45 PM
As I said before, in each access-list there is implicit deny any any statement, if you will have only this configuration, only ssh will work from outside.
Please refer to the link, which I already provided.
Best Regards,
Eugene
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide