官术网_书友最值得收藏!

Locking the root user account

The cloud is big business nowadays, and it's now quite common to rent a virtual private server from companies such as Rackspace, DigitalOcean, or Microsoft Azure. These can serve a variety of purposes, as follows:

  • You can run your own website, where you install your own server software instead of letting a hosting service do it
  • You can set up a web-based app for other people to access
  • Recently, I saw a YouTube demo on a crypto-mining channel that showed how to set up a Proof of Stake master node on a rented virtual private server

One thing that these cloud services have in common is that when you first set up your account and the provider sets up a virtual machine for you, they'll have you log in to the root user account. (It even happens with Ubuntu, even though the root account is disabled on a local installation of Ubuntu.)

I know that there are some folk who just keep logging in to the root account of these cloud-based servers and think nothing of it, but that's really a horrible idea. There are botnets, such as the Hail Mary botnet, that continuously scan the internet for servers that have their Secure Shell port exposed to the internet. When the botnets find one, they'll do a brute-force password attack against the root user account of that server. And yes, the botnets sometimes are successful in breaking in, especially if the root account is set with a weak password.

So, the first thing that you want to do when you set up a cloud-based server is to create a normal user account for yourself and set it up with full sudo privileges. Then, log out of the root user account, log into your new account, and do the following:

sudo passwd -l root

I mean, really, why take the chance of getting your root account compromised?

主站蜘蛛池模板: 辽宁省| 库伦旗| 威宁| 白银市| 正镶白旗| 宁陵县| 丁青县| 黎平县| 平和县| 韶关市| 邓州市| 察雅县| 荥阳市| 沙坪坝区| 安国市| 青神县| 德钦县| 陵水| 施甸县| 全州县| 丁青县| 藁城市| 凤冈县| 鄂托克旗| 万载县| 湖口县| 库车县| 彰化县| 林西县| 东丽区| 庄浪县| 龙胜| 泰宁县| 嘉祥县| 皮山县| 修水县| 元江| 大宁县| 宣城市| 嘉黎县| 思南县|