Linux - SecurityThis forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
First:
"Urgent" must be urgent to me. How can I know whether it is urgent to you?
I just want to express my feeling about my situation. Shouldn't I do this?
Second:
"Be specific". What's your point? How am I "non-specifie"? Pls. be specific to me.
Third:
I am asking about the setup of sshd. NOT ssh client.
I've read the file sshd_config.
There is a field to allows the login from a specific host NOT a specific user.
Fourth:
Thanks for your advice. However, could you pls. be more specific?
What keywords should I input?
Fifth:
How can you know "I haven't search the web."?
I just don't know how to search what I want.
Sixth:
If you're willing to help, just skip the post.
No need to blame others.
If you think the post is nonsense, talk to the admin. and kill this post.
Where did I find that? In the sshd_config man page:
Quote:
AllowUsers
This keyword can be followed by a list of user name patterns, separated by spaces. If specified, login is allowed only for user names that match one of the patterns. `*' and `?' can be used as wildcards in the patterns. Only user names are valid; a numerical user ID is not recognized. By default, login is allowed for all users. If the pattern takes the form USER@HOST then USER and HOST are separately checked, restricting logins to particular users from particular hosts.
I apologize for my rudeness. Your help is so precious to me.
My urgent situation is that:
I am an admin of a over-100-user computer. 70% of them know nothing about computer and
their password is same as their username(So stupid, right?).
In the past few days, there are some hackers login to the computer and ruined the system.
I've just reinstall it and find the hackers AGAIN.
Your help let me know how to block these hackers and still allowing to do the admin job.
Thanks a lot and please accept my sincere apology.
Personally, I'd start by kicking my users squarely in their foreheads one at a time....
Then Setup public/private key auth for a non root user and only allow that user to logon via ssh with the AllowUsers directive. Then, add that user to the wheel group and set "su" to be executable only to users in "wheel" and root
Then you could log in with that user, using a rsa key/passphrase combo and su to root as needed
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.