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

Input validation around ID parameter #31

Open
FIMTooler opened this issue Jan 21, 2021 · 1 comment
Open

Input validation around ID parameter #31

FIMTooler opened this issue Jan 21, 2021 · 1 comment
Assignees

Comments

@FIMTooler
Copy link

Admittedly, I began using some of the commandlets without reading the wiki or putting much thought into what I was doing. I was attempting to validate the module install was working correctly by the Get-Resource commandlet to perform a simple query. I wrongly supplied an AccountName string to the ID parameter. Obviously there was an error message. However, the message from the MIM Service was something about "requestmessageviolatesprotocol". Looking up this string resulted in only a couple of posts mainly around 2010 RTM and Update 2 which provided no useful information as to the what was really happening.

Outside of my lack of reading the Wiki and passing the correct ResourceID to the ID parameter to begin with, it would be nice to have some validation around the ID parameter to make sure it's a GUID value or a string in a GUID format. A failure of this check would prevent a call being made to the MIM Service and an error message that provides no hint to the actual issue. A much more useful error message could be returned indicating the actual problem.

@ryannewington
Copy link
Member

Thanks for the suggestion @FIMTooler, i'll look at adding something in a future release

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants