Looking for ideas on install/uninstall company software for devs.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements

Welcome Idira to LIVEcommunity!

Our community just got stronger! Explore new identity security resources, connect with experts, and discover more ways to learn and collaborate.

Meet Idira

Looking for ideas on install/uninstall company software for devs.

L1 Bithead

Hi,

 

Looking to solve an interesting problem that has developed within our environment. We have an in-house software that we make and sign that our users use. I've had an application policy built that allows a user to install/uninstall based on the installer publisher and the file name. In the past it's worked flawlessly because the user could install software-installer.msi and uninstall random-character.msi using that info using this policy.

 

The new problem is a change in our msi packaging process has changed and has introduced new behavior that has broken the uninstall process and thereby breaking my policy preventing a user from uninstalling the software. Currently this problem is only affecting our devs who install/uninstall the test versions. I'm really trying my best to adapt our side of the house rather than get them to undo whatever they did to change the behavior.

 

The process that was working before had this workflow.

Add or remove programs -> user selects remove on the software -> UAC for random-character.msi would need admin permissions -> EPM elevated and removed the software because the random-character.msi was signed and matched the CyberArk application policy.

 

The new process.

Add or remove programs -> user selects remove on the software -> UAC for msiexec.exe - > EPM fails because a policy to handle the event doesn't exist.

 

I've introduced a temp solution in the form of a script distribution policy that would allow them to run a script to uninstall the software in the meantime. I'm just looking for a more permanent fix to make the end user experience better.

 

The problem I'm trying to solve is how can I allow them to uninstall the software without giving them full admin access to msiexec.exe. That just seems like a bad idea in itself given they could uninstall any piece of software that doesn't have some kind of tamper protection. Any help or ideas would be greatly appreciated.

 

Thank you,

Braydon

6 REPLIES 6

L4 Transporter

Not sure if you can add the paremeter for commandline /x {1234567 or in the Filename add *.* as a wildcard thats what I did at my last gig to get aroud different filenames.

 

Other than that maybe give JIT rights and then capture the policy used from Policy Audit logs and make a policy out of it thats something I learn about making policies when a dev has admin rights - then search JIT in the policy audit and hopefully there's a policy audit for the uninstallation and then create a policy from it. if the GUID keeps chaning this could be an issue though so not entirely sure it will work, hopefully gives you a few ideas. Field_Content_versions_oct20__068Vy00001HqQ4GIAV.png 

Hey Hirogen,

 

Thank you for the answer. I was definitely concerned with the GUID changing between versions which is mostly why I haven't gone down that route of adding the command line and parameters. From events management I was seeing "msiexec.exe /x {GUID}" was being executed so I may be out of luck on any chance of using a file name as a parameter.

 

I could give the JIT policy a try to at least see if that could get me anymore useful information.

 

-Braydon

See if you can somehow sign the MSIEXEC and check with Sigchecker.exe? but also check by right clicking the msiexec.exe file click EPM tab and check if the signature under publisher status is applied that epm is picking it up, that could be the issue ? https://community.cyberark.com/s/article/EPM-Policy-Best-Practices-Proactively-Troubleshoot-Policy-Outcome.

 

I know at my last gig there were some older files on some network shares which were not code signed properly that epm did not pick up on it. https://community.cyberark.com/s/article/How-does-the-CyberArk-EPM-Agent-validate-digital-signatures-on-Windows - https://learn.microsoft.com/en-us/windows/win32/seccrypto/using-signtool-to-verify-a-file-signature

I ain't a dev but picked up this stuff at my last gig - not sure if EPM supports msiexec if not maybe look into a different packaging process otherwise you're in a pickle?

 

L3 Networker

Are you sure that it was a packaging change that is causing the issues and not something like an update to UAC settings? I agree with hirogen that there is probably a way to get it working, but it is hard to know for sure without some troubleshooting and knowing more of what is going on. It could be as simple as using a filename with a wild card or adding a separate definition in the policy for the test version.

I would say that I'm 99% sure that it is a package change. I have the two different versions that both have the two different behaviors. When I reference Events management I can see the two different behaviors. I've been able to continuously replicate the issue with both versions.

 

Old (working) version File Info:

Publisher: <Company Cert>

Product Name: <Company Product Name>

 

New (not working) version File Info:

Publisher: Microsoft Corportation

Product Name: Windows Installer - Unicode

Original Filename: msiexec.exe

 

If you have any documentation on the UAC settings that are recommended I could still take a look at those. To the best of my knowledge no changes have been made.

 

Just to clarify as well, the problem is only with uninstalling the software, installing the software still works as normal. Using a wildcard for the new versions seems problematic as I don't want to overly grant permissions to the end user who may end up with the potential to uninstall more than allowed, if that makes sense.

Ah that makes more sense. Yeah, it is probably not UAC then, but I pasted the link below if you want to look. Typically trusting MSFT as a publisher gets wonky and is not a great practice in general for security. Something like this may be a better fit for step-up authentication, where you let them elevate but on the basis that they re-authenticate to verify their identity first. There is always a balance when you give access to admin tools like MSI. Usually you are still giving the enduser a lot of power to change things in the system.

 

https://docs.cyberark.com/epm/latest/en/content/installation/windows-systemrequirements.htm?Highlight=uac#UserAccountControlUAC

  • 79 Views
  • 6 replies
  • 0 Likes
Like what you see?

Show your appreciation!

Click Like if a post is helpful to you or if you just want to show your support.

Click Accept as Solution to acknowledge that the answer to your question has been provided.

The button appears next to the replies on topics you’ve started. The member who gave the solution and all future visitors to this topic will appreciate it!

These simple actions take just seconds of your time, but go a long way in showing appreciation for community members and the LIVEcommunity as a whole!

The LIVEcommunity thanks you for your participation!