My selinux status got enforcing instead of permissive - X Style (Pure) Q&A, Help & Troubleshooting

I searched lots of things to make it permissive...
I did this things
1)
/etc/init.d directory, create a file and rename it as 08setperm
2)
Added lines on that file
#!/system/sh
setenforce 0
It did work but when i tried rebooting it didn't...
Im using cm14.1 official..
I can't wipe anything because my storage is full
Twrp doesn't give me permission to do that and says selinux not premssive...
How to do it then?? I want it permanently not for temp purpose

Have you tried SELinux Mode Changer app? http://forum.xda-developers.com/showthread.php?t=2524485

acejavelin said:
Have you tried SELinux Mode Changer app? http://forum.xda-developers.com/showthread.php?t=2524485
Click to expand...
Click to collapse
But that's for temp use bro...
I can't add exposed....

Sagar_1401 said:
But that's for temp use bro...
I can't add exposed....
Click to expand...
Click to collapse
Yes you can. Set it where when the phone boots it notifs you that its changed to permissive. I've used it on LP, MM, and now 7.1. I've used it with Xposed and Viper just fine

Related

[GUIDE] RIL on Vanir/FXP CM12

Hello everyone!
Making another guide, this time on how to fix RIL on CM12 based roms e.g. Vanir and FXP.
The cause of the problem is once again SELinux and the fix is rather simple... let's go!
Before we start there is one crucial requirement! :
Do you have a SIM PIN set? If YES just continue reading. If NO, please set one BEFORE flashing a CM12 ROM.
We need to be able to set SELinux to permissive before the phone attempts to access the SIM card or it will not work! If you have a PIN set, your phone will not "try" to load it till you entered the PIN and that gives SELinux mode changer the time to change the mode! If you have no PIN set the phone will load the SIM card almost immediately and the app is not quick enough to set the mode to permissive before it loads the SIM! Users with no SIM PIN can try "method 2"
Steps:
METHOD1:
1: Install a build of your choice (Vanir/FXP, and no this fix is not for locked bootloader CM12 roms like RR, there is another fix for those roms!).
2: Once your device has booted up, turn off auto brightness to prevent your phone from rebooting while doing these steps. (your phone will soft-reboot once after disabling auto brightness)
3: Download and install SELinux mode changer from here: Google Play (or any other app that is able to set SELinux to permissive on boot.)
4: Open the app grant root access and check the "show notification" Checkbox.
5: Fully reboot your device and WAIT on the lockscreen till the app says that it changed the SELinux mode to permissive!!!
6: Enter your SIM PIN and you should be ready to go!
METHOD2:
1: Create a new script file in /system/su.d.
2: Put this inside of the file:
Code:
#!/system/bin/sh
echo 0 > /sys/fs/selinux/enforce
3: Set correct permissions.
4: Reboot
(this method was not comfirmed by me! And it might not work, can someone try it?)
Remaining bugs:
1: When you call someone or you get called, the sound will be glitchy!
2: Auto-brightness still does not work!
3: More?
The fix was found by : @AndreAkaNick
Method2 found by @jojos10
Enjoy CM12!,
Noahvt
credits to @AndreAkaNick
Gara91 said:
credits to @AndreAkaNick
Click to expand...
Click to collapse
I almost forgot, thank you
@noahvt
The call gets really bad? You can hear the person on the other side?
lvints said:
@noahvt
The call gets really bad? You can hear the person on the other side?
Click to expand...
Click to collapse
Let me try that for a sec. I'll report when I get back AKA when my phone boots up to FXP 24/02
what if I run su setenforce 0 in terminal and reboot? Do I still need to set SIM PIN then?
vvaklnprm said:
what if I run su setenforce 0 in terminal and reboot? Do I still need to set SIM PIN then?
Click to expand...
Click to collapse
I tried that and it doesn't work...
After reboot selinux returns to enforcing...
How to make permissive selinux with init.d script?
I'm too lazy to download selinux mode changer
Or you can use this init.d script:
Code:
#!/system/bin/sh
echo 0 > /sys/fs/selinux/enforce
Or if init.d doesn't work in your ROM (like current FXP-CM12), you can install SuperSU and put the script in /system/su.d directory.
This way, there is no need to worry about SIM PINs and whatnot.
jojos10 said:
Or you can use this init.d script:
Code:
#!/system/bin/sh
echo 0 > /sys/fs/selinux/enforce
Or if init.d doesn't work in your ROM (like current FXP-CM12), you can install SuperSU and put the script in /system/su.d directory.
This way, there is no need to worry about SIM PINs and whatnot.
Click to expand...
Click to collapse
could you please make a flashable zip?
also how to get rid of cyanogen recovery? cant install anything
2 not working....but wait...what name this file should have?RIL?RIL fix?
The second fix will not work if Google Now is activated.
I get an error that Google (Now) has a network error while my data and radio works.
dimitrakhs1 said:
2 not working....but wait...what name this file should have?RIL?RIL fix?
Click to expand...
Click to collapse
2 only works if you have flashed chainfire's supersu zip and you can choose any name you like for the .sh file
Sent from my Nexus 7 using XDA Free mobile app
Yeah,but it don't need it in this version,it's pre-rooted already(Resurrection v5.3.6).You suggest flashing this anyway?
dimitrakhs1 said:
Yeah,but it don't need it in this version,it's pre-rooted already(Resurrection v5.3.6).You suggest flashing this anyway?
Click to expand...
Click to collapse
You can flash it if you want. I didn't flash it and now I'm using SELinux Mode Changer.
I have tried the 1st method
It works also on RR 5.3.6 #1 build by Furrydaus
jojos10 said:
Or you can use this init.d script:
Code:
#!/system/bin/sh
echo 0 > /sys/fs/selinux/enforce
Or if init.d doesn't work in your ROM (like current FXP-CM12), you can install SuperSU and put the script in /system/su.d directory.
This way, there is no need to worry about SIM PINs and whatnot.
Click to expand...
Click to collapse
I kept trying with FXP CM12 9th Feb , did all the above but RIL still not working.
edit - copied accidentally with a space behind the sh on the first line, hence wasn;t working. Everything works!
does not able to set 3g .. on latest vanir
hey im using latest vanir ... 5.0.2 022715 .. and tried the first method .. set a sim pin .. and it works but when i turn on data ... and set to 3g .. it reboot(screen fade out slowly ) and now when it reboot and again asked for the pin .. and i entered my pin then again it reboots
-EDIT-
it works, accidentally had a space behind the first line of the script hence it didn't work.
Guys my apologies.
Tested again. Turns out the script is not activating no matter what was done - permission set correctly (RWX RX RX chmod755), SuperSU flashed and set on boot, script inside /system/su.d folder. SELinux status keeps being on enforcing.
where can I find the system / su.d
Sent from my Xperia SP using XDA Free mobile app

Possible to set SELinux to permissive on boot?

Hey all. I know we can use terminal editor to change the SELinux permissions but if we reboot it will have to be done again. Is there anyway to permanently set it to permissive on boot?
Yeah the app for that is here: https://f-droid.org/repository/browse/?fdid=com.mrbimc.selinux
In Samsung s7 edge not work
I apologize if it's the wrong post. But on my Samsung s7 edge I can not change the selinux to permissive. I tried in every way, selinuxmodechanger, init.d folder and terminal Android. Is there some other method?
Thank you

[GUIDE] [NOUGAT] Viper4Android

//Thank you all for 30k+ Views. You're amazing guys//
You want Android 8 with Viper4android to?
Thread created check my profile...
Hi,
at first im not responsible for anything that happens to your phone OK?
Fine Let's Start.
If you are on cm skip all until the cm section
Supported kernel list and known errors/bugs see second post
Step 1
- Flash full Factory Images.
- Install TWRP, remember you have to be decrypted.
Step 2
- Install Android 7 ROM by tupac4u / or any other rom / or leave stock
- Reboot //if nessesairy
Step 3
- Flash ElementalX's N Kernel.
- Flash Viper5.0_Stock.zip in Recovery / or any other viper
- Reboot.
Step 4
- Install driver.
- Open File Explorer and delete /system/vendor/etc/audio_effects.conf
- Reboot.
Step 5
- Set enforcing to permissive (You have to do it at every Reboot!).
- In Viper open Menu->FX-CompatibleMode->yes // you can try without, it may work
- Enjoy Viper.
CM Section
1. Flash arise sound mod ( link down below )
2. And IMPORTANT flash super su
3. Disable audio fx and reboot
SPOTIFY FIX
1. Download that file
https://drive.google.com/file/d/0BxyY1q0qeeeEeUFGT3JHeDZLZkE/view
2. Place it under /system/etc
3. Reboot
PURE NEXUS ONLY WORKS WITH BUILD 10/25!!!
If it worked leave a reply.
Alternative Download link for ARISE Viper here:
http://forum.xda-developers.com/android/software/r-s-e-sound-systems-auditory-research-t3379709
Unsupported Rom/Kernel
Kernel:
- Stock
- Jolla
ROM:
F.A.Q.
Q: Spotify isn't working with that
A: Force enable Viper4Android and turn FX Mode to compatible. Then restart both applications.
Q: Why ElementalX Kernel?
A: That's the only Kernel who works with Viper except Stock kernel. Elite Kernel may also work but it hasent been updated since the Dev Previews.
Q: Is that also working with the stock rom?
A: Yup. Also works with (nearly) any stock based ROM.
Is there a definite way of checking if it's working? Not by sound?
Yes, just check driver status in viper when something is playing in the background. If it says 'processing', then it's working.
Btw, why would I need custom kernel for viper?
Sent from my Nexus 5X using Tapatalk
how to set permissive mode permanently?
Nightshadow931 said:
Yes, just check driver status in viper when something is playing in the background. If it says 'processing', then it's working.
Btw, why would I need custom kernel for viper?
Click to expand...
Click to collapse
I found that it isn't working on jolla Kernel and Stock.
Did you enable viper in app itself?
Not sure, but maybe you need to enable it on order to see 'processing'..
Did the installation of driver went well?
Sent from my Nexus 5X using Tapatalk
enzippo said:
how to set permissive mode permanently?
Click to expand...
Click to collapse
use a file exlorer with root privileges like es or root explorer and go to /etc/init.d directory, create a file and named "08setperm" (without quotes) and add the below lines in the file and save it..
#!/system/sh
setenforce 0
And give full permission (rwxrwxrwx)
reboot and you should be good. if for some reason your init.d script doesn't launch then download and install universal init.d tool and enable it.
Nice that someone is trying to get Viper4Android to work on Nexus 5x with Android 7.0 (Nougat). Sadly it does not work, tried your way but it does not enable me to get Viper4Android to work in Spotify.
Selinux is in permissive, your viber4android package is in place, audio_effects.conf removed, Android 7 by tupac4u installed and complete factory image installation before all this. No go..
Viper4android driver status does not complain but processing is always "no".
Try some other app like play music, v4a won't work on all apps if they have their own equalizer.
Sent from my Nexus 5X using Tapatalk
Blinkiz said:
Nice that someone is trying to get Viper4Android to work on Nexus 5x with Android 7.0 (Nougat). Sadly it does not work, tried your way but it does not enable me to get Viper4Android to work in Spotify.
Selinux is in permissive, your viber4android package is in place, audio_effects.conf removed, Android 7 by tupac4u installed and complete factory image installation before all this. No go..
Viper4android driver status does not complain but processing is always "no".
Click to expand...
Click to collapse
For those who want to use Viper4android with Spotify change fx compatible Mode to compatible in Viper settings. Then Open Spotify and go to Settings->Equalizer that should bring up Viper. Select Force enable and close Viper and Spotify. Open up both again and Boom Viper is there.
How find Android 7 by tupac4u ??
EDIT.
I found him already
Did someone get it working with stock rooted ROM?
noidea24 said:
use a file exlorer with root privileges like es or root explorer and go to /etc/init.d directory, create a file and named "08setperm" (without quotes) and add the below lines in the file and save it..
#!/system/sh
setenforce 0
And give full permission (rwxrwxrwx)
reboot and you should be good. if for some reason your init.d script doesn't launch then download and install universal init.d tool and enable it.
Click to expand...
Click to collapse
Idk if this will work on the new version, but this zip I've attached here sets the previous ElementalX-N5x-1.17 kernel permissive permanently. I'm not on nougat yet, waiting for Xposed.
trhacker01 said:
Idk if this will work on the new version, but this zip I've attached here sets the previous ElementalX-N5x-1.17 kernel permissive permanently. I'm not on nougat yet, waiting for Xposed.
Click to expand...
Click to collapse
In gonna give it a try
Nightshadow931 said:
Did someone get it working with stock rooted ROM?
Click to expand...
Click to collapse
Me not
Thargorsson said:
In gonna give it a try
Click to expand...
Click to collapse
Nope it don't works
Thargorsson said:
Nope it don't works
Click to expand...
Click to collapse
thats how im running right now, just checked. only with the universal init.d though
noidea24 said:
thats how im running right now, just checked. only with the universal init.d though
Click to expand...
Click to collapse
Ur saying that permissive zip works with the universal init.d?
trhacker01 said:
Ur saying that permissive zip works with the universal init.d?
Click to expand...
Click to collapse
As long as the zip creates/places a file in the init.d to change selinux then i guess it should work

Delete

Delete
Craz Basics said:
When I try to install v4a it gives me this error. I have it installed in system/xbin, and have tried all the other places as well. I'm on nougat and have SELinux set to permissive.
Click to expand...
Click to collapse
Have you tried to change this?
in superSu settings, uncheck the namespace and reboot.
After that install the driver for Viper.
mashardpro said:
Have you tried to change this?
in superSu settings, uncheck the namespace and reboot.
After that install the driver for Viper.
Click to expand...
Click to collapse
Ahh! That makes sense. Thanks a ton
Edit: it worked

xposed framework for huawei p10 lite?

Recently it has come out xposed framework by rovo89 for android N:
https://forum.xda-developers.com/showthread.php?t=3034811
Has anyone tried it on the p10 lite, with rom stock + recovery + root? or in some other device huawei with rom stock and emui 6?
Thanks in advance.
I've tried it and it works fine, but since I rooted my p10 and installed xposed my battery started to drain noticeably faster, so I went back to stock.
I use xposed with magisk v14 and no battery drain(I think)
Testing and work fine.
Some times, after reboot, xposed in disabled. Need run this attached script on init, in /su/su.d
mpiero11 said:
Testing and work fine.
Some times, after reboot, xposed in disabled. Need run this attached script on init, in /su/du.d
Click to expand...
Click to collapse
I get this too, but to fix I just untick all enabled modules in xposed, reboot, enable modules again and reboot again.
hayabusa2yk said:
I use xposed with magisk v14 and no battery drain(I think)
Click to expand...
Click to collapse
How did you install magisk?
plerohero said:
How did you install magisk?
Click to expand...
Click to collapse
Just flash in TWRP
sorry for my bad English
mpiero11 said:
Testing and work fine.
Some times, after reboot, xposed in disabled. Need run this attached script on init, in /su/su.d
Click to expand...
Click to collapse
I am facing the same problem and when I tried to use your solution its not working either.
I somehow able to found out the error (by using init.d scripts app):
Path is not correct for
/data/user_de/0/de.robv.android.xposed.installer/conf/enabled.modules.list
/data/user_de/0/de.robv.android.xposed.installer/conf/modules.list
On checking the path appears to be correct. Then whats the issue here? Please guide.
My P10-Lite is rooted. So I can see the path actually exists in my phone's root folder.
Thanks
mzeeshan2 said:
I am facing the same problem and when I tried to use your solution its not working either.
I somehow able to found out the error (by using init.d scripts app):
Path is not correct for
/data/user_de/0/de.robv.android.xposed.installer/conf/enabled.modules.list
/data/user_de/0/de.robv.android.xposed.installer/conf/modules.list
On checking the path appears to be correct. Then whats the issue here? Please guide.
My P10-Lite is rooted. So I can see the path actually exists in my phone's root folder.
Thanks
Click to expand...
Click to collapse
Change permisions for .sh file, chmod 777 to script, reboot and enjoy.
No problems for my.

Categories

Resources