yashsingh1/xdaforums huggingface dataset:
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
All right, folks. I have promised I would show you an example of Lineage roms showing security patches implemented in the beginning of the month, but actually merged weeks and sometimes months later. Let's see:

Here is Google security patch CVE-2016-6699. It was published in November 2016 bulletin. https://source.android.com/security/bulletin/2016-11-01 It is the first one entitled 'Remote code execution vulnerability in Mediaserver". If you click on it you will see the description: 'Fix free-after-use for MediaHTTP' It was implemented by Google in September, but it wasn't available until November bulletin was published about November 3.

And here is the actual Lineage commit: https://github.com/LineageOS/android_frameworks_av/commits/cm-14.1/media/libstagefright/http/MediaHTTP.cpp It is the first one on top. It also says 'Fix free-after-use for MediaHTTP'. Now, look at the dates. What does it say? Yeah, you have 2 dates: one showing that it was implemented by Google on September 13 and another November 17, when it was actually merged by Lineage.

So, if you were to compile a Lineage rom on let's say November 7, your info in 'about phone' would say 'Android security patch level November 5', but this commit wouldn't be implemented. That's what I was talking about. Sometimes they do it quickly, sometimes weeks later and sometimes months later.

It is not a big deal, but it misleads the user into thinking he has all security patches, while in reality he doesn't. I don't want that in my rom. This is why I don't sync the platform_build directory and instead change the patch date manually only after all security patches have been implemented.

I got a lot of angry feedback including from a few moderators, although they were not moderating at the time, saying I didn't have a clue. One of them claimed he had never heard someone manually changing security patch date. But of course! If you compile an unofficial rom, you got no problem with syncing. If you forked a rom, changed a wall paper, a few icons and call it Mango, you also won't have any problems syncing. However, if you start with vanilla Android or Slim (that is virtually vanilla Android with extra virtual button options), as it was in my case, you actually change 100s and 1000s of files to implement various features. After that the rom becomes virtually unsyncable with either Android source or Slim source. Yeah, you can try, but you will have so many conflicts to resolve that it would be easier just to manually implement security patches.

So, to uninvited huligans: before opening your mouth and spewing insults, know what you are talking about, because otherwise it is you, who in the end turn out to be the clueless ones...

Peace...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Danny94:
Does it exist the possibility lenovo will puplish the firmware open source ?
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
They never do that: Patents/Comptetition. Qualcomm says No way...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] sykopompos:
Actually if you built it on the 7th it would say the previous month still because it wasn't merged into build till the 8th

https://github.com/LineageOS/android_build/commit/c2de06e7249e4d618664546db7c86aac4c0c4771

Also, you are looking at the rebase repos, it was merged into the prerebase repo on the 10th

https://github.com/LineageOS/android_frameworks_av/commit/c3c767dc294e092317113247276c29908afb0758

The same day as official nightlies started http://tech.firstpost.com/news-anal...rt-rolling-out-for-select-devices-346570.html
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
Encryption

Good news: Keyboard shows up when encrypted!

However, when I enter the password, it tells me the password is correct, but data is corrupted. Now, I have to revert 50-100 commits that I have implemented trying to fix this. :)
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] the.D:
Great to hear! Message me if you ever need any testing.
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] blankingblank:
Hey Optimum,

Thanks for agreeing to take a peek at my log. It ended up being quite large so I compressed it... Sorry if that's not standard, I've never pulled a logcat before.

BTW, only change I made it kernel adiutor was reducing CPU max frequencies to factory settings
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
Are you on the latest release? Anyway, the errors in art are the leftovers of my changes related to encryption. This is going to be reverted very soon. I think it will take just a few days to finish encryption and I will post a new release...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] blankingblank:
Still on r7
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
Go to 9 dirty. I don't think you will have any of those problems...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Knoth:
[MENTION=5075064]optimumpro[/MENTION], think about compiling with Qualcomm LLVM
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Eltorito94:
[MENTION=5075064]optimumpro[/MENTION] i have installed your rom (the 9.2 plus open gapps aroma, clean install) and i can't tap on every app in drawer (stock launcher).. any solutions?
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] blankingblank:
What about 03 flag? You recommended clean flash no?
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
You can try dirty.

Change gapps.

Sdlang is already used...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Eltorito94:
Not change anymore.. when i change dpi in display settings i can't tap on every app in drawer
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] singhvishvendra:
I was checking aex rom thread of davidevinavil

One guy is saying that encryption is working fine

But keyboard coming after 30-40 minutes

May be discussion with davidevinavil resolve this problem so i posted here
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
If you encrypt your phone now, that's what you will get. That's what is called encryption is not working: no one can wait 40 minutes on every reboot plus the phone reboots 10 times during that time. But I have already resolved that. The only remaining issue is to return to vanilla behaviour, which I had heavily modified to try to fix encryption.
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
All right. Done. Encryption is fully working. See attached
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] benplay64:
Congratulation. Do you know if it is specific to the Indian firmware that you shared before?
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
Probably not. So, you should be able to encrypt with Chinese firmware...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] singhvishvendra:
Appreciate your hard work

You are the only one for zuk z2 who is fixing problem step wise ...i really like your work and knowledge.

:good::good:
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
And encryption also works with Magisk. You can even encrypt with Magisk installed, however, after booting, you will loose root, so, you'll have to sideload Magisk in TWRP, then you'll have root.

Can someone link Fedor's TWRP that is able to decrypt?
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] singhvishvendra:
With this fedor twrp encryption worked for one guy in du...i think you are talking about this

https://yadi.sk/d/JWaxwHrj34c6RJ
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
This one can't decrypt...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] the.D:
Despite what was said on github I was never able to decrypt using that version of TWRP. The latest official TWRP worked for me.

Edit: I should have replied quicker.
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Preetam286:
Wow! Congratulations.
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
You mean official TWRP is able to decrypt?
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] the.D:
Yes
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
I am going to try, but my TWRP is built with official sources...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
Yes. Official TWRP does decrypt successfully. That means we are all set. Now Z2 plus can be officially encrypted/decrypted...

Edit: I had to revert about 100 commits and downgrade to 128 bit encryption instead of 256, but the magic was on the surface, as it often happens. David or Varatone: they are the knotty boys who screwed encryption. :) Nonetheless, both are great developers...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] the.D:
Edit: I demand the ability to hide the statusbar on homescreen for making us wait this long ;)
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
Status bar is a major part of android. I don't think it would be easy to have it disappeared. Plus, is it really a necessary feature? Z2 has a pretty sizeable screen...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Knoth:
adb shell settings put global policy_control immersive.status=org.launcher3.es (for example)
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
I don't think immersive.status would do the trick. Status bar is a permanent fixture...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Knoth:
Yes, but he has asked to hide statusbar in homescreen (launcher).

This command works with apps, I've tried it myself
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
XDA is having problems with upload. So, I will post the new release later...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
Yeah, but it might stop showing all kinds of notifications...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] the.D:
It's useful for those that use live wallpapers.
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Knoth:
Oh, yeah.

I remember you said that CaptivePortal commands integrated them into Settings or something, right? Say you still do not apply these commands, because I need to manually put them so that the "x" does not appear in WiFi icon statusbar.
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
Have you deleted Captiveportal.apk? Because it is possible that it resets global settings for itself each time. You can also put the commands into Afwall, if you use it. Just omit the word adb. This way it will apply the commands each time you switch between wifi and mobile...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Knoth:
I will try to remove CaptivePortal in your next release. I'll do a dirty installation, I guess there will be no problem with encryption.
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Euphyse:
Love your work on the Jaguar rom but I cannot use it as a daily driver because I always have a large miscellaneous battery drain. Back when I clean flashed the May 10th release and now the June 16th release. Now the misc. drain isn't as bad on the latest build but Jaguar doesn't last as long as the other roms by a large margin. I'm not sure what's causing it either, on every rom I use the impulse cpu governor and powersave gpu as I don't play games. Basically I just use my phone for web browsing and every once in a while I will get a call or message.
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
You are doing something wrong. Trust me. I have tried other roms. Jaguar's battery lasts longer. You can take a look at one of my posts in this thread showing 4+ hours of SOT and 53% of battery still left with wifi/data/email 24/7 and about 4 hours of web browsing.

Don't use darkmoon kernel for obvious reasons. Don't use greenify, as it actually drains battery more than when it is absent. In kerneadiutor untick all 'apply on boot' and reboot to let default values load. Stay with interactive governor. I use kernel adiutor for vibration and cpu frequencies only. If you have a battery drain, that's one or more of your apps.

If you don't believe me, ask other users...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Euphyse:
Thanks for the reply, I don't use the darkmoon kernel on this rom but I do use greenify I'll get rid of that and see if the misc drain disappears.
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
Misc drain won't disappear, as this is the difference between actual and estimated battery drain. You might have it large enough that it shows up, if you jump from rom to rom and system doesn't have the time (4-5 charging cycles) to adjust.
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
Could anyone tell me how many settings (and list them) you have in Settings/More/Tethering & portable hotspot?
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Euphyse:
I noticed that the drain usually happens when I stop using my phone for a extended period of time. Like a couple hours and the drain isn't very large but if I leave my phone there while I sleep the drain is really bad. Does this mean that it's one of my apps? If so I'll just do a clean install without titanium backup.

---------- Post added at 15:53 ---------- Previous post was at 15:47 ----------

I have four settings:

USB tethering

Portable Wi-Fi hotspot

Set up Wi-Fi hotspot (AndroidAP WPA2 PSK portable Wi-Fi hotspot)

Bluetooth tethering
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] the.D:
Exactly what I needed. Package name is com.slim.slimlauncher for those that are interested.
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
Rom updated

Release 10 with fully working encryption decryptable via official TWRP is live. See download and description in post #3.
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Knoth:
For dirt update, wipe system only, right? or too cache?
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
For dirty update, don't wipe anything. System is wiped automatically each time...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Knoth:
You should update #1. Remove 256bits, ZUK Module etc ...: D
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Fabio B:
Thanks for the fully working encryption/decryption feature!!!!
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Knoth:
[MENTION=5075064]optimumpro[/MENTION] Is it normal that even making the installation completely clean, keep the encryption of the previous installation? (I keep asking myself the password to decrypt, after wipe system-data-internal-cache)
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
Yes. You only encrypt once. The only way to get rid of encryption is doing Format and Factory reset in TWRP, when you are prompted to enter 'Yes'. Just make sure not to use any other TWRP...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Knoth:
I dont understand "when you are prompted to enter 'Yes'" I wipe all (and Factory Reset) in TWRP and the encryption not rid :D
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
If you press wipe and then the button on the right that says 'Format data', you will get a prompt to enter 'Yes' and that gets rid of encryption and all data you have including SD card. But if you go to Advanced on the left, you can wipe everything, but not encryption...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Knoth:
[MENTION=5075064]optimumpro[/MENTION] There is some kind of bug with Webview, because Lightning Browser / Privacy Browser (uses webview to function) crash when starting. With r9.2 it did not happen.
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Magz Heaven:
Up this on afh pls

El Psy Congroo
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] vigilante7373:
I really don't understand what is going on... Google services keep crashing. I clean flashed release 10, flashed gapps (opengapps, pico), rebooted, flashed magisk (12). It didn't help. Then I clean flashed ROM and gapps again and rebooted, tried to open the play store and it crashes again! I didn't even flash magisk. Is release 10 even supposed to be clean flashed?
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] 110errm:
K9mail crashes permanently. Standard mail crashes in setup. Since r10 with encryption. Encryption works. Thx
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] capoooro:
O.k, I'm not alone; I have FC in some Google apps and Amazon app after installing V10. I tried to reinstall them but nothing. Obviously ROM+gapps and reboot. Lukly I restored v 9.1. I tried dirty flash.

I'll try a clean flash, by the way do you think there be a solution?

List of crashing apps:

Google search

Google mail

Google opinion reward

Amazon app

All the others seems to work without troubles

Your ROM is really good and your work is amazing

Tnx

Inviato dal mio Z2 Plus utilizzando Tapatalk
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] vigilante7373:
Yes, that's why I did a clean flash - because gmail stopped working and reinstalling didn't help.
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] capoooro:
Does a clean flash is the solution? I've read that you had problems with playstore after the clean flash.

Tnx

Inviato dal mio Z2 Plus utilizzando Tapatalk
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] vigilante7373:
No, a clean flash didn't help. I had to go back to 9.2.
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] rauld28:
Did u check the permissions in the setting->apps?

I had similar problems and has some weird permissions on gapps.

Also what version of gapps did you use and where did you take it from? I tried (in 9.1) with http://opengapps.org/ ARM64-7.1-mini, latest version from current month and i have no problems.
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
Why don't you, guys, check if you have webview in system/app? I might have accidentally deleted it. If that's the case, just get it from apkmirror and install: http://www.apkmirror.com/apk/google-inc/android-system-webview/android-system-webview-59-0-3071-92-release/android-system-webview-59-0-3071-92-2-android-apk-download/
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] rauld28:
I have a problem (in 9.1 and 8.0) with bluetooth. I listen to music form soundcloud and if i answer a call i can't switch sound to handset or if i use the bluetooth headset the phone does a quick restart after 10-20 seconds of talking. After which i can't connect my bluetooth headset. Only after a full restart i can reconnect the bluetooth and liste to music.

Did anyone else experiences this or can reproduce it? Any solutions or ideas about this?

Thanks!
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] 110errm:
Checked. Webview is installed. Thx
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Doe.it:
Good job!!! I tested the encryption and it works pretty well.

Finally we have a custom ROM with full encryption working.

Can you share the kernel solution?

Thanks a lot anyway. We are really grateful for your effort. :good::good::good:
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
My K9mail works fine.
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
It is not in kernel. I will share it soon...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
The issue does sound like a webview problem. Could someone try to use google webview I linked and report? I have been using Google webview instead of android webview for a while and I always delete stock webview.

Although, I don't use Gapps, K9mail and Silence messenger would crash without webview and they don't...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] 110errm:
After installing linked webview k9mail works again. No crashes in other apps. Great. Thx
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
Good. I take changes directly from android gerrit master branch. So apparently older android webview releases no longer work.I'll put the link into post #3...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
So, it is confirmed installing the latest stable Google webview v59 arm64 resolves any issues with web browsers/messengers/emails and any other app that relies on webview. After installing you can delete /system/app/webview...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Knoth:
I am glad to hear that. But AOSP version is preferable.

Edit: Delete CaptivePortalLogin not change anything :)
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
No, it is not. AOSP webview is no longer built from source in the rom, it is prebuilt anyway, the same way as Google webview. And AOSP version is much older...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Knoth:
Are you saying that the AOSP project no longer supports a "no-google" version of Webview?
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
They do, but starting from mm, the sources are not included with the rom, meaning you can't build it...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Knoth:
but you can take the sources and integrate in the rom. I think that as much as possible it is best to have all the "AOSP" possible.
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
Google has removed every build script and it might not even be possible to recreate. Plus, this will increase build time twice. What everybody does is take prebuilt from AOSP and it is always 2 numbers behind Google.
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Knoth:
I get it. And do you know any place where AOSP binaries are uploaded? (Although there are two versions underneath I do not think anything happens. The problem is that in this case -your-rom- it is version v52 and it is from 2016) ;)
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
You might be able to get it from chromium website, but I don't think they have it as an installable apk. Rather, they have it for putting in /system/webview, which may not even be signed, which means you can't use it. But do look and see...
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] capoooro:
I confirm it works now, no force close,

Tnx Master

P.s. installed in 9.2 before dirty flash v10

Inviato dal mio Z2 Plus utilizzando Tapatalk
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] alexon.cunha:
I've waited so long for this release! Since R7 I Think!

Will check tomorrow!

Thanks Optimum!
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] Shubhi singhal:
hello i just order my zuk z2 previosly m using zuk z1

can someone tell me all the steps to setup device after flashing this rom..because i don't know about magisk because i use supersu and nuclear rom in my zuk z1...........also i dont know about Afwall. ......If i update my device to official naugat and then flash this rom ...then did i have to flash any firmware or not ?

And is this rom is best for me or not

sorry for so many ques and A big THANKS in advance
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] vigilante7373:
after you get your new phone update it to the latest official firmware, unlock bootloader, flash twrp and then flash this ROM folowing the instructions on the frontpage.

after that you can tell us if this is the best rom for you :)))

magisk works the same way as supersu, only it has a bit more features. you download a zip and flash it the same way as you would flash supersu. only you have to install the app called "magisk manager" afterwards and that's it.
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] hp5942:
[MENTION=8229569]vigilante7373[/MENTION] already told you everything but I would like to add one more thing that after unlocking and before flashing this rom, reboot to original stock rom and enable voLTE, otherwise you will face volte issues. On initial setup, internet will not work so just skip the setup and then install afwall (app in thread) and enable it. Internet will work only after enabling afwall. Enable the apps that you think should need internet in afwall and only the apps enabled in afwall will get internet.
[Lenovo ZUK Z2 (Plus) ROMs, Kernels, Recoveries, & ] optimumpro:
Next project will be to fix offline charging. I bet it is similar to encryption solution...