Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove-TppCertificate needs to updated #4

Closed
jmeldrum76 opened this issue May 1, 2020 · 7 comments · Fixed by #65
Closed

Remove-TppCertificate needs to updated #4

jmeldrum76 opened this issue May 1, 2020 · 7 comments · Fixed by #65
Assignees

Comments

@jmeldrum76
Copy link

Hi,

Remove-TppCertificate works as you have it designed; however, The Venafi DELETE Certificates/{guid} API not only deletes the certificate but also removes the application/device objects as long as there are not additional child objects.

From Document:

"The Application object, associated with the certificate, has no children or only Generational Credential children after the Certificate object is deleted. "

This would be really helpful and would make this function way more useful.

Thanks again for your consideration.

Regards,

Jeremy Meldrum

@gdbarron
Copy link
Collaborator

gdbarron commented May 5, 2020

Hey Jeremy, thanks for your post. I might just be having one of those days, and with my day job schedule lately I wouldn't be surprised, but I'm not following what the suggestion is. Remove-TppCertificate already uses that api. Could you please explain a bit more? Interesting though, now that I re-read through all this, it sounds as if -Force doesn't provide any additional functionality. I wonder if this changed in the api at some point.

@gdbarron
Copy link
Collaborator

@jmeldrum76, just following up. Thanks.

@jmeldrum76
Copy link
Author

Hi Greg, Justin pinged me to comment. Sorry for the lat response.

If you use the native API it deletes the Certificate and the Device and application when there are no more than one associated application. when I use your command it deletes the certificate but orphans the application and device.

Let me know if that makes sense.

Thanks,

Jeremy Meldrum

@gdbarron
Copy link
Collaborator

Thanks, @jmeldrum76, that does make sense. Remove-TppCertificate removes the certificate by default and if there are multiple associations, gives you the option of still removing the certificate by removing the associations ahead of time with -Force. The module isn't just a wrapper for the API, but tries to add some additional logic/functionality. I could see adding an option to remove all associated objects in addition to the cert.

Just so I understand the history and can make an informed decision on how to proceed, could you explain why DELETE Certificates/{guid} works the way it does? Why delete the app/device if only 1 association?

@gdbarron
Copy link
Collaborator

@jmeldrum76 just following up, thanks. Including @BeardedPrincess as well.

@gdbarron gdbarron transferred this issue from gdbarron/VenafiTppPS May 6, 2021
@wilddev65
Copy link
Collaborator

Hey @jmeldrum76 just an FYI, I will look at this as part of some work I'm doing for a customer and figure out a solution.

@jmeldrum76
Copy link
Author

jmeldrum76 commented Jan 18, 2022 via email

@wilddev65 wilddev65 linked a pull request Jan 20, 2022 that will close this issue
gdbarron pushed a commit that referenced this issue Jan 24, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants