yashsingh1/xdaforums huggingface dataset:
[Magisk] IlyaKol:
That was me :). I just tried what one of the other folks suggested and removed and files or APKs, etc. that had magisk or root in the name and no bueno. Company Portal still knows.

This kinda sucks...I rely heavily on this to work. Might have to unroot but I dread the day I won't have a Titanium backup to fall back on when my phone dies and I need to reset everything up from scratch.
[Magisk] }{Alienz}{:
Same issue...update from March 12 breaks it.

Any workarounds?
[Magisk] IlyaKol:
I'm trying to downgrade to the previous version (V5.0.5067.0) and so far it isn't complaining about root but can't seem to finish getting my companies policy.
[Magisk] IlyaKol:
Can confirm that downgrading resolved my issue. It was stuck on scanning for a new policy but I gave up and hit back and it no longer had a red exclamation point. Went to outlook, added my work email and bob was my uncle :).
[Magisk] }{Alienz}{:
You only downgraded intune to V5.0.5067.0?
[Magisk] }{Alienz}{:
Can confirm, downgrade to Intune Company Portal V5.0.5067.0 to fix this.

It can be found here: https://apkfab.com/intune-company-portal/com.microsoft.windowsintune.companyportal

Use Magisk to hide all of Intune's activities.

Outlook (or other apps) can stay on the latest version.

Make sure to tick off automatic updates in the market.

I don't know for how long this will continue to work. I've made a ticket to the developer of Magisk on Github in the meantime
[Magisk] kb8no:
@}{Alienz}{ Thank you for this! I only discovered your post this week. It has been working great on Moto X Pure 18.1 LOS. So far it is still working for me but I never open InTune Company Portal so I don't know what the version of what I have installed. I disabled update anyway. Do you think this problem is device specific or will it eventually reach every updated app?
[Magisk] IlyaKol:
Good call on the GitHub ticket.

For anyone reading, this is the process I followed:

1) Uninstall the existing Intune Company Portal

2) Reboot

3) Install the APK listed above or from another source (I used APK Pure). DO NOT LAUNCH INTUNE!

4) Before launching, go into Magisk and make sure to hide ALL of it as well as all of Outlook, OneNote, OneDrive, Teams, etc. (whatever uses your company credentails)

5) Launch InTune and set it up.

6) Disable auto-updates of the app as he stated in Google Play Store.

7) Profit.
[Magisk] IlyaKol:
This is not device specific to my knowledge, it is version specific for the app.
[Magisk] frov:
Hmmm, also here suddenly it stopped working, as I also recently update Portal. But I also have backups with Swift Backup: so I restored into version V5.0.5067.0. I also cleared all cache and storage of related apps Teams & Outlook. I had to re-add the Portal and all its sub-things to Magisk Hide. Logged in ok. Then it all started to work again, also for me.
[Magisk] frov:
Intune Company Portal breaks Magiskhide · Issue #4026 · topjohnwu/Magisk

Magiskhide no longer works with latest Company Portal Intune app. Not working: Company Portal Intune 5.0.5084.0 Working: Company Portal Intune 5.0.5067.0 Latest Magisk 22 on both and no other chang...

github.com

But this issue was also closed quickly on github: I wonder, does that mean a solution in magisk is nearby?
[Magisk] greg_the_lazy:
WORKS! Puuuurefect! :D
[Magisk] jbug187:
This worked well for me. Thanks for sharing the fix.
[Magisk] BrimoFan123:
Confirmed - it works.

My procedure:

- uninstalled Intune

- Rebooted

- Restored Intune version 5.0.5067 by Titanum Backup

- Selected all components of Intune in Magisk hide

- Outlook & Teams works
[Magisk] IFireflyl:
This did not work on my Note 20 Ultra 5G (Snapdragon). Intune is still saying my device is rooted using Intune Company Portal V5.0.5059.0 or Intune Company Portal V5.0.5067.0. MagiskHide shows all of my apps except for root 6 root apps are hidden, including Company Portal, Office, OneDrive, Outlook, and Teams. Every time it gets to Finishing Setting Up Device, and then it hangs. After a few minutes it says, "Couldn't add your device. You can try again or send the error information to your company support in an email."
[Magisk] IlyaKol:
Hmm...interesting. You're the first one out of like 10 confirmations here and on Reddit that it didn't work for.
[Magisk] IFireflyl:
I might actually be an idiot. I found this when I was trying to get Intune to work, and I didn't realize that this requires a Magisk module. I'm using the latest Magisk Manager and Magisk, but I'm not seeing this Intune Hider module. Is this something you are using? I feel stupid that I'm not finding this option inside of Magisk Manager. I have only been using MagiskHide to hide Intune and the Office applications.
[Magisk] IlyaKol:
Yes, I did install the module but I do not see it in my Magisk modules list...I think it's a 'one-time' thing. You have to download it from the OP. Otherwise someone will have to share it with you.
[Magisk] IFireflyl:
Either I'm completely missing it, or it's not in the OP anymore. The author seems to have done a strike-through on almost everything in the first post.

Does anyone know where I can get the module for this?
[Magisk] kb8no:
It is easy to be confused. The "module" from the OP was needed before but is now obsolete since Magisk has gained the necessary functionality alone without the "module". There is no "module" in Magisk. Now go back and read the past posts over 2 months. First you hide Magisk so it passes safety net. Then you go into superuser MagiskHide, go into the app (eg Portal) and check everything. You need to understand that they updated Portal so you need to downgrade it so Portal will work again. You need to understand to use latest Magisk and Magisk changed. Not surprising you are confused. Now perhaps you have figured out the basics and the details will make sense.
[Magisk] IlyaKol:
Good clarification. I guess my running the module didn't do anything (I didn't know that background on the functionality). Firefly, I have it on my Google Drive but it sounds like there is no need for it.
[Magisk] niveaj:
Confirming the steps also worked for me - thank you!

If you're still struggling to get it to work, make sure you're not making either of the same mistakes I was (despite the very clear instructions here):

1. Make sure you're downloading the right version of the Intune .apk (some of the links posted won't take you directly to the right version).

2. When people say to hide ALL the components of Intune using Magisk hide, that means that you need to click on Intune in Magisk hide to expand the list of sub-components and make sure they are all hidden as well.

Thanks again for these steps!
[Magisk] kb8no:
The previous apkpure link in this thread for Intune Company Portal V5.0.5067.0 needed to downgrade from the current V5.0.5059.0 was a link to the latest version. When the link was placed it linked to V5.0.5067.0 but after the Portal was upgraded it now points to V5.0.5059.0 so no longer gives you what you need. Here is a link to the legacy version that we need. apkpure link

I think this forum should be closed and a new forum started because this forum OP discusses the "module" which is now obsolete and the forum has changed topic. That would eliminate much of the confusion generated by the evolution of the topic away from the OP.
[Magisk] SirVilhelm:
This worked for me!
[Magisk] Jirachilover:
I'm an idiot I didn't check everything in magisk hide. Passing now
[Magisk] andylcm:
I try

I follow this instruction and this works only after I open the outlook. I can see my email, but about 30 seconds later, my outlook was being kicked out and and it show red on "Device is healthy".. I try several times, it can works...less than 30 seconds only.
[Magisk] kb8no:
If you do nothing then Outlook (or other apps) will appear to work briefly. Then InTune takes a short time when it appears to work and then blocks it. This is usual and means it is not working at all.

I believe you are not following the directions correctly. Does Magisk pass SaftyNet? Did you completely delete InTune and then downgrade? Did you leave InTune alone and not open it before configuring Magisk? Did you check every box in Magisk for Intune (common mistake)? Try clearing Outlook app and then deleting it before you start over.
[Magisk] ogkillergreen:
Cleared cache and uninstalled Intune.

Cleared cache and uninstalled outlook

Installed Intune V5.0.5067.0

Made sure to enable Magisk hide before launching and checked all other options under it

Was able to use Intune successfully

2 days later I got the device compromised error

Tried the steps again and failed

Downgraded to V5.0.5059.0

It worked but then again two days later ran into the error again

Tried to downgrade again, but it failed.

Now there seems to be no way to get this to work anymore
[Magisk] kb8no:
Did you disable intune auto-update?
[Magisk] ogkillergreen:
Yes I did. Everytime it happens I double check the verson installed in app info and it is the correct downgraded version
[Magisk] kb8no:
67 should work. No reason to downgrade more. Do you open intune before you activate all the intune toggles in Magisk?
[Magisk] sarichter:
Sorry, but can you elaborate on 'all components of Intune' as I only see Company Portal as the component to hide. Are there more? Is there a standard list? I'm not talking about apps such as Teams and Outlook... I'm wondering if there are other modules.
[Magisk] kb8no:
Read post 474. There are no modules used, also in recent post. Intune Company Portal is app full name, call it what you like.
[Magisk] fajner:
Where is the download link of the latest version?
[Magisk] diesteldorf:
Just wanted to thank everyone. Everything is working now. I also disabled auto updates for Intune. Hopefully another fix will be found if the old version of Intune is ever permanently disabled.
[Magisk] vaidhy2007:
Intune version 67 works. The latest ones dont work.
[Magisk] drewcu:
Hi,

Could use some help please as I just joined a new company using Company Portal/Intune.

Have a LG V30 that is bootloader unlocked and rooted on the stock rom (also unencrypted to accomplish this).

Using Magisk v22, Edxposed, and following the procedure to:

1) Install Company Portal V5.0.5067.0

2) Magisk Hide ALL of Company Portal checkboxes

3) Reboot

4) Still pass SafetyNet

5) Launch Company Portal

The result is I am still stuck on the "Open the Intune App" screen... No other error messages related to rooting, but cannot even get to log in or download Outlook or Teams. Have tried downloading the Intune App from the Play Store and that tells me to open Company Portal... so going in circles... I'm told I need to only use Company Portal from our IT firm.

Have even tried disabling ALL Magisk modules including EdXposed, but that didn't help. Would rather not test Uninstalling Magisk if that is going to wipe away all my module settings unless I know for sure that could be the issue.

Is the issue that my V30 is unencrypted? Any way around this or am I stuck choosing between an unencrypted, rooted device vs. an encrypted, not rooted device with Company Portal working?

Could encrypting within the LG rom suffice for the encryption check? I see there is an option to encrypt my Phone and SD card within Settings -- Security, but don't want to bother if that is a dead end.

Or could the issue be on my IT admin's end somehow? Haven't seen others mention this Open the Intune App screen which makes me think the issue isn't on my end....?

Thanks very much!

Drew
[Magisk] mike_302:
I'm looking to install LineageOS on my OnePlus 3. I use InTune to access company resources through Outlook, OneDrive, Teams, etc. so I'm conscious that my install of a ROM like Lineage could mess that up. I'm thinking that this thread solves the problem for those users who need to apply InTune after they've already installed a custom ROM, and I'm wondering if I have any advantage coming from a working setup. e.g. could I possibly find out what checks my companies InTune policies are doing, from my working install on the stock OxygenOS? Or can I tweak my LineageOS install process to hide the problems that InTune will call up later?
[Magisk] IlyaKol:
This is busted again. Where is the best place to make a thread and get a developer who knows what they are doing to fix this permanently?

Today Intune FORCED an update (nothing would open otherwise). After updating, same issues as before...
[Magisk] indishcurry:
unfortunately, i do not have time to investigate, but probably one of the following paths is not hidden properly:

"/system/app/Superuser.apk",

"/sbin/su",

"/system/bin/su",

"/system/xbin/su",

"/data/local/xbin/su",

"/data/local/bin/su",

"/system/sd/xbin/su",

"/system/bin/failsafe/su",

"/data/local/su",

"/su/bin/su"

see https://github.com/Aleksey7151/AndroidRootCheck/blob/master/RootCheck/RootChecker.cs
[Magisk] IlyaKol:
Thank you for that. Hopefully someone can take this and run with it as I'm not sure how to 'hide properly'.
[Magisk] Didgeridoohan:
Of those paths, only /sbin/su is being used by Magisk, and that is normally not visible to apps that are on the MagiskHide list. Of course, there are plenty of ways to fool the current implementation of MagiskHide, which is why @topjohnwu has been working on a new method with zygote injection hiding. Who knows when that'll be ready though...
[Magisk] reconan1:
Hi,

My problem is different because the application does not detect the root but when it starts to generate the working profile does not advance and does not create the profile or install applications. I have a Mi Note 3 with revOS 12.1 Android 9 and there is no way...previously on this same device had worked even with magisk. Can it be some restriction of MIUI? I have disabled the second space and dual applications because I have read that it can give problems. I have also tried with v5067 and many others and exactly the same. Any ideas?

Thanks you,
[Magisk] IlyaKol:
Anyone hear any updates? Maybe I should be happy this isn't working because I'm working less but...lol...
[Magisk] indishcurry:
new outlook version enforces a newer intune portal for me...downgrade to 4.2113.2 worked for me
[Magisk] Brownstain:
This worked for me using the latest company portal (5.0.5123.0).

Go into Magisk settings and select Hide Magisk Manager. This repackages the app so other apps see it as something different. After doing, that I cleared the cache in Outlook & Company portal (although I'm not sure that was required). Of course, all the previous discussion about adding Company Portal to your magisk hide list is also required.
[Magisk] indishcurry:
hi, indeed this did the trick - thanks! :) i wonder why I did not think of it before ...
[Magisk] IlyaKol:
Can confirm this worked. The option in settings that you want is "Hide the Magisk app". Also using the latest (5.0.5123.0) Company Portal.

THANK YOU!
[Magisk] :
For me it turned out the company portal was detecting Edxposed somehow. Uninstalled that and everything was running smoothly again.

I don't think it is necessarily an issue with Magisk Hide, it seems to be detecting Edxposed in a different way.

Switched to LSPosed now for the modules I was using and so far the company portal isn't acting up anymore, even on the latest versions.
[Magisk] Patty60205:
Hi I have a similar issue too. During device set up step 2 in Intunes, my phone will suddenly refresh (not reboot, but log will appear and ask for password log in). I can see the work apps in settings but can't click on them,and no work apps in home screen
[Magisk] Diablo2424:
Can confirm this worked for me as well on the newest version of Intune Company Portal running the latest (last) version of Pixen OS on OnePlus 6
[Magisk] SirVilhelm:
What version do you have installed? I am on 5.0.5095.0
[Magisk] mr-mauro:
The latest Outlook app (4.2120.2 updated today), doesn't work anymore with Company Portal 5.0.5095.0 but requires a newer version :) So, be aware, stop automatic Outlook updates too :P
[Magisk] SirVilhelm:
I had magisk hiden last time I tried this and it did not work with company portal. Something change to company portal that resolved that?
[Magisk] Diablo2424:
I'm on Company Portal 5.0.5155.0 and Outlook 4.2120.2

However, although root is hidden to the point where I am able to install and log in to Outlook and Teams, I am not getting my companies Root CA Cert (needed for VPN) via Intune. Not sure why I'm not getting it.

Also note, this is working on my OnePlus 6 running PiXen OS. I have a second OnePlus 6 that was running LineageOS 18.1 nightly, and is now running Evolution X RQ2A.210505.003 (newest version as of 6/7/2021) and both of those ROMs will let me install Company Portal, hide it within Magisk, but will not let me log in to either Outlook (I get "An error occurred" and that's it) or Teams (it never accepts my credentials - just keeps asking for them). So it's something about PiXen OS that is working, compared to the other ROMs.

I also am currently testing my OnePlus 5 running stock OOS, and it is fully working, even the Root CA Certificate downloaded and VPN is working - so that's frustrating as I don't like stock OOS and need root for other apps I run.
[Magisk] SirVilhelm:
Thank you for the update. I am running a Pixel 4a 5G on stock rom, just rooted.
[Magisk] altafharsh60:
This has worked for me.

1. I installed latest Intune company portal from play store.

(Version 5.0.5155.0) ,

2. outlook installed from Uptodown (microsoft-outlook-4-2111-1.apk) Mar 30th, 2021.

Installed both but didn't open, went on to Hide magisk Manager from settings. Then added both the apps to the MagiskHide list.

It's working fine for me
[Magisk] najit97:
I updated and now it doesn't work. Is it possible to side-load an older version APK in the work profile?
[Magisk] agorze:
Hi,

I have a problem with my new Galaxy S21 rooted with Magisk.

It's working fine with my bank app hiding with Magisk Hide. But, it doesn't work with Intune Company Portal V5.0.5067.0 as previously advised here even after hiding with Magisk Hide and Magisk repacked.

Intune detect a custom OS installed.

Any help welcome.
[Magisk] rajkatiyar07:
From where to download ? I can see development has been stopped but still want to try it.
[Magisk] kbs23:
THANK YOU SIR!

Number 2 was my mistake! Thanks for clarifying this, i was driving insane!
[Magisk] rajkatiyar07:
I was having same issue on my P2XL.

Installed Universal Safetynet fix by @kdrag0n and its working just fine now.

https://xdaforums.com/t/magisk-module-universal-safetynet-fix-1-1-0.4217823/
[Magisk] Deli0s:
Any new on this? Looks like they changed the detecting way again...

Now I can log in in teams / outlook, and says that my device is OK, but after some time, a intune notification appears saying that they detected root and they remove my credentials.

I have magisk hidden, all microsoft apps hidden, no root-related files in the storage, safety net passing, and stills finds it... it's really anoying.

I have installed all the files at last version from play store
[Magisk] znjrols:
This just worked for me on the newest company portal app (5.0.5228.0). Thanks!
[Magisk] skuppej:
Working for me as well! Glad it was so simple! And Teams no longer reports that my device is "unauthorized" :D

Also- yes, clearing data is a required step
[Magisk] irammstein:
I found a solution that might not work for everyone: I have a Oneplus 6 with an opened bootloader, ,and I didn't want to loose a root for this.

In Oneplus there is an option to createn new users. This allows you to open a user, while the program can't access your previous files or root.

It's a bit of a hassle, since your need to move between the users.

It means that outlook /intuit are looking for rooted files.
[Magisk] AllGamer:
Is this still working?

The first post is all crossed out.
[Magisk] skuppej:
OK I spoke too soon...after a little while Teams is reporting non-compliant device again. So, it seems that the Hide Magisk Manager method is not enough.
[Magisk] skuppej:
I did some testing and the latest Microsoft Teams (V1416/1.0.0.2021114201) works with company portal app with up to this version:

Intune Company Portal - 2021-05-12 - v5.0.5147.0

Anything newer eventually leads to 'non-compliant device' error, even with the latest magisk hide fixes.

You can get it on apkpure.
[Magisk] microspock:
Strangely, I managed to install teams, outlook and the Company Portal (all last versions) without any problem yesterday. I didn't change anything in my configuration which was not working since the beginning of the year. While safetynet is still failing... I don't understand why it works now.
[Magisk] mr-mauro:
Hi! Cool, I confirm that with that version I pass all the checks. However, I can use only teams but, for example, outlook tells me that intune is too old and that I have to update it!
[Magisk] skuppej:
Yes- I'm unfortunately having the same issue where OneNote is telling me intune is too old, also.

The only way that I am aware to fix this is to use Shelter or Island to move Company Portal + Teams over to isolated space. Then you can uninstall CP/Teams from your normal env. Also be sure to use Play Store (Sheltered) to freeze updates for CP.
[Magisk] Deli0s:
Hey! How do you configure your Shelter to avoid the detection? I have company portal and teams under the shelter, but I still have them detected... Did you do something in magisk hide or something?
[Magisk] skuppej:
Make sure that you have copied over or installed directly the Intune Company Portal - 2021-05-12 - v5.0.5147.0 apk in your shelter'ed env, and not any later version. Teams can be the current version. And then freeze updates for CP via the shelter'ed Play Store app.

And then, yes, also ensure that Teams and Company Portal have been added to MagiskHide and that all toggles are selected. And ensure that you have performed the "Hide the Magisk App" procedure for Magisk itself (found in Magisk settings).

Finally, make sure you've force-closed both Teams and CP and then cleared the storage on both. Then I'd give your phone a restart for good measure after completing these steps. Then just open Teams (sheltered version) and log in via this (I didn't need to open CP first).
[Magisk] Deli0s:
I have followed everything and still not working... It still detects root from time to time and makes me relogin again and again... This intune portal has the best root detection method ever 😂

Thank you anyway!!
[Magisk] skuppej:
Ah damn. Maybe some other detection method is being flagged on your device which is not a problem on mine. Are you also passing SafetyNet and have spoofed the fingerprint for your device? This is also something that should be performed.

Perhaps you can try even earlier versions of Company Portal + Teams to see if anything works there. The problem is though if you go back to Company Portal v5.0.5123.0 or earlier then you need to start rolling back to an earlier version of Teams (also available on apkpure), otherwise you get a "Company Portal out of date" error when you launch teams.

(From my notes/experimentation, I am seeing that for Company Portal v5.0.5123.0 you need to use Teams v1416/1.0.0.2021063702, or earlier.)
[Magisk] Deli0s:
I am passing safety net correctly, but I am spoofing the device as a pixel 5, this can be the cause? The spoof is not done though magisk, but it's a "feature" of my current ROM

I have also checked and removed TWRP folder and any file with the "root" or "magisk" name from the system, even if with it's supposed to not be able to find them because shelter...

Maybe I can try tomorrow with the versions that you point, thank you for the info!

By the way, nobody has found what kind of detection is performing those apps? They are the most difficult to hide by far, good job Microsoft engineers
[Magisk] elite-fusion:
has anyone had luck with this lately?

I tried the 5067 version and it worked, but teams and outlook still stated that the intune is out of date, so still unusable.
[Magisk] skuppej:
Teams v1416 + CP 5.0.5147.0 still works using my workaround. The Outlook version that works with that version of CP, I am unsure.
[Magisk] elite-fusion:
But how do I get the older version of teams on the work profile it creates?

Plus my magiskhide does not have options for which services or apps,just enabled or disabled toggle in settings of magisk