How to add remove user (standard user/non-root) in Kali Linux?

  1. Add a user with all user directories already in place (thereby avoiding “Could not update .ICEauthority var/lib/gdm3/.ICEauthority” or any error containing .ICEauthority or permission in general.
  2. Add user to sudo group to allow him to use root commands. You can also add user to ‘lpadmin’ group to allow printing for Canon or HP and such. See Linux printing guide
  3. Change default shell from chsh to bash. Or any shell like Bourne Shell (sh), Bourne-Again Shell (bash), C Shell (csh) or Korn shell (ksh) etc.
  4. Login as that user and demonstrate there were no errors.
  5. Be able to use sudo and show groups affinity.
  6. Delete that user safely.

Benefits of Standard User in Kali:

Few benefits you have as non-root or standard user in Kali

  1. Install and run Google Chrome
  2. Install and run Gnome User and Groups manager (Install gnome-system-tools)
  3. Use Kali as Primary Operating System without worrying about breaking it all the time.

Now let’s move onto actual guide.

Add user in Kali Linux:

  • First of all let’s confirm which version of Linux and Kernel I’m running.In command prompt type in
    uname –a
    lsb_release –a

    How to add remove user - Standard usernon-root - in Kali Linux - blackMORE Ops -1

  • Now let’s add user. Open terminal and type following to create new user (replace user1 with your desired user name)
    useradd -m user1

    How to add remove user - Standard usernon-root - in Kali Linux - blackMORE Ops -2

    (Note: -m means create home directory which is usually /home/username)

  • Now set password for this user
    passwd user1

    Enter desired password twice

    How to add remove user - Standard usernon-root - in Kali Linux - blackMORE Ops -3

  • Add user to sudo group (to allow user to install software, allow printing, use privileged mode etc.)
    usermod -a -G sudo user1

    How to add remove user - Standard usernon-root - in Kali Linux - blackMORE Ops -4

    (Note: -a means append or add and –G mean to specified group/groups)

  • Change default shell of previously created user to bash
    chsh -s /bin/bash user1

    How to add remove user - Standard usernon-root - in Kali Linux - blackMORE Ops -5

    (Note: chsh mean change login shell, -s is the name of the specified shell you want for the user, in this case /bin/bash)

    Nice, all worked out as expected.
    Let’s logout and login back as our new Standard Non-root user (user1)


  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值