Results 1 to 9 of 9

Thread: OnePlus 5 - Nethunter

  1. #1
    Junior Member
    Join Date
    Jun 2017
    Posts
    1

    Question OnePlus 5 - Nethunter

    Hello everyone!

    I want to port the Kali Nethunter rom to the OnePlus 5.
    Because it is my first time i need some people who can port it together with me.

    Offensive Security has a nice tutorial on their website but its getting complicated when i come to the modify kernel part.
    I really need some help with that.

    If you got some tips or advice on how to do it let me know!

    Greetings,
    Stefjoe

  2. #2
    Junior Member
    Join Date
    Sep 2015
    Posts
    4

    Nethunter for OnePlus 5

    Quote Originally Posted by stefjoe View Post
    Hello everyone!

    I want to port the Kali Nethunter rom to the OnePlus 5.
    Because it is my first time i need some people who can port it together with me.

    Offensive Security has a nice tutorial on their website but its getting complicated when i come to the modify kernel part.
    I really need some help with that.

    If you got some tips or advice on how to do it let me know!

    Greetings,
    Stefjoe
    I found a way to "port" but not the entire kernel.

    I managed to create chroot and can run Kali shell after one failed trail.
    IMPORTANT : It went into bootloop(only boots into twrp) once while trying to remount /system as rw. But then I figured out SElinux must be disabled. You know what to do if it goes into a bootloop, but just take a backup (nandroid backup didn't work for me)
    And I also lost all of my data after I flashed stock recovery.


    Everything seems to be working fine. But there is a problem with the Nethunter 3.0.
    The
    Code:
    apt-get
    does not work.

    However, I pinged google.com and I get replies.
    So, we need to install metapackages manually. At least for now.

    What I did :
    1. Download OnePlus One nethunter 3.0 ROM
    2. Locate the apks (<nethunter_extracted>/data/app)
    3. Install in this order :
    • Nhterminal
    • VNC
    • Nethunter app
    4. Open the Nethunter app and install the chroot
    ( I selected full chroot, however, you may choose minimal chroot too instead )

    5. From any root explorer, we need to copy the files that are under /data/data/com.offsec.nethunter/files/scripts/*
    to
    /system/bin
    (If you don't find the .../files/scripts, open Nethunter app and try again)

    6. After copying the files to /system/bin,
    There are three important files :
    •bootkali
    •bootkali_bash
    •bootkali_login
    We need to symlink these ↑

    Important : we need to make the /system writable first.
    Run from AndroidSU shell:
    Code:
    #setenforce 0
    Code:
    #mount -o rw,remount /system
    *[Edit]*
    Before linking, you may need to delete the existing bootkali, bootkali_bash and bootkali_login from /system/bin/ first.
    Code:
    OnePlus5:/system/bin# unlink bootkali bootkali_bash bootkali_login
    Then, linking :
    Code:
    ln -s /data/data/com.offsec.nethunter/files/scripts/bootkali /system/bin/bootkali
    Code:
    ln -s /data/data/com.offsec.nethunter/files/scripts/bootkali_bash /system/bin/bootkali_bash
    Code:
    ln -s /data/data/com.offsec.nethunter/files/scripts/bootkali_login /system/bin/bootkali_login
    You can remount /system to read-only if you wish to.

    7. Next, install BusyBox to /system/bin
    Usually, it is installed to /su/xbin.
    But we need to install to /system/bin too.
    This step is necessary.

    8. Now, the Kali shell works fine.
    Try running
    Code:
    #bootkali
    in AndroidSU shell and you should be in the Kali shell
    You can also open Nhterminal app and select Kali.

    9. You may install the other apks now.

    Enjoy ~ !!
    Last edited by raavan666; 2017-08-14 at 11:04 AM. Reason: A correction

  3. #3
    Senior Member
    Join Date
    Feb 2016
    Posts
    113
    Sure, which ROM do you use?
    Bitcoin Donations: 19yTDoJS8YLGh4bSjZEcLU1msTrrn2UoEp

  4. #4
    Junior Member
    Join Date
    Sep 2015
    Posts
    4
    I used the stock Oxygen 4.5.8
    But we need a stable kernel with all the USB drivers, HID, etc.
    I've heard that it's complicated.
    It would be very helpful if someone could port the Nethunter to base Oxygen 4.5.x ROM.

  5. #5
    Senior Member
    Join Date
    Feb 2016
    Posts
    113
    I will do that. But I don't have the device, so you'll have to test the kernel yourself. I do have experience with porting and am porting OPO and OPX variations of the kernels.
    Last edited by Phreya; 2017-08-20 at 06:09 PM.
    Bitcoin Donations: 19yTDoJS8YLGh4bSjZEcLU1msTrrn2UoEp

  6. #6
    Junior Member
    Join Date
    Sep 2015
    Posts
    4
    Okay, I'll do that. But I have no idea about what can go wrong.
    So assist me through the entire process and any warnings, softwares if I hard-bricked the device, etc.

  7. #7
    Senior Member
    Join Date
    Feb 2016
    Posts
    113
    There cannot be a hard-brick, only soft-brick (boot-loop) which can be solved easily but dirty-flashing the rom again. I will let you know when I'm finished.
    Bitcoin Donations: 19yTDoJS8YLGh4bSjZEcLU1msTrrn2UoEp

  8. #8
    Junior Member
    Join Date
    Sep 2015
    Posts
    4
    Roger that.

  9. #9
    Junior Member
    Join Date
    Oct 2017
    Posts
    1
    can u can sent me the link for kali nethunter oneplus 5 and supporting kernel plz ? please build the rom fully we waiting early

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •