Disable Direct Root Login and User Access via SSH to Server Désactiver le login root direct et l'accès des utilisateurs par SSH au serveur
Everybody knows, including hackers and attackers that all Linux and UNIX flavored systems come with a all powerful root user account, which once get compromised, mean all hell breaks loose. Tout le monde sait, y compris les pirates et les assaillants que tous les UNIX et Linux à saveur systèmes sont livrés avec un tout-puissant compte utilisateur root, qui une fois compromis, l'ensemble des pauses enfer lâches. So it’sa good security practice to disable the ability for root user to able to login and gain access to the server system via SSH directly (of course, the system must have disabled FTP access). Donc c'est une bonne pratique de sécurité de désactiver la possibilité pour l'utilisateur root pour pouvoir se connecter et avoir accès au serveur via SSH directement (bien sûr, le système doit avoir un accès FTP handicapés). After disabling direct root SSH remote login, the chance for the brute force hacking to success is greatly reduced. Après la désactivation directe racine SSH connexion distante, la possibilité pour la force brutale de piratage du succès est grandement réduite.
To turn off and disable direct root SSH login, follow this simple tutorial: Pour désactiver et désactiver directement racine de connexion SSH, suivez ce tutoriel:
IMPORTANT: Make sure you have another account (preferably belongs to wheel user group too) which is able to login via SSH remotely, and able to SU to root user account. IMPORTANT: Assurez-vous que vous avez un autre compte (de préférence appartient à roue groupe d'utilisateurs trop), qui est capable de se connecter à distance par SSH, et capable de passer en root avec su compte d'utilisateur. Else you risk been locked out from your server. Sinon vous risquez été lock-out de votre serveur.
- SSH into server and login as root. SSH en serveur et connectez-vous en tant que root.
- In command shell, use pico or vi to edit sshd_config file by typing one of the following commands: En commande shell, l'utilisation pico ou vi pour éditer le fichier sshd_config en tapant une des commandes suivantes:
pico /etc/ssh/sshd_config pico / etc / ssh / sshd_config
vi /etc/ssh/sshd_config vi / etc / ssh / sshd_config - Scroll down the SSH server configuration file and locate a line like below: Faites défiler la liste vers le serveur SSH fichier de configuration et trouver une ligne comme celle ci-dessous:
#PermitRootLogin yes # PermitRootLogin yes
- Uncomment the line by removing the hash symbol (#), and then change the “yes” to “no”. Décommentez la ligne en supprimant la symbole dièse (#), puis changer le "oui" à "no". The final line should look like below: La dernière ligne devrait ressembler à ci-dessous:
PermitRootLogin no PermitRootLogin no
- Save the config file. Enregistrez le fichier de configuration. In pico, press Ctrl-o, follow by Ctrl-x. Dans pico, appuyez sur Ctrl-o, suivi par Ctrl-x. In vi, type :wq and press Enter. Dans vi, tapez: wq et appuyez sur Entrée.
- Restart SSH server by typing the following command in command line, and press Enter: Redémarrez le serveur SSH en tapant la commande suivante dans la ligne de commande, et appuyez sur Entrée:
/etc/rc.d/init.d/sshd restart / etc / rc.d / init.d / sshd redémarrer
- Logout from SSH connection. Sortir de connexion SSH. Try to login as root, it should fail with Access denied error. Essayez de vous connecter en tant que root, il échoue avec l'erreur Access denied. To access root account, login with your own user name and password, and then SU to root. Pour accéder à ce compte, connectez-vous avec votre propre nom d'utilisateur et mot de passe, puis passer en root avec su.
IMPORTANT : This is a machine translated page which is provided "as is" without warranty. IMPORTANT: Il s'agit d'une machine qui traduit la page est fourni «tel quel», sans garantie. Machine translation may be difficult to understand. La traduction automatique mai être difficile à comprendre. Please refer to S’il vous plaît se référer à original English article article original anglais whenever possible. chaque fois que possible.
Share and contribute or get technical support and help at Partagez et contribuer ou obtenir de l'aide technique et l'aide à My Digital Life Forums Ma vie numérique forums .
Related Articles Articles connexes
- How to Get Linux Server Sends Email Alert on Root Login Comment obtenir Linux serveur envoie alerte par e-mail sur login root
- Disable and Turn Off Telnet in Linux Désactiver et désactiver telnet sous Linux
- Cannot FTP to Web Host or Server running cPanel/WHM Impossible de FTP sur le Web ou le serveur hôte fonctionnement cPanel / WHM
- cPanel Invalid License File After Changing Hostname Error cPanel fichier de licence non valide après avoir changé le nom de l'hôte erreur
- Restore Full Backup or cpmove File in cPanel Web Host Réactiver le compte cpmove de sauvegarde ou de dossier dans cPanel Web Host
- Using phpMyAdmin for Effective MySQL Management in Windows XP Utilisation de phpMyAdmin pour MySQL efficace de gestion sous Windows XP
- Installing Web Server in FreeBSD 6.0 with Apache 2.2, MySQL 5.0 and PHP 5 - Part 3 Installation du serveur Web dans FreeBSD 6,0 avec Apache 2,2, 5,0 MySQL et PHP 5 - Partie 3
- Change and Reset MySQL root Password Changement et Réinitialiser le mot de passe root
- How to Check if Telnet Is Running on a Server Comment vérifier si Telnet est en cours d'exécution sur un serveur
- Check and Optimize MySQL Database Automatically with Crontab/Cron Vérifier et optimiser automatiquement la base de données MySQL avec crontab / cron
































