Adding proper SU to AOSP - Android Q&A, Help & Troubleshooting

Hi all,
I'm trying to solve this but I didn't find proper solution. I have Android 9 SDK for specific SoC vendor (Amlogic, but this is not important now - It's basically AOSP).
What I'm trying to implement into my SDK is proper root access with su daemon running and all things that come with su.
I looked at LineageOS implementation but it seems that it's too deeply implemented into it's sources now (such as using lineageos SettingsProvider etc). Does anyone know easier solution for achieving this?
Thanx,
Stane1983

Related

[Q] Compiling a kernal module from stage 1

Hi
Could anybody point me in the direction of sourcing, locating and compiling a kernel module please? I have found many guides but they all seem to start halfway in the process ("assuming you have already managed to...", "assuming you are already proficient with...")
I have a cheap Android Chinese TV box. It came without joydev.ko so I can't use it with joypads/sticks, which is a pretty big limitation considering it has 4 usb ports which work fine with keyboards, mice and webcams.
I already have an Eclipse environemt set up which I use for Java/Android development but I've never dabbled with anything like this before.
I guess the steps required are something like this:
Locate source code for my particular Android version (Android 4.2.2, Kernel 3.3.0) - where do I do that? Do I need the entire source or can I just download and compile the module by itself?
Set up the cross compiler - is this a standard thing, or does it depend on my hardware? My chipset is an Allwinner A20 ARM Cortex-A7(Dual Core)
Compile the module.
So, have I got the steps right? If not, please correct me. If so.... how do I go about doing the above?

[Q] Compiling for/on Android

Hi,
I own a Galaxy Ace 2 running CyanogenMod, with the drivers/firmware from http://bcmon.blogspot.be/ I have working monitor mode/injection.
Included in the package are amongst other applications airodump-ng, aireplay-ng, ...
I wanted to be able to use mdk3 (http://homepages.tu-darmstadt.de/~p_larbig/wlan/) for testing purposes on my phone.
What is the easiest way to compile this (and in the future other) C applications for my phone?
1) Set up a cross-compiling toolchain for Android (Seems pretty difficult, need to re-write Makefiles,...)
2) Compile it on the phone itself (I saw you can chroot ubuntu on Android, so maybe compile it there, and copy the binaries over?)
3) Another way?
Thanks!
I also want one But I don't know how to compile

Need a head start in understanding RootKit

I rooted my Xperia - L successfully using the RootKit method. But, I am not happy with myself in the sense that just by going through the code, I did not really understand how the developer exploited CVE 2013-6282 bug to achieve root. I don't have any prior experience in Linux kernel development. As a side note, I could set up NDK and recompile the exploit successfully for ARM platform. Please guide me with appropriate pointers so that I can understand the code completely. What information do I need to have? Where should I start? Do I need to have driver development on *NIX?

[Q] How do I upgrade a device tree and kernel for Lollipop?

I know it's not as simple as it looks, otherwise everybody could do it, but at least can someone point me in a vague direction?
Just out of interest, how do you upgrade a device tree to support newer Android versions? Anything in particular which might prevent Android from functioning correctly?
I've acknowledged SELinux as a problem already.
I'm new to running device trees and kernels but I do know my way around Linux (I know how toolchains works, and I can build Android and kernels, for example) and I know C++, C and Java.
I've 'Google-d' the matter, but to no avail – there appears no clear way to do it.
+1 this question
i want its answer too:good:

How can a developer port LineageOS to an unsupported device?

My question is really simple: How can I make an unofficial port of LineageOS? I've read this, which is based on an article from the (now death) CM Wiki, but some files (e.g. the mkvendor.sh script) are in older CM repos/branches. According to what I've read, there's not a full guide explaining the porting process since every device has its own tweaks (I imagine that it's due to ARM's nature)
What I want to do: Port LineageOS (the latest version) to the Samsung Galaxy Ace 4 Neo SM-G136ML (codenamed vivalto3mve3gltn). However there's not a LOS port at the latest version for a similar device which I could fork, so this would be "from scratch" in some way. I've seen Lineage's android repository at github but idk what are those xml files (they are definitively not the source code of a whole OS) EDIT: I realized that I had to clone it with `repo init`
What I've done so far: Documented myself as much as I could, read about how to get the vendor files, firmwares, kernel sources (in fact I requested the kernel source code for the device to the vendor), build.prop, recovery.fstab, and recovery/boot images.
My skills: I have a lot of experience with the GNU/Linux OS and I know some Linux kernel hacking, in fact I'm used to compile kernels for the x86_64, i686 and armv7h arch'es (not the vanilla kernel itself, but the Linux-libre kernel, which is basically vanilla but without binary blobs) and also patch them, and test them, etc. Besides kernel-stuff, I know shell scripting, advanced use of git (git clone, commit, add, push, remote, fetch, diff, apply, and more), use Heimdall, install custom recoveries and ROMs, and some advanced (non-noob ) Android hacking (Idk Java, C nor C++, however)
I know that here at XDA we've very talented developers who have experience with this, and much more. The only thing I need is some guidance to help me in my way to contribute the FLOSS community, I say this because when I asked in the LineageOS IRC channel if there was an official or well documented and updated guide, step-by-step, tutorial to port LOS that I could follow, someone answered me "it's impossible to have something like this", but I believe that there's ppl here who can demonstrate me the opposite
Thanks in advance
(...) I requested the kernel source code for the device to the vendor
Click to expand...
Click to collapse
Here it is https://gitlab.com/Megver83/android_kernel_samsung_vivalto3mve3gltn

Categories

Resources