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

Store API Key/Secret in module scope variable #54

Closed
b-dasass opened this issue Sep 24, 2021 · 2 comments
Closed

Store API Key/Secret in module scope variable #54

b-dasass opened this issue Sep 24, 2021 · 2 comments

Comments

@b-dasass
Copy link

Storing the API Key/Secret in module scope variable instead of the global scope would protect them a little bit more. Right now everything running in PowerShell could see these variables.

Tagging my personal account @sassdawe to have a look at weekend and if time allows send a PR

@JosephMcEvoy
Copy link
Owner

Hi, if I can lead you in the right direction: you should only have to modify PSZoom/Private/Get-ZoomApiCredentials.ps1 to make this work.

@sassdawe
Copy link

Thank you! I haven't spent enough time looking at it just yet, but think we'll need a Set function as well. Plus switch all the $Global: variables to module scoped.
I also want to create some Pester tests for the changes I'm going to introduce. If you don't mind.

Malpractis added a commit to Malpractis/PSZoom that referenced this issue Feb 3, 2023
Fix: Store API Key/Secret in module scope variable JosephMcEvoy#54

With the Server-to-Server OAuth token changes, and the $PSZoomToken variable being stored in the Global scope, it is possible for scripts to run over eachother (especially if you're doing a long running job) and overwrite the token being used. This change is designed to address this issue.
JosephMcEvoy pushed a commit that referenced this issue Mar 19, 2023
Fix: Store API Key/Secret in module scope variable #54

With the Server-to-Server OAuth token changes, and the $PSZoomToken variable being stored in the Global scope, it is possible for scripts to run over eachother (especially if you're doing a long running job) and overwrite the token being used. This change is designed to address this issue.
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

No branches or pull requests

3 participants