How to Install kali linux on android without root .


 

Hello friends, In this article we will see how we can install kali linux with desktop on our android device without having root access .

Required Application 

Termux
VNC viewer


Installation

So first we have to update our termux repositories .

pkg update


Now enter the following command to install kali linux .

pkg install wget openssl-tool proot -y && hash -r && wget https://raw.githubusercontent.com/EXALAB/AnLinux-Resources/master/Scripts/Installer/Kali/kali.sh && bash kali.sh


Once kali linux is installed then start it .


./start-kali.sh


Now, first we have to update its repositories so that we can install packages .

apt update


We have to add a temporary user because you may harm your system if you don't have better knowledge about it .

adduser {username}


Now we have to install sudo and nano so that we can get superuser access in temporary user .

apt install sudo nano -y


Now we have to configure superuser permissions for our user.

nano /etc/sudoers


Now you we see a line starting with root just copy that line and just after that line paste the text that you copied and replace root with your username.

Once you have done that just save it by  ctrl  +  o  and exit by  ctrl  +  x


Now login to your temporary user.

su {username}


Now we have to install a desktop environment so that we can use kali in GUI mode, here I am using xfce because its a lightweight desktop .

sudo apt install -y xfce4*  -y


Once xfce is installed, then install tightvncserver and kali linux themes .

sudo apt install tightvncserver kali-themes dbus-x11 -y


Now we will install firefox browser, web server and a text editor .

sudo apt install firefox-esr apache2 leafpad -y


Once it has installed then start vncserver and setup your password for vnc.

vncserver
 

Now we have to configure xstartup file.

nano .vnc/xstartup


clear all the line in it and paste the following.

#!/bin/bash
startxfce4 &


Now stop vnc server.

vncserver -kill :1


Now start vncserver again.

vncserver -geometry 1920x1080


You can change 1920x1080 according to  your device .

Now open VNC viewer app and create a connection with localhost:1 and connect .

Here is the complete video tutorial :


        Subscribe our YouTube channel

9 Comments

  1. tbot@localhost:~$ vncstart

    Warning: localhost:1 is taken because of /tmp/.X1-lock
    Remove this file if there is no X server localhost:1

    Warning: localhost:2 is taken because of /tmp/.X2-lock
    Remove this file if there is no X server localhost:2

    Warning: localhost:3 is taken because of /tmp/.X3-lock
    Remove this file if there is no X server localhost:3

    Warning: localhost:4 is taken because of /tmp/.X4-lock
    Remove this file if there is no X server localhost:4

    New 'X' desktop is localhost:8

    Starting applications specified in /home/tbot/.vnc/xstartup
    Log file is /home/tbot/.vnc/localhost:8.log

    solve my problem

    ReplyDelete
  2. help me plz !

    root@localhost:~# sudo apt install -y xfce4* -y
    Killed

    sudo return " Killed "

    I can continue without sudo ?

    ReplyDelete
    Replies
    1. Yes u can if u want remove sudo and -y from last

      Delete
  3. I've run it successfully but after I stop the server and I start it again why the screen in the vnc viewer goes blank instead

    ReplyDelete
  4. vncserver: geometry 1920×1080 is invalid

    ReplyDelete
    Replies
    1. What can. I do , pls ans me

      Delete
Post a Comment
Previous Post Next Post