Jump to content

Recommended Posts

Posted
This is not selling the move to InTune to me [emoji846]

 

Oh absolutely, there are certain things in Intune that just make absolutely 0 sense. Not including native recurring login scripts within intune is one of those things.

 

For the most part, everything I need to do I have now figured out in intune, but is a lot of it easy? Nope. Could a lot of it be done far simpler in group policy on prem? Yep.

 

I moved to Intune and full azure so that our system is available from anywhere on our devices with no need for a VPN or remote system.

 

Just open laptop, connect to wifi, login and get the full experience as if you were on site.

 

For me, that makes it worth the hassle, but other peoples requirements will be different!

Posted
May I ask what you're in need of running as a script at logon? We've not had login scripts for years now.

 

Sure! Our login script:

 

- clears public desktop (removes any app shortcuts that get added when apps install themselves)

- creates a ‘My Files’ and ‘Google Chrome’ shortcut on to the public desktop once cleared.

- left aligns task bar

- sets dark mode In the taskbar only (not explorer)

- starts some necessary applications

- adds a reg key and proxy setting for our internet filtering solution.

 

Think that’s about it. May be a few other minor tweaks in there but they’re the key ones.

Posted

Is step 10 (setting full control for Everyone) not a bit of a security risk? Or is this just on your development machine?

 

What's to stop a student from modifying/adding to your scripts? I'm not a powershell expert, so please forgive me if I have missed something.

Posted
Is step 10 (setting full control for Everyone) not a bit of a security risk? Or is this just on your development machine?

 

What's to stop a student from modifying/adding to your scripts? I'm not a powershell expert, so please forgive me if I have missed something.

 

Yes, it would be.

 

The script and whole process works without that part, it’s only the detection rule that doesn’t for whatever reason. Detection fails in Intune but everything still works.

 

I should state here in the post that you should either:

 

- add a part to remove the everyone permission as soon as the script ends.

 

- not use the everyone permission at all and use a different detection policy.

 

 

They can’t actually traverse to the folder that has the scripts in as inheritance isn’t enabled on it, they will get a UAC prompt if they go any further than just the top level directory folder, but I have yet to mess around and see how easy this is to break as a student, so the points above still apply.

Posted
All of the steps that the script does can be done via group policy, I wouldn’t use a login script. Are there InTune policies that can do the same?
Posted
All of the steps that the script does can be done via group policy, I wouldn’t use a login script. Are there InTune policies that can do the same?

 

Intune doesn’t use group policy. Intune is built around scripts and win32 apps, it’s a lot harder to manage and maintain.

Posted
Do all what?

 

- clears public desktop (removes any app shortcuts that get added when apps install themselves)

- creates a ‘My Files’ and ‘Google Chrome’ shortcut on to the public desktop once cleared.

- left aligns task bar

- sets dark mode In the taskbar only (not explorer)

- starts some necessary applications

- adds a reg key and proxy setting for our internet filtering solution.

 

 

 

The above that you want your login script to do.

Posted
- clears public desktop (removes any app shortcuts that get added when apps install themselves)

- creates a ‘My Files’ and ‘Google Chrome’ shortcut on to the public desktop once cleared.

- left aligns task bar

- sets dark mode In the taskbar only (not explorer)

- starts some necessary applications

- adds a reg key and proxy setting for our internet filtering solution.

 

 

 

The above that you want your login script to do.

 

No, because powershell scripts in Intune only run once per user/per device.

 

I need my script to run every time a user logs in.

 

As apps get pushed out/installed, their shortcut appears on public desktop, the login script clears it every time and only puts back the files and chrome shortcut.

 

Applications that get started from a server location also need to reliably start on every login.

 

I do wish they made this functionality natively in Intune but it’s just not there, for whatever reason.

  • Thanks 1
Posted

Have you got an example of the script you are using to create the below ?

 

- creates a ‘My Files’ and ‘Google Chrome’ shortcut on to the public desktop once cleared.

 

Thank you

Posted
Have you got an example of the script you are using to create the below ?

 

- creates a ‘My Files’ and ‘Google Chrome’ shortcut on to the public desktop once cleared.

 

Thank you

 

I am back in work tomorrow, I’ll simplify the whole process and send over a package containing the login script that has this in, as well as the rest for you to use if you want to!

  • Thanks 1
  • 2 weeks later...
Posted
For people who dont use this method or scheduled task etc, I am curious as to how you perform user registry settings etc that you would like to apply or reapply per logon (perhaps you dont want people messing with user acrobat settings etc). I am aware that if you have the licensing you can use remediation.
Posted
For people who dont use this method or scheduled task etc, I am curious as to how you perform user registry settings etc that you would like to apply or reapply per logon (perhaps you dont want people messing with user acrobat settings etc). I am aware that if you have the licensing you can use remediation.

 

Hi. If you want recurring reg keys to change via a script, you need to use the task scheduler or this method I’ve provided.

 

Remediations can work but can only be set to per hour at a minimum so is not quick enough for what we need.

 

There is no other way to run recurring scripts on login unfortunately, that’s why I created this method.

Posted
Indeed, I do something similar. I was more wondering what others do. I too found that user WIN32 installations were too slow and unpredictable for items that were needed on logon. At least with system WIN32 you can white glove/pre provision.
Posted
Indeed, I do something similar. I was more wondering what others do. I too found that user WIN32 installations were too slow and unpredictable for items that were needed on logon. At least with system WIN32 you can white glove/pre provision.

 

Yes It’s very frustrating that they haven’t included functionality for login and startup scripts in Intune, the fact it has to be done in a janky way is ridiculous.

  • Thanks 1

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...