You are not logged in.
Hey fellow archers.
I am currently interested in having access to my desktop PC while being on the fly.
I am however very uncertain what precautions I should take and how it should all work. I'd like to use SSH for this, but what should I do to make it secure since it would be running remotely?
Marcus
Last edited by M_ller (2011-03-07 21:34:46)
Offline
Hey fellow archers.
I am currently interested in having access to my desktop PC while being on the fly.
I am however very uncertain what precautions I should take and how it should all work. I'd like to use SSH for this, but what should I do to make it secure since it would be running remotely?Marcus
Use a non-standard port for your SSH server. Use key-based authentication. Do not allow root logins.
https://wiki.archlinux.org/index.php/Using_SSH_Keys
Last edited by lifeafter2am (2011-03-07 16:05:47)
#binarii @ irc.binarii.net
Matrix Server: https://matrix.binarii.net
-------------
Allan -> ArchBang is not supported because it is stupid.
Offline
M_ller wrote:Hey fellow archers.
I am currently interested in having access to my desktop PC while being on the fly.
I am however very uncertain what precautions I should take and how it should all work. I'd like to use SSH for this, but what should I do to make it secure since it would be running remotely?Marcus
Use a non-standard port for your SSH server. Use key-based authentication. Do not allow root logins.
Thanks!
Setting up the key-based auth. was really easy and works perfectly!
Should I create a new user for my ssh logins etc, or how can I disable root logins?
- Marcus
EDIT: It is all working nicely, however if I don't have the SSH key file, it just asks for the password of the specified user, is it possible to disable that, so they can only connect when having the file?
Last edited by M_ller (2011-03-07 16:45:13)
Offline
Should I create a new user for my ssh logins etc, or how can I disable root logins?
- Marcus
Edit /etc/ssh/sshd_config and make sure that PermitRootLogin is set to no
Offline
Should I create a new user for my ssh logins etc, or how can I disable root logins?
- Marcus
No need to create a new user. Just disable root access. Edit /etc/ssh/sshd_config and locate the line that says "PermitRootLogin" and ensure its set to no.
Offline
Also you can set this in /etc/ssh/sshd_config to prevent from password brute forcing by turning password access off:
PasswordAuthentication noBasically, that's all. There are more methods of securing SSH, but these aren't very common and such efficient:
1) fail2ban. After some sequental authentication failures it blocks this IP. Use with caution!
2) opening ssh port only after some manipulations. Using iptables and some more utils, you can make ssh available only after sending packets on "secret" ports.
Offline
Thanks for all your help.
However, when PermitRootLogin is set to no, I can still do "su" within in SSH'd terminal and then type in the root password, and then be logged in as root.
Am I supposed to be able to do that?
When I try to use my external IP to connect to my SSH server, it gives me this error:
xxxxx: no route to host
I guess that is just a router forwarding problem?
EDIT: And what does "UseLogin no" mean in the sshd_config file?
Last edited by M_ller (2011-03-07 17:10:14)
Offline
Offline
Hello,
I am trying to set up my SSH server but I cannot manage to do it well. In fact, I have this post in order to solve it. Could you please tell me what do you see in my sshd_config file anormal? Or just simply post your file letting me to compare them myself?
Thank you very much
Offline
parmegv: you have managed to both cross-post and thread hijack: https://wiki.archlinux.org/index.php/Fo … _Hijacking
Please do not do this again.
Offline
parmegv: you have managed to both cross-post and thread hijack: https://wiki.archlinux.org/index.php/Fo … _Hijacking
Please do not do this again.
Understood. Should I edit that message, or just send a private message to the one I am interested in?
Offline