Skip to content

Commit c92ea07

Browse files
committed
code analysis
1 parent 7e0819c commit c92ea07

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

Modules/ibPS/Functions/CSP/Authentication/JWT/Connect-B1Account.ps1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,14 @@ function Connect-B1Account {
77
Connects to the Infoblox Portal and retrieves an interactive JWT session token, enabling the use of account switching.
88
99
In most cases, I would recommend using API Keys as they remain persistent for the length of the key's lifetime, and do not require re-authentication.
10-
10+
1111
However, in cases such as automating the creation of Sandboxes; you will not have received an API Key for the sandbox account yet. Using a JWT session token with this function will enable you to switch into the Sandbox account(s) and perform the necessary operations and optionally create persistent API Key(s).
1212
1313
When connected to the Infoblox Portal using this function, it will override any active connection profile configured in Get-B1ConnectionProfile for the duration of the session. You can disconnect from the Infoblox Portal using Disconnect-B1Account, which will restore the previous connection profile.
1414
1515
.PARAMETER Email
1616
The email address of the Infoblox Portal account to use when connecting.
17-
17+
1818
.PARAMETER Password
1919
The password of the Infoblox Portal account to use when connecting.
2020

Modules/ibPS/Functions/CSP/Authentication/JWT/Disconnect-B1Account.ps1

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@ function Disconnect-B1Account {
2020
.FUNCTIONALITY
2121
Authentication
2222
#>
23+
[CmdletBinding()]
24+
[Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseDeclaredVarsMoreThanAssignments', '')]
2325
param()
2426
if ($ENV:B1Bearer) {
2527
$CU = Get-B1CSPCurrentUser

Modules/ibPS/Functions/CSP/Authentication/JWT/Switch-B1Account.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ function Switch-B1Account {
5757

5858
try {
5959
$Result = Invoke-RestMethod -Method POST -Uri "https://csp.infoblox.com/v2/session/account_switch" -Body $Body -Headers $Headers -ContentType "application/json"
60-
60+
6161
if ($Result.jwt -ne $null) {
6262
$ENV:B1Bearer = $Result.jwt
6363
if ($CU = Get-B1CSPCurrentUser) {

0 commit comments

Comments
 (0)