Public/adc-functions-conf-authentication.ps1
function Invoke-ADCAddAuthenticationadfsproxyprofile { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for ADFSProxy Profile resource. .PARAMETER Name Name for the adfs proxy profile. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at sign (@), equal sign (=), and hyphen (-) characters. Cannot be changed after the profile is created. CLI Users: If the name includes one or more spaces, enclose the name in double or single quotation marks (for example, "my push service" or 'my push service'). . .PARAMETER Username This is the name of an account in directory that would be used to authenticate trust request from ADC acting as a proxy. .PARAMETER Password This is the password of an account in directory that would be used to authenticate trust request from ADC acting as a proxy. .PARAMETER Serverurl Fully qualified url of the adfs server. .PARAMETER Certkeyname SSL certificate of the proxy that is registered at adfs server for trust. .PARAMETER PassThru Return details about the created authenticationadfsproxyprofile item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationadfsproxyprofile -name <string> -username <string> -password <string> -serverurl <string> -certkeyname <string> An example how to add authenticationadfsproxyprofile configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationadfsproxyprofile Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationadfsproxyprofile/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [ValidateLength(1, 127)] [string]$Name, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Username, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Password, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Serverurl, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Certkeyname, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationadfsproxyprofile: Starting" } process { try { $payload = @{ name = $name username = $username password = $password serverurl = $serverurl certkeyname = $certkeyname } if ( $PSCmdlet.ShouldProcess("authenticationadfsproxyprofile", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationadfsproxyprofile -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationadfsproxyprofile -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationadfsproxyprofile: Finished" } } function Invoke-ADCDeleteAuthenticationadfsproxyprofile { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for ADFSProxy Profile resource. .PARAMETER Name Name for the adfs proxy profile. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at sign (@), equal sign (=), and hyphen (-) characters. Cannot be changed after the profile is created. CLI Users: If the name includes one or more spaces, enclose the name in double or single quotation marks (for example, "my push service" or 'my push service'). . .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationadfsproxyprofile -Name <string> An example how to delete authenticationadfsproxyprofile configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationadfsproxyprofile Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationadfsproxyprofile/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationadfsproxyprofile: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationadfsproxyprofile -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationadfsproxyprofile: Finished" } } function Invoke-ADCUpdateAuthenticationadfsproxyprofile { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for ADFSProxy Profile resource. .PARAMETER Name Name for the adfs proxy profile. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at sign (@), equal sign (=), and hyphen (-) characters. Cannot be changed after the profile is created. CLI Users: If the name includes one or more spaces, enclose the name in double or single quotation marks (for example, "my push service" or 'my push service'). . .PARAMETER Username This is the name of an account in directory that would be used to authenticate trust request from ADC acting as a proxy. .PARAMETER Password This is the password of an account in directory that would be used to authenticate trust request from ADC acting as a proxy. .PARAMETER Serverurl Fully qualified url of the adfs server. .PARAMETER Certkeyname SSL certificate of the proxy that is registered at adfs server for trust. .PARAMETER PassThru Return details about the created authenticationadfsproxyprofile item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationadfsproxyprofile -name <string> An example how to update authenticationadfsproxyprofile configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationadfsproxyprofile Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationadfsproxyprofile/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [ValidateLength(1, 127)] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Username, [ValidateScript({ $_.Length -gt 1 })] [string]$Password, [ValidateScript({ $_.Length -gt 1 })] [string]$Serverurl, [ValidateScript({ $_.Length -gt 1 })] [string]$Certkeyname, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationadfsproxyprofile: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('username') ) { $payload.Add('username', $username) } if ( $PSBoundParameters.ContainsKey('password') ) { $payload.Add('password', $password) } if ( $PSBoundParameters.ContainsKey('serverurl') ) { $payload.Add('serverurl', $serverurl) } if ( $PSBoundParameters.ContainsKey('certkeyname') ) { $payload.Add('certkeyname', $certkeyname) } if ( $PSCmdlet.ShouldProcess("authenticationadfsproxyprofile", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationadfsproxyprofile -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationadfsproxyprofile -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationadfsproxyprofile: Finished" } } function Invoke-ADCGetAuthenticationadfsproxyprofile { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for ADFSProxy Profile resource. .PARAMETER Name Name for the adfs proxy profile. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at sign (@), equal sign (=), and hyphen (-) characters. Cannot be changed after the profile is created. CLI Users: If the name includes one or more spaces, enclose the name in double or single quotation marks (for example, "my push service" or 'my push service'). . .PARAMETER GetAll Retrieve all authenticationadfsproxyprofile object(s). .PARAMETER Count If specified, the count of the authenticationadfsproxyprofile object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationadfsproxyprofile Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationadfsproxyprofile -GetAll Get all authenticationadfsproxyprofile data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationadfsproxyprofile -Count Get the number of authenticationadfsproxyprofile objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationadfsproxyprofile -name <string> Get authenticationadfsproxyprofile object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationadfsproxyprofile -Filter @{ 'name'='<value>' } Get authenticationadfsproxyprofile data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationadfsproxyprofile Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationadfsproxyprofile/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [ValidateLength(1, 127)] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationadfsproxyprofile: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationadfsproxyprofile objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationadfsproxyprofile -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationadfsproxyprofile objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationadfsproxyprofile -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationadfsproxyprofile objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationadfsproxyprofile -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationadfsproxyprofile configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationadfsproxyprofile -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationadfsproxyprofile configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationadfsproxyprofile -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationadfsproxyprofile: Ended" } } function Invoke-ADCUnsetAuthenticationauthnprofile { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for Authentication profile resource. .PARAMETER Name Name for the authentication profile. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the RADIUS action is added. .PARAMETER Authenticationdomain Domain for which TM cookie must to be set. If unspecified, cookie will be set for FQDN. .PARAMETER Authenticationlevel Authentication weight or level of the vserver to which this will bound. This is used to order TM vservers based on the protection required. A session that is created by authenticating against TM vserver at given level cannot be used to access TM vserver at a higher level. .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationauthnprofile -name <string> An example how to unset authenticationauthnprofile configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationauthnprofile Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationauthnprofile Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Boolean]$authenticationdomain, [Boolean]$authenticationlevel ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationauthnprofile: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('authenticationdomain') ) { $payload.Add('authenticationdomain', $authenticationdomain) } if ( $PSBoundParameters.ContainsKey('authenticationlevel') ) { $payload.Add('authenticationlevel', $authenticationlevel) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationauthnprofile -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationauthnprofile: Finished" } } function Invoke-ADCDeleteAuthenticationauthnprofile { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for Authentication profile resource. .PARAMETER Name Name for the authentication profile. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the RADIUS action is added. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationauthnprofile -Name <string> An example how to delete authenticationauthnprofile configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationauthnprofile Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationauthnprofile/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationauthnprofile: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationauthnprofile -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationauthnprofile: Finished" } } function Invoke-ADCUpdateAuthenticationauthnprofile { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for Authentication profile resource. .PARAMETER Name Name for the authentication profile. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the RADIUS action is added. .PARAMETER Authnvsname Name of the authentication vserver at which authentication should be done. .PARAMETER Authenticationhost Hostname of the authentication vserver to which user must be redirected for authentication. .PARAMETER Authenticationdomain Domain for which TM cookie must to be set. If unspecified, cookie will be set for FQDN. .PARAMETER Authenticationlevel Authentication weight or level of the vserver to which this will bound. This is used to order TM vservers based on the protection required. A session that is created by authenticating against TM vserver at given level cannot be used to access TM vserver at a higher level. .PARAMETER PassThru Return details about the created authenticationauthnprofile item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationauthnprofile -name <string> An example how to update authenticationauthnprofile configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationauthnprofile Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationauthnprofile/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [ValidateLength(1, 128)] [string]$Authnvsname, [ValidateLength(1, 256)] [string]$Authenticationhost, [ValidateLength(1, 256)] [string]$Authenticationdomain, [ValidateRange(0, 255)] [double]$Authenticationlevel, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationauthnprofile: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('authnvsname') ) { $payload.Add('authnvsname', $authnvsname) } if ( $PSBoundParameters.ContainsKey('authenticationhost') ) { $payload.Add('authenticationhost', $authenticationhost) } if ( $PSBoundParameters.ContainsKey('authenticationdomain') ) { $payload.Add('authenticationdomain', $authenticationdomain) } if ( $PSBoundParameters.ContainsKey('authenticationlevel') ) { $payload.Add('authenticationlevel', $authenticationlevel) } if ( $PSCmdlet.ShouldProcess("authenticationauthnprofile", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationauthnprofile -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationauthnprofile -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationauthnprofile: Finished" } } function Invoke-ADCAddAuthenticationauthnprofile { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for Authentication profile resource. .PARAMETER Name Name for the authentication profile. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the RADIUS action is added. .PARAMETER Authnvsname Name of the authentication vserver at which authentication should be done. .PARAMETER Authenticationhost Hostname of the authentication vserver to which user must be redirected for authentication. .PARAMETER Authenticationdomain Domain for which TM cookie must to be set. If unspecified, cookie will be set for FQDN. .PARAMETER Authenticationlevel Authentication weight or level of the vserver to which this will bound. This is used to order TM vservers based on the protection required. A session that is created by authenticating against TM vserver at given level cannot be used to access TM vserver at a higher level. .PARAMETER PassThru Return details about the created authenticationauthnprofile item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationauthnprofile -name <string> -authnvsname <string> An example how to add authenticationauthnprofile configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationauthnprofile Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationauthnprofile/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(Mandatory)] [ValidateLength(1, 128)] [string]$Authnvsname, [ValidateLength(1, 256)] [string]$Authenticationhost, [ValidateLength(1, 256)] [string]$Authenticationdomain, [ValidateRange(0, 255)] [double]$Authenticationlevel, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationauthnprofile: Starting" } process { try { $payload = @{ name = $name authnvsname = $authnvsname } if ( $PSBoundParameters.ContainsKey('authenticationhost') ) { $payload.Add('authenticationhost', $authenticationhost) } if ( $PSBoundParameters.ContainsKey('authenticationdomain') ) { $payload.Add('authenticationdomain', $authenticationdomain) } if ( $PSBoundParameters.ContainsKey('authenticationlevel') ) { $payload.Add('authenticationlevel', $authenticationlevel) } if ( $PSCmdlet.ShouldProcess("authenticationauthnprofile", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationauthnprofile -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationauthnprofile -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationauthnprofile: Finished" } } function Invoke-ADCGetAuthenticationauthnprofile { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for Authentication profile resource. .PARAMETER Name Name for the authentication profile. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the RADIUS action is added. .PARAMETER GetAll Retrieve all authenticationauthnprofile object(s). .PARAMETER Count If specified, the count of the authenticationauthnprofile object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationauthnprofile Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationauthnprofile -GetAll Get all authenticationauthnprofile data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationauthnprofile -Count Get the number of authenticationauthnprofile objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationauthnprofile -name <string> Get authenticationauthnprofile object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationauthnprofile -Filter @{ 'name'='<value>' } Get authenticationauthnprofile data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationauthnprofile Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationauthnprofile/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationauthnprofile: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationauthnprofile objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationauthnprofile -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationauthnprofile objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationauthnprofile -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationauthnprofile objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationauthnprofile -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationauthnprofile configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationauthnprofile -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationauthnprofile configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationauthnprofile -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationauthnprofile: Ended" } } function Invoke-ADCAddAuthenticationazurekeyvault { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for Azure Key Vault entity resource. .PARAMETER Name Name for the new Azure Key Vault profile. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER Vaultname Name of the Azure vault account as configured in azure portal. .PARAMETER Clientid Unique identity of the relying party requesting for authentication. .PARAMETER Clientsecret Unique secret string to authorize relying party at authorization server. .PARAMETER Servicekeyname Friendly name of the Key to be used to compute signature. .PARAMETER Signaturealg Algorithm to be used to sign/verify transactions. Possible values = RS256 .PARAMETER Tokenendpoint URL endpoint on relying party to which the OAuth token is to be sent. .PARAMETER Pushservice Name of the service used to send push notifications. .PARAMETER Defaultauthenticationgroup This is the group that is added to user sessions that match current IdP policy. It can be used in policies to identify relying party trust. .PARAMETER Refreshinterval Interval at which access token in obtained. .PARAMETER Tenantid TenantID of the application. This is usually specific to providers such as Microsoft and usually refers to the deployment identifier. .PARAMETER Authentication If authentication is disabled, otp checks are not performed after azure vault keys are obtained. This is useful to distinguish whether user has registered devices. . Possible values = ENABLED, DISABLED .PARAMETER PassThru Return details about the created authenticationazurekeyvault item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationazurekeyvault -name <string> -vaultname <string> -clientid <string> -clientsecret <string> -servicekeyname <string> An example how to add authenticationazurekeyvault configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationazurekeyvault Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationazurekeyvault/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Parameter(Mandatory)] [ValidateLength(1, 63)] [string]$Vaultname, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Clientid, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Clientsecret, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Servicekeyname, [ValidateSet('RS256')] [string]$Signaturealg = 'RS256', [ValidateScript({ $_.Length -gt 1 })] [string]$Tokenendpoint, [ValidateScript({ $_.Length -gt 1 })] [string]$Pushservice, [string]$Defaultauthenticationgroup, [double]$Refreshinterval = '50', [string]$Tenantid, [ValidateSet('ENABLED', 'DISABLED')] [string]$Authentication = 'ENABLED', [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationazurekeyvault: Starting" } process { try { $payload = @{ name = $name vaultname = $vaultname clientid = $clientid clientsecret = $clientsecret servicekeyname = $servicekeyname } if ( $PSBoundParameters.ContainsKey('signaturealg') ) { $payload.Add('signaturealg', $signaturealg) } if ( $PSBoundParameters.ContainsKey('tokenendpoint') ) { $payload.Add('tokenendpoint', $tokenendpoint) } if ( $PSBoundParameters.ContainsKey('pushservice') ) { $payload.Add('pushservice', $pushservice) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('refreshinterval') ) { $payload.Add('refreshinterval', $refreshinterval) } if ( $PSBoundParameters.ContainsKey('tenantid') ) { $payload.Add('tenantid', $tenantid) } if ( $PSBoundParameters.ContainsKey('authentication') ) { $payload.Add('authentication', $authentication) } if ( $PSCmdlet.ShouldProcess("authenticationazurekeyvault", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationazurekeyvault -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationazurekeyvault -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationazurekeyvault: Finished" } } function Invoke-ADCDeleteAuthenticationazurekeyvault { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for Azure Key Vault entity resource. .PARAMETER Name Name for the new Azure Key Vault profile. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationazurekeyvault -Name <string> An example how to delete authenticationazurekeyvault configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationazurekeyvault Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationazurekeyvault/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationazurekeyvault: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationazurekeyvault -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationazurekeyvault: Finished" } } function Invoke-ADCUpdateAuthenticationazurekeyvault { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for Azure Key Vault entity resource. .PARAMETER Name Name for the new Azure Key Vault profile. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER Vaultname Name of the Azure vault account as configured in azure portal. .PARAMETER Clientid Unique identity of the relying party requesting for authentication. .PARAMETER Clientsecret Unique secret string to authorize relying party at authorization server. .PARAMETER Servicekeyname Friendly name of the Key to be used to compute signature. .PARAMETER Signaturealg Algorithm to be used to sign/verify transactions. Possible values = RS256 .PARAMETER Tokenendpoint URL endpoint on relying party to which the OAuth token is to be sent. .PARAMETER Pushservice Name of the service used to send push notifications. .PARAMETER Defaultauthenticationgroup This is the group that is added to user sessions that match current IdP policy. It can be used in policies to identify relying party trust. .PARAMETER Refreshinterval Interval at which access token in obtained. .PARAMETER Tenantid TenantID of the application. This is usually specific to providers such as Microsoft and usually refers to the deployment identifier. .PARAMETER Authentication If authentication is disabled, otp checks are not performed after azure vault keys are obtained. This is useful to distinguish whether user has registered devices. . Possible values = ENABLED, DISABLED .PARAMETER PassThru Return details about the created authenticationazurekeyvault item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationazurekeyvault -name <string> An example how to update authenticationazurekeyvault configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationazurekeyvault Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationazurekeyvault/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [ValidateLength(1, 63)] [string]$Vaultname, [ValidateScript({ $_.Length -gt 1 })] [string]$Clientid, [ValidateScript({ $_.Length -gt 1 })] [string]$Clientsecret, [ValidateScript({ $_.Length -gt 1 })] [string]$Servicekeyname, [ValidateSet('RS256')] [string]$Signaturealg, [ValidateScript({ $_.Length -gt 1 })] [string]$Tokenendpoint, [ValidateScript({ $_.Length -gt 1 })] [string]$Pushservice, [string]$Defaultauthenticationgroup, [double]$Refreshinterval, [string]$Tenantid, [ValidateSet('ENABLED', 'DISABLED')] [string]$Authentication, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationazurekeyvault: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('vaultname') ) { $payload.Add('vaultname', $vaultname) } if ( $PSBoundParameters.ContainsKey('clientid') ) { $payload.Add('clientid', $clientid) } if ( $PSBoundParameters.ContainsKey('clientsecret') ) { $payload.Add('clientsecret', $clientsecret) } if ( $PSBoundParameters.ContainsKey('servicekeyname') ) { $payload.Add('servicekeyname', $servicekeyname) } if ( $PSBoundParameters.ContainsKey('signaturealg') ) { $payload.Add('signaturealg', $signaturealg) } if ( $PSBoundParameters.ContainsKey('tokenendpoint') ) { $payload.Add('tokenendpoint', $tokenendpoint) } if ( $PSBoundParameters.ContainsKey('pushservice') ) { $payload.Add('pushservice', $pushservice) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('refreshinterval') ) { $payload.Add('refreshinterval', $refreshinterval) } if ( $PSBoundParameters.ContainsKey('tenantid') ) { $payload.Add('tenantid', $tenantid) } if ( $PSBoundParameters.ContainsKey('authentication') ) { $payload.Add('authentication', $authentication) } if ( $PSCmdlet.ShouldProcess("authenticationazurekeyvault", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationazurekeyvault -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationazurekeyvault -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationazurekeyvault: Finished" } } function Invoke-ADCUnsetAuthenticationazurekeyvault { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for Azure Key Vault entity resource. .PARAMETER Name Name for the new Azure Key Vault profile. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER Signaturealg Algorithm to be used to sign/verify transactions. Possible values = RS256 .PARAMETER Pushservice Name of the service used to send push notifications. .PARAMETER Defaultauthenticationgroup This is the group that is added to user sessions that match current IdP policy. It can be used in policies to identify relying party trust. .PARAMETER Refreshinterval Interval at which access token in obtained. .PARAMETER Authentication If authentication is disabled, otp checks are not performed after azure vault keys are obtained. This is useful to distinguish whether user has registered devices. . Possible values = ENABLED, DISABLED .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationazurekeyvault -name <string> An example how to unset authenticationazurekeyvault configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationazurekeyvault Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationazurekeyvault Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Boolean]$signaturealg, [Boolean]$pushservice, [Boolean]$defaultauthenticationgroup, [Boolean]$refreshinterval, [Boolean]$authentication ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationazurekeyvault: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('signaturealg') ) { $payload.Add('signaturealg', $signaturealg) } if ( $PSBoundParameters.ContainsKey('pushservice') ) { $payload.Add('pushservice', $pushservice) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('refreshinterval') ) { $payload.Add('refreshinterval', $refreshinterval) } if ( $PSBoundParameters.ContainsKey('authentication') ) { $payload.Add('authentication', $authentication) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationazurekeyvault -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationazurekeyvault: Finished" } } function Invoke-ADCGetAuthenticationazurekeyvault { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for Azure Key Vault entity resource. .PARAMETER Name Name for the new Azure Key Vault profile. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER GetAll Retrieve all authenticationazurekeyvault object(s). .PARAMETER Count If specified, the count of the authenticationazurekeyvault object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationazurekeyvault Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationazurekeyvault -GetAll Get all authenticationazurekeyvault data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationazurekeyvault -Count Get the number of authenticationazurekeyvault objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationazurekeyvault -name <string> Get authenticationazurekeyvault object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationazurekeyvault -Filter @{ 'name'='<value>' } Get authenticationazurekeyvault data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationazurekeyvault Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationazurekeyvault/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationazurekeyvault: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationazurekeyvault objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationazurekeyvault -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationazurekeyvault objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationazurekeyvault -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationazurekeyvault objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationazurekeyvault -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationazurekeyvault configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationazurekeyvault -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationazurekeyvault configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationazurekeyvault -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationazurekeyvault: Ended" } } function Invoke-ADCAddAuthenticationcaptchaaction { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for Captcha Action resource. .PARAMETER Name Name for the new captcha action. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. The following requirement applies only to the NetScaler CLI: If the name includes one or more spaces, enclose the name in double or single quotation marks (for example, "my action" or 'my action'). .PARAMETER Serverurl This is the endpoint at which captcha response is validated. .PARAMETER Secretkey Secret of gateway as established at the captcha source. .PARAMETER Sitekey Sitekey to identify gateway fqdn while loading captcha. .PARAMETER Defaultauthenticationgroup This is the group that is added to user sessions that match current policy. .PARAMETER PassThru Return details about the created authenticationcaptchaaction item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationcaptchaaction -name <string> -secretkey <string> -sitekey <string> An example how to add authenticationcaptchaaction configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationcaptchaaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcaptchaaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [string]$Serverurl, [Parameter(Mandatory)] [string]$Secretkey, [Parameter(Mandatory)] [string]$Sitekey, [string]$Defaultauthenticationgroup, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationcaptchaaction: Starting" } process { try { $payload = @{ name = $name secretkey = $secretkey sitekey = $sitekey } if ( $PSBoundParameters.ContainsKey('serverurl') ) { $payload.Add('serverurl', $serverurl) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSCmdlet.ShouldProcess("authenticationcaptchaaction", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationcaptchaaction -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationcaptchaaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationcaptchaaction: Finished" } } function Invoke-ADCDeleteAuthenticationcaptchaaction { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for Captcha Action resource. .PARAMETER Name Name for the new captcha action. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. The following requirement applies only to the NetScaler CLI: If the name includes one or more spaces, enclose the name in double or single quotation marks (for example, "my action" or 'my action'). .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationcaptchaaction -Name <string> An example how to delete authenticationcaptchaaction configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationcaptchaaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcaptchaaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationcaptchaaction: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationcaptchaaction -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationcaptchaaction: Finished" } } function Invoke-ADCUpdateAuthenticationcaptchaaction { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for Captcha Action resource. .PARAMETER Name Name for the new captcha action. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. The following requirement applies only to the NetScaler CLI: If the name includes one or more spaces, enclose the name in double or single quotation marks (for example, "my action" or 'my action'). .PARAMETER Serverurl This is the endpoint at which captcha response is validated. .PARAMETER Secretkey Secret of gateway as established at the captcha source. .PARAMETER Sitekey Sitekey to identify gateway fqdn while loading captcha. .PARAMETER Defaultauthenticationgroup This is the group that is added to user sessions that match current policy. .PARAMETER PassThru Return details about the created authenticationcaptchaaction item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationcaptchaaction -name <string> An example how to update authenticationcaptchaaction configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationcaptchaaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcaptchaaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [string]$Serverurl, [string]$Secretkey, [string]$Sitekey, [string]$Defaultauthenticationgroup, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationcaptchaaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('serverurl') ) { $payload.Add('serverurl', $serverurl) } if ( $PSBoundParameters.ContainsKey('secretkey') ) { $payload.Add('secretkey', $secretkey) } if ( $PSBoundParameters.ContainsKey('sitekey') ) { $payload.Add('sitekey', $sitekey) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSCmdlet.ShouldProcess("authenticationcaptchaaction", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationcaptchaaction -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationcaptchaaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationcaptchaaction: Finished" } } function Invoke-ADCUnsetAuthenticationcaptchaaction { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for Captcha Action resource. .PARAMETER Name Name for the new captcha action. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. The following requirement applies only to the NetScaler CLI: If the name includes one or more spaces, enclose the name in double or single quotation marks (for example, "my action" or 'my action'). .PARAMETER Serverurl This is the endpoint at which captcha response is validated. .PARAMETER Defaultauthenticationgroup This is the group that is added to user sessions that match current policy. .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationcaptchaaction -name <string> An example how to unset authenticationcaptchaaction configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationcaptchaaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcaptchaaction Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Boolean]$serverurl, [Boolean]$defaultauthenticationgroup ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationcaptchaaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('serverurl') ) { $payload.Add('serverurl', $serverurl) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationcaptchaaction -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationcaptchaaction: Finished" } } function Invoke-ADCGetAuthenticationcaptchaaction { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for Captcha Action resource. .PARAMETER Name Name for the new captcha action. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. The following requirement applies only to the NetScaler CLI: If the name includes one or more spaces, enclose the name in double or single quotation marks (for example, "my action" or 'my action'). .PARAMETER GetAll Retrieve all authenticationcaptchaaction object(s). .PARAMETER Count If specified, the count of the authenticationcaptchaaction object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcaptchaaction Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcaptchaaction -GetAll Get all authenticationcaptchaaction data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcaptchaaction -Count Get the number of authenticationcaptchaaction objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcaptchaaction -name <string> Get authenticationcaptchaaction object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcaptchaaction -Filter @{ 'name'='<value>' } Get authenticationcaptchaaction data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationcaptchaaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcaptchaaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationcaptchaaction: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationcaptchaaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcaptchaaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationcaptchaaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcaptchaaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationcaptchaaction objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcaptchaaction -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationcaptchaaction configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcaptchaaction -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationcaptchaaction configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcaptchaaction -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationcaptchaaction: Ended" } } function Invoke-ADCUnsetAuthenticationcertaction { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for CERT action resource. .PARAMETER Name Name for the client cert authentication server profile (action). Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after certifcate action is created. .PARAMETER Twofactor Enables or disables two-factor authentication. Two factor authentication is client cert authentication followed by password authentication. Possible values = ON, OFF .PARAMETER Usernamefield Client-cert field from which the username is extracted. Must be set to either ""Subject"" and ""Issuer"" (include both sets of double quotation marks). Format: <field>:<subfield>. .PARAMETER Groupnamefield Client-cert field from which the group is extracted. Must be set to either ""Subject"" and ""Issuer"" (include both sets of double quotation marks). Format: <field>:<subfield>. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationcertaction -name <string> An example how to unset authenticationcertaction configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationcertaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcertaction Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Boolean]$twofactor, [Boolean]$usernamefield, [Boolean]$groupnamefield, [Boolean]$defaultauthenticationgroup ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationcertaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('twofactor') ) { $payload.Add('twofactor', $twofactor) } if ( $PSBoundParameters.ContainsKey('usernamefield') ) { $payload.Add('usernamefield', $usernamefield) } if ( $PSBoundParameters.ContainsKey('groupnamefield') ) { $payload.Add('groupnamefield', $groupnamefield) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationcertaction -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationcertaction: Finished" } } function Invoke-ADCAddAuthenticationcertaction { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for CERT action resource. .PARAMETER Name Name for the client cert authentication server profile (action). Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after certifcate action is created. .PARAMETER Twofactor Enables or disables two-factor authentication. Two factor authentication is client cert authentication followed by password authentication. Possible values = ON, OFF .PARAMETER Usernamefield Client-cert field from which the username is extracted. Must be set to either ""Subject"" and ""Issuer"" (include both sets of double quotation marks). Format: <field>:<subfield>. .PARAMETER Groupnamefield Client-cert field from which the group is extracted. Must be set to either ""Subject"" and ""Issuer"" (include both sets of double quotation marks). Format: <field>:<subfield>. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER PassThru Return details about the created authenticationcertaction item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationcertaction -name <string> An example how to add authenticationcertaction configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationcertaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcertaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [ValidateSet('ON', 'OFF')] [string]$Twofactor = 'OFF', [ValidateScript({ $_.Length -gt 1 })] [string]$Usernamefield, [ValidateScript({ $_.Length -gt 1 })] [string]$Groupnamefield, [string]$Defaultauthenticationgroup, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationcertaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('twofactor') ) { $payload.Add('twofactor', $twofactor) } if ( $PSBoundParameters.ContainsKey('usernamefield') ) { $payload.Add('usernamefield', $usernamefield) } if ( $PSBoundParameters.ContainsKey('groupnamefield') ) { $payload.Add('groupnamefield', $groupnamefield) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSCmdlet.ShouldProcess("authenticationcertaction", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationcertaction -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationcertaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationcertaction: Finished" } } function Invoke-ADCDeleteAuthenticationcertaction { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for CERT action resource. .PARAMETER Name Name for the client cert authentication server profile (action). Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after certifcate action is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationcertaction -Name <string> An example how to delete authenticationcertaction configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationcertaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcertaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationcertaction: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationcertaction -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationcertaction: Finished" } } function Invoke-ADCUpdateAuthenticationcertaction { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for CERT action resource. .PARAMETER Name Name for the client cert authentication server profile (action). Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after certifcate action is created. .PARAMETER Twofactor Enables or disables two-factor authentication. Two factor authentication is client cert authentication followed by password authentication. Possible values = ON, OFF .PARAMETER Usernamefield Client-cert field from which the username is extracted. Must be set to either ""Subject"" and ""Issuer"" (include both sets of double quotation marks). Format: <field>:<subfield>. .PARAMETER Groupnamefield Client-cert field from which the group is extracted. Must be set to either ""Subject"" and ""Issuer"" (include both sets of double quotation marks). Format: <field>:<subfield>. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER PassThru Return details about the created authenticationcertaction item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationcertaction -name <string> An example how to update authenticationcertaction configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationcertaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcertaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [ValidateSet('ON', 'OFF')] [string]$Twofactor, [ValidateScript({ $_.Length -gt 1 })] [string]$Usernamefield, [ValidateScript({ $_.Length -gt 1 })] [string]$Groupnamefield, [string]$Defaultauthenticationgroup, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationcertaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('twofactor') ) { $payload.Add('twofactor', $twofactor) } if ( $PSBoundParameters.ContainsKey('usernamefield') ) { $payload.Add('usernamefield', $usernamefield) } if ( $PSBoundParameters.ContainsKey('groupnamefield') ) { $payload.Add('groupnamefield', $groupnamefield) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSCmdlet.ShouldProcess("authenticationcertaction", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationcertaction -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationcertaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationcertaction: Finished" } } function Invoke-ADCGetAuthenticationcertaction { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for CERT action resource. .PARAMETER Name Name for the client cert authentication server profile (action). Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after certifcate action is created. .PARAMETER GetAll Retrieve all authenticationcertaction object(s). .PARAMETER Count If specified, the count of the authenticationcertaction object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertaction Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertaction -GetAll Get all authenticationcertaction data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertaction -Count Get the number of authenticationcertaction objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertaction -name <string> Get authenticationcertaction object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertaction -Filter @{ 'name'='<value>' } Get authenticationcertaction data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationcertaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcertaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationcertaction: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationcertaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationcertaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationcertaction objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertaction -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationcertaction configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertaction -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationcertaction configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertaction -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationcertaction: Ended" } } function Invoke-ADCUpdateAuthenticationcertpolicy { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for CERT policy resource. .PARAMETER Name Name for the client certificate authentication policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after cert authentication policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to determine whether to attempt to authenticate the user with the authentication server. .PARAMETER Reqaction Name of the client cert authentication action to be performed if the policy matches. .PARAMETER PassThru Return details about the created authenticationcertpolicy item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationcertpolicy -name <string> An example how to update authenticationcertpolicy configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationcertpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcertpolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Rule, [ValidateScript({ $_.Length -gt 1 })] [string]$Reqaction, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationcertpolicy: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('rule') ) { $payload.Add('rule', $rule) } if ( $PSBoundParameters.ContainsKey('reqaction') ) { $payload.Add('reqaction', $reqaction) } if ( $PSCmdlet.ShouldProcess("authenticationcertpolicy", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationcertpolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationcertpolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationcertpolicy: Finished" } } function Invoke-ADCUnsetAuthenticationcertpolicy { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for CERT policy resource. .PARAMETER Name Name for the client certificate authentication policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after cert authentication policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to determine whether to attempt to authenticate the user with the authentication server. .PARAMETER Reqaction Name of the client cert authentication action to be performed if the policy matches. .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationcertpolicy -name <string> An example how to unset authenticationcertpolicy configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationcertpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcertpolicy Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Boolean]$rule, [Boolean]$reqaction ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationcertpolicy: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('rule') ) { $payload.Add('rule', $rule) } if ( $PSBoundParameters.ContainsKey('reqaction') ) { $payload.Add('reqaction', $reqaction) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationcertpolicy -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationcertpolicy: Finished" } } function Invoke-ADCAddAuthenticationcertpolicy { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for CERT policy resource. .PARAMETER Name Name for the client certificate authentication policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after cert authentication policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to determine whether to attempt to authenticate the user with the authentication server. .PARAMETER Reqaction Name of the client cert authentication action to be performed if the policy matches. .PARAMETER PassThru Return details about the created authenticationcertpolicy item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationcertpolicy -name <string> -rule <string> An example how to add authenticationcertpolicy configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationcertpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcertpolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Rule, [ValidateScript({ $_.Length -gt 1 })] [string]$Reqaction, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationcertpolicy: Starting" } process { try { $payload = @{ name = $name rule = $rule } if ( $PSBoundParameters.ContainsKey('reqaction') ) { $payload.Add('reqaction', $reqaction) } if ( $PSCmdlet.ShouldProcess("authenticationcertpolicy", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationcertpolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationcertpolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationcertpolicy: Finished" } } function Invoke-ADCDeleteAuthenticationcertpolicy { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for CERT policy resource. .PARAMETER Name Name for the client certificate authentication policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after cert authentication policy is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationcertpolicy -Name <string> An example how to delete authenticationcertpolicy configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationcertpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcertpolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationcertpolicy: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationcertpolicy -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationcertpolicy: Finished" } } function Invoke-ADCGetAuthenticationcertpolicy { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for CERT policy resource. .PARAMETER Name Name for the client certificate authentication policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after cert authentication policy is created. .PARAMETER GetAll Retrieve all authenticationcertpolicy object(s). .PARAMETER Count If specified, the count of the authenticationcertpolicy object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicy Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicy -GetAll Get all authenticationcertpolicy data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicy -Count Get the number of authenticationcertpolicy objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicy -name <string> Get authenticationcertpolicy object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicy -Filter @{ 'name'='<value>' } Get authenticationcertpolicy data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationcertpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcertpolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationcertpolicy: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationcertpolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationcertpolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationcertpolicy objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationcertpolicy configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationcertpolicy configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationcertpolicy: Ended" } } function Invoke-ADCGetAuthenticationcertpolicyauthenticationvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationvserver that can be bound to authenticationcertpolicy. .PARAMETER Name Name of the client cert authentication policy. .PARAMETER GetAll Retrieve all authenticationcertpolicy_authenticationvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationcertpolicy_authenticationvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicyauthenticationvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicyauthenticationvserverbinding -GetAll Get all authenticationcertpolicy_authenticationvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicyauthenticationvserverbinding -Count Get the number of authenticationcertpolicy_authenticationvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicyauthenticationvserverbinding -name <string> Get authenticationcertpolicy_authenticationvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicyauthenticationvserverbinding -Filter @{ 'name'='<value>' } Get authenticationcertpolicy_authenticationvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationcertpolicyauthenticationvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcertpolicy_authenticationvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationcertpolicyauthenticationvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationcertpolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationcertpolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationcertpolicy_authenticationvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationcertpolicy_authenticationvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationcertpolicy_authenticationvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationcertpolicyauthenticationvserverbinding: Ended" } } function Invoke-ADCGetAuthenticationcertpolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object which returns the resources bound to authenticationcertpolicy. .PARAMETER Name Name of the client cert authentication policy. .PARAMETER GetAll Retrieve all authenticationcertpolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationcertpolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicybinding -GetAll Get all authenticationcertpolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicybinding -name <string> Get authenticationcertpolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicybinding -Filter @{ 'name'='<value>' } Get authenticationcertpolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationcertpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcertpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationcertpolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationcertpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationcertpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationcertpolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationcertpolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationcertpolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationcertpolicybinding: Ended" } } function Invoke-ADCGetAuthenticationcertpolicyvpnglobalbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the vpnglobal that can be bound to authenticationcertpolicy. .PARAMETER Name Name of the client cert authentication policy. .PARAMETER GetAll Retrieve all authenticationcertpolicy_vpnglobal_binding object(s). .PARAMETER Count If specified, the count of the authenticationcertpolicy_vpnglobal_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicyvpnglobalbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicyvpnglobalbinding -GetAll Get all authenticationcertpolicy_vpnglobal_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicyvpnglobalbinding -Count Get the number of authenticationcertpolicy_vpnglobal_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicyvpnglobalbinding -name <string> Get authenticationcertpolicy_vpnglobal_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicyvpnglobalbinding -Filter @{ 'name'='<value>' } Get authenticationcertpolicy_vpnglobal_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationcertpolicyvpnglobalbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcertpolicy_vpnglobal_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationcertpolicyvpnglobalbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationcertpolicy_vpnglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy_vpnglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationcertpolicy_vpnglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy_vpnglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationcertpolicy_vpnglobal_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy_vpnglobal_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationcertpolicy_vpnglobal_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy_vpnglobal_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationcertpolicy_vpnglobal_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy_vpnglobal_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationcertpolicyvpnglobalbinding: Ended" } } function Invoke-ADCGetAuthenticationcertpolicyvpnvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the vpnvserver that can be bound to authenticationcertpolicy. .PARAMETER Name Name of the client cert authentication policy. .PARAMETER GetAll Retrieve all authenticationcertpolicy_vpnvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationcertpolicy_vpnvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicyvpnvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicyvpnvserverbinding -GetAll Get all authenticationcertpolicy_vpnvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicyvpnvserverbinding -Count Get the number of authenticationcertpolicy_vpnvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicyvpnvserverbinding -name <string> Get authenticationcertpolicy_vpnvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcertpolicyvpnvserverbinding -Filter @{ 'name'='<value>' } Get authenticationcertpolicy_vpnvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationcertpolicyvpnvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcertpolicy_vpnvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationcertpolicyvpnvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationcertpolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationcertpolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationcertpolicy_vpnvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy_vpnvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationcertpolicy_vpnvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy_vpnvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationcertpolicy_vpnvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcertpolicy_vpnvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationcertpolicyvpnvserverbinding: Ended" } } function Invoke-ADCAddAuthenticationcitrixauthaction { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for Citrix Authentication action resource. .PARAMETER Name Name for the new Citrix Authentication action. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. The following requirement applies only to the NetScaler CLI: If the name includes one or more spaces, enclose the name in double or single quotation marks (for example, "my action" or 'my action'). .PARAMETER Authenticationtype Type of the Citrix Authentication implementation. Default implementation uses Citrix Cloud Connector. Possible values = CITRIXCONNECTOR, ATHENA .PARAMETER Authentication Authentication needs to be disabled for searching user object without performing authentication. Possible values = ENABLED, DISABLED .PARAMETER PassThru Return details about the created authenticationcitrixauthaction item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationcitrixauthaction -name <string> An example how to add authenticationcitrixauthaction configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationcitrixauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcitrixauthaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [ValidateSet('CITRIXCONNECTOR', 'ATHENA')] [string]$Authenticationtype = 'CITRIXCONNECTOR', [ValidateSet('ENABLED', 'DISABLED')] [string]$Authentication = 'ENABLED', [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationcitrixauthaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('authenticationtype') ) { $payload.Add('authenticationtype', $authenticationtype) } if ( $PSBoundParameters.ContainsKey('authentication') ) { $payload.Add('authentication', $authentication) } if ( $PSCmdlet.ShouldProcess("authenticationcitrixauthaction", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationcitrixauthaction -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationcitrixauthaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationcitrixauthaction: Finished" } } function Invoke-ADCDeleteAuthenticationcitrixauthaction { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for Citrix Authentication action resource. .PARAMETER Name Name for the new Citrix Authentication action. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. The following requirement applies only to the NetScaler CLI: If the name includes one or more spaces, enclose the name in double or single quotation marks (for example, "my action" or 'my action'). .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationcitrixauthaction -Name <string> An example how to delete authenticationcitrixauthaction configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationcitrixauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcitrixauthaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationcitrixauthaction: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationcitrixauthaction -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationcitrixauthaction: Finished" } } function Invoke-ADCUpdateAuthenticationcitrixauthaction { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for Citrix Authentication action resource. .PARAMETER Name Name for the new Citrix Authentication action. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. The following requirement applies only to the NetScaler CLI: If the name includes one or more spaces, enclose the name in double or single quotation marks (for example, "my action" or 'my action'). .PARAMETER Authenticationtype Type of the Citrix Authentication implementation. Default implementation uses Citrix Cloud Connector. Possible values = CITRIXCONNECTOR, ATHENA .PARAMETER Authentication Authentication needs to be disabled for searching user object without performing authentication. Possible values = ENABLED, DISABLED .PARAMETER PassThru Return details about the created authenticationcitrixauthaction item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationcitrixauthaction -name <string> An example how to update authenticationcitrixauthaction configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationcitrixauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcitrixauthaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [ValidateSet('CITRIXCONNECTOR', 'ATHENA')] [string]$Authenticationtype, [ValidateSet('ENABLED', 'DISABLED')] [string]$Authentication, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationcitrixauthaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('authenticationtype') ) { $payload.Add('authenticationtype', $authenticationtype) } if ( $PSBoundParameters.ContainsKey('authentication') ) { $payload.Add('authentication', $authentication) } if ( $PSCmdlet.ShouldProcess("authenticationcitrixauthaction", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationcitrixauthaction -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationcitrixauthaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationcitrixauthaction: Finished" } } function Invoke-ADCUnsetAuthenticationcitrixauthaction { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for Citrix Authentication action resource. .PARAMETER Name Name for the new Citrix Authentication action. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. The following requirement applies only to the NetScaler CLI: If the name includes one or more spaces, enclose the name in double or single quotation marks (for example, "my action" or 'my action'). .PARAMETER Authenticationtype Type of the Citrix Authentication implementation. Default implementation uses Citrix Cloud Connector. Possible values = CITRIXCONNECTOR, ATHENA .PARAMETER Authentication Authentication needs to be disabled for searching user object without performing authentication. Possible values = ENABLED, DISABLED .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationcitrixauthaction -name <string> An example how to unset authenticationcitrixauthaction configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationcitrixauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcitrixauthaction Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Boolean]$authenticationtype, [Boolean]$authentication ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationcitrixauthaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('authenticationtype') ) { $payload.Add('authenticationtype', $authenticationtype) } if ( $PSBoundParameters.ContainsKey('authentication') ) { $payload.Add('authentication', $authentication) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationcitrixauthaction -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationcitrixauthaction: Finished" } } function Invoke-ADCGetAuthenticationcitrixauthaction { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for Citrix Authentication action resource. .PARAMETER Name Name for the new Citrix Authentication action. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. The following requirement applies only to the NetScaler CLI: If the name includes one or more spaces, enclose the name in double or single quotation marks (for example, "my action" or 'my action'). .PARAMETER GetAll Retrieve all authenticationcitrixauthaction object(s). .PARAMETER Count If specified, the count of the authenticationcitrixauthaction object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcitrixauthaction Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcitrixauthaction -GetAll Get all authenticationcitrixauthaction data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcitrixauthaction -Count Get the number of authenticationcitrixauthaction objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcitrixauthaction -name <string> Get authenticationcitrixauthaction object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationcitrixauthaction -Filter @{ 'name'='<value>' } Get authenticationcitrixauthaction data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationcitrixauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationcitrixauthaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationcitrixauthaction: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationcitrixauthaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcitrixauthaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationcitrixauthaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcitrixauthaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationcitrixauthaction objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcitrixauthaction -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationcitrixauthaction configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcitrixauthaction -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationcitrixauthaction configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationcitrixauthaction -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationcitrixauthaction: Ended" } } function Invoke-ADCUnsetAuthenticationdfaaction { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for Dfa authentication action resource. .PARAMETER Name Name for the DFA action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the DFA action is added. .PARAMETER Clientid If configured, this string is sent to the DFA server as the X-Citrix-Exchange header value. .PARAMETER Serverurl DFA Server URL. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationdfaaction -name <string> An example how to unset authenticationdfaaction configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationdfaaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationdfaaction Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Boolean]$clientid, [Boolean]$serverurl, [Boolean]$defaultauthenticationgroup ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationdfaaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('clientid') ) { $payload.Add('clientid', $clientid) } if ( $PSBoundParameters.ContainsKey('serverurl') ) { $payload.Add('serverurl', $serverurl) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationdfaaction -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationdfaaction: Finished" } } function Invoke-ADCDeleteAuthenticationdfaaction { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for Dfa authentication action resource. .PARAMETER Name Name for the DFA action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the DFA action is added. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationdfaaction -Name <string> An example how to delete authenticationdfaaction configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationdfaaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationdfaaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationdfaaction: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationdfaaction -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationdfaaction: Finished" } } function Invoke-ADCUpdateAuthenticationdfaaction { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for Dfa authentication action resource. .PARAMETER Name Name for the DFA action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the DFA action is added. .PARAMETER Clientid If configured, this string is sent to the DFA server as the X-Citrix-Exchange header value. .PARAMETER Serverurl DFA Server URL. .PARAMETER Passphrase Key shared between the DFA server and the Citrix ADC. Required to allow the Citrix ADC to communicate with the DFA server. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER PassThru Return details about the created authenticationdfaaction item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationdfaaction -name <string> An example how to update authenticationdfaaction configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationdfaaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationdfaaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Clientid, [string]$Serverurl, [ValidateScript({ $_.Length -gt 1 })] [string]$Passphrase, [string]$Defaultauthenticationgroup, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationdfaaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('clientid') ) { $payload.Add('clientid', $clientid) } if ( $PSBoundParameters.ContainsKey('serverurl') ) { $payload.Add('serverurl', $serverurl) } if ( $PSBoundParameters.ContainsKey('passphrase') ) { $payload.Add('passphrase', $passphrase) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSCmdlet.ShouldProcess("authenticationdfaaction", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationdfaaction -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationdfaaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationdfaaction: Finished" } } function Invoke-ADCAddAuthenticationdfaaction { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for Dfa authentication action resource. .PARAMETER Name Name for the DFA action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the DFA action is added. .PARAMETER Clientid If configured, this string is sent to the DFA server as the X-Citrix-Exchange header value. .PARAMETER Serverurl DFA Server URL. .PARAMETER Passphrase Key shared between the DFA server and the Citrix ADC. Required to allow the Citrix ADC to communicate with the DFA server. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER PassThru Return details about the created authenticationdfaaction item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationdfaaction -name <string> -clientid <string> -serverurl <string> -passphrase <string> An example how to add authenticationdfaaction configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationdfaaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationdfaaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(Mandatory)] [string]$Clientid, [Parameter(Mandatory)] [string]$Serverurl, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Passphrase, [string]$Defaultauthenticationgroup, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationdfaaction: Starting" } process { try { $payload = @{ name = $name clientid = $clientid serverurl = $serverurl passphrase = $passphrase } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSCmdlet.ShouldProcess("authenticationdfaaction", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationdfaaction -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationdfaaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationdfaaction: Finished" } } function Invoke-ADCGetAuthenticationdfaaction { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for Dfa authentication action resource. .PARAMETER Name Name for the DFA action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the DFA action is added. .PARAMETER GetAll Retrieve all authenticationdfaaction object(s). .PARAMETER Count If specified, the count of the authenticationdfaaction object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationdfaaction Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationdfaaction -GetAll Get all authenticationdfaaction data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationdfaaction -Count Get the number of authenticationdfaaction objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationdfaaction -name <string> Get authenticationdfaaction object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationdfaaction -Filter @{ 'name'='<value>' } Get authenticationdfaaction data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationdfaaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationdfaaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationdfaaction: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationdfaaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationdfaaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationdfaaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationdfaaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationdfaaction objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationdfaaction -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationdfaaction configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationdfaaction -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationdfaaction configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationdfaaction -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationdfaaction: Ended" } } function Invoke-ADCAddAuthenticationdfapolicy { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for Dfa authentication policy resource. .PARAMETER Name Name for the DFA policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after DFA policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to determine whether to attempt to authenticate the user with the Web server. .PARAMETER Action Name of the DFA action to perform if the policy matches. .PARAMETER PassThru Return details about the created authenticationdfapolicy item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationdfapolicy -name <string> -rule <string> -action <string> An example how to add authenticationdfapolicy configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationdfapolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationdfapolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Rule, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Action, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationdfapolicy: Starting" } process { try { $payload = @{ name = $name rule = $rule action = $action } if ( $PSCmdlet.ShouldProcess("authenticationdfapolicy", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationdfapolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationdfapolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationdfapolicy: Finished" } } function Invoke-ADCDeleteAuthenticationdfapolicy { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for Dfa authentication policy resource. .PARAMETER Name Name for the DFA policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after DFA policy is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationdfapolicy -Name <string> An example how to delete authenticationdfapolicy configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationdfapolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationdfapolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationdfapolicy: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationdfapolicy -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationdfapolicy: Finished" } } function Invoke-ADCUpdateAuthenticationdfapolicy { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for Dfa authentication policy resource. .PARAMETER Name Name for the DFA policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after DFA policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to determine whether to attempt to authenticate the user with the Web server. .PARAMETER Action Name of the DFA action to perform if the policy matches. .PARAMETER PassThru Return details about the created authenticationdfapolicy item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationdfapolicy -name <string> An example how to update authenticationdfapolicy configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationdfapolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationdfapolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Rule, [ValidateScript({ $_.Length -gt 1 })] [string]$Action, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationdfapolicy: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('rule') ) { $payload.Add('rule', $rule) } if ( $PSBoundParameters.ContainsKey('action') ) { $payload.Add('action', $action) } if ( $PSCmdlet.ShouldProcess("authenticationdfapolicy", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationdfapolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationdfapolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationdfapolicy: Finished" } } function Invoke-ADCGetAuthenticationdfapolicy { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for Dfa authentication policy resource. .PARAMETER Name Name for the DFA policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after DFA policy is created. .PARAMETER GetAll Retrieve all authenticationdfapolicy object(s). .PARAMETER Count If specified, the count of the authenticationdfapolicy object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationdfapolicy Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationdfapolicy -GetAll Get all authenticationdfapolicy data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationdfapolicy -Count Get the number of authenticationdfapolicy objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationdfapolicy -name <string> Get authenticationdfapolicy object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationdfapolicy -Filter @{ 'name'='<value>' } Get authenticationdfapolicy data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationdfapolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationdfapolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationdfapolicy: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationdfapolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationdfapolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationdfapolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationdfapolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationdfapolicy objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationdfapolicy -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationdfapolicy configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationdfapolicy -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationdfapolicy configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationdfapolicy -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationdfapolicy: Ended" } } function Invoke-ADCGetAuthenticationdfapolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object which returns the resources bound to authenticationdfapolicy. .PARAMETER Name Name of the WebAuth policy. .PARAMETER GetAll Retrieve all authenticationdfapolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationdfapolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationdfapolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationdfapolicybinding -GetAll Get all authenticationdfapolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationdfapolicybinding -name <string> Get authenticationdfapolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationdfapolicybinding -Filter @{ 'name'='<value>' } Get authenticationdfapolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationdfapolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationdfapolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationdfapolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationdfapolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationdfapolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationdfapolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationdfapolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationdfapolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationdfapolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationdfapolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationdfapolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationdfapolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationdfapolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationdfapolicybinding: Ended" } } function Invoke-ADCGetAuthenticationdfapolicyvpnvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the vpnvserver that can be bound to authenticationdfapolicy. .PARAMETER Name Name of the WebAuth policy. .PARAMETER GetAll Retrieve all authenticationdfapolicy_vpnvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationdfapolicy_vpnvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationdfapolicyvpnvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationdfapolicyvpnvserverbinding -GetAll Get all authenticationdfapolicy_vpnvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationdfapolicyvpnvserverbinding -Count Get the number of authenticationdfapolicy_vpnvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationdfapolicyvpnvserverbinding -name <string> Get authenticationdfapolicy_vpnvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationdfapolicyvpnvserverbinding -Filter @{ 'name'='<value>' } Get authenticationdfapolicy_vpnvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationdfapolicyvpnvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationdfapolicy_vpnvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationdfapolicyvpnvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationdfapolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationdfapolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationdfapolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationdfapolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationdfapolicy_vpnvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationdfapolicy_vpnvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationdfapolicy_vpnvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationdfapolicy_vpnvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationdfapolicy_vpnvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationdfapolicy_vpnvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationdfapolicyvpnvserverbinding: Ended" } } function Invoke-ADCAddAuthenticationemailaction { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for Email entity resource. .PARAMETER Name Name for the new email action. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER Username Username/Clientid/EmailID to be used to authenticate to the server. .PARAMETER Password Password/Clientsecret to use when authenticating to the server. .PARAMETER Serverurl Address of the server that delivers the message. It is fully qualified fqdn such as http(s):// or smtp(s):// for http and smtp protocols respectively. For SMTP, the port number is mandatory like smtps://smtp.example.com:25. .PARAMETER Content Content to be delivered to the user. "$code" string within the content will be replaced with the actual one-time-code to be sent. .PARAMETER Defaultauthenticationgroup This is the group that is added to user sessions that match current IdP policy. It can be used in policies to identify relying party trust. .PARAMETER Timeout Time after which the code expires. .PARAMETER Type Type of the email action. Default type is SMTP. Possible values = SMTP, ATHENA .PARAMETER Emailaddress An optional expression that yields user's email. When not configured, user's default mail address would be used. When configured, result of this expression is used as destination email address. .PARAMETER PassThru Return details about the created authenticationemailaction item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationemailaction -name <string> -username <string> -password <string> -serverurl <string> An example how to add authenticationemailaction configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationemailaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationemailaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Username, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Password, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Serverurl, [string]$Content, [string]$Defaultauthenticationgroup, [double]$Timeout = '180', [ValidateSet('SMTP', 'ATHENA')] [string]$Type = 'SMTP', [string]$Emailaddress, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationemailaction: Starting" } process { try { $payload = @{ name = $name username = $username password = $password serverurl = $serverurl } if ( $PSBoundParameters.ContainsKey('content') ) { $payload.Add('content', $content) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('timeout') ) { $payload.Add('timeout', $timeout) } if ( $PSBoundParameters.ContainsKey('type') ) { $payload.Add('type', $type) } if ( $PSBoundParameters.ContainsKey('emailaddress') ) { $payload.Add('emailaddress', $emailaddress) } if ( $PSCmdlet.ShouldProcess("authenticationemailaction", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationemailaction -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationemailaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationemailaction: Finished" } } function Invoke-ADCDeleteAuthenticationemailaction { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for Email entity resource. .PARAMETER Name Name for the new email action. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationemailaction -Name <string> An example how to delete authenticationemailaction configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationemailaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationemailaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationemailaction: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationemailaction -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationemailaction: Finished" } } function Invoke-ADCUpdateAuthenticationemailaction { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for Email entity resource. .PARAMETER Name Name for the new email action. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER Username Username/Clientid/EmailID to be used to authenticate to the server. .PARAMETER Password Password/Clientsecret to use when authenticating to the server. .PARAMETER Serverurl Address of the server that delivers the message. It is fully qualified fqdn such as http(s):// or smtp(s):// for http and smtp protocols respectively. For SMTP, the port number is mandatory like smtps://smtp.example.com:25. .PARAMETER Content Content to be delivered to the user. "$code" string within the content will be replaced with the actual one-time-code to be sent. .PARAMETER Defaultauthenticationgroup This is the group that is added to user sessions that match current IdP policy. It can be used in policies to identify relying party trust. .PARAMETER Timeout Time after which the code expires. .PARAMETER Type Type of the email action. Default type is SMTP. Possible values = SMTP, ATHENA .PARAMETER Emailaddress An optional expression that yields user's email. When not configured, user's default mail address would be used. When configured, result of this expression is used as destination email address. .PARAMETER PassThru Return details about the created authenticationemailaction item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationemailaction -name <string> An example how to update authenticationemailaction configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationemailaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationemailaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Username, [ValidateScript({ $_.Length -gt 1 })] [string]$Password, [ValidateScript({ $_.Length -gt 1 })] [string]$Serverurl, [string]$Content, [string]$Defaultauthenticationgroup, [double]$Timeout, [ValidateSet('SMTP', 'ATHENA')] [string]$Type, [string]$Emailaddress, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationemailaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('username') ) { $payload.Add('username', $username) } if ( $PSBoundParameters.ContainsKey('password') ) { $payload.Add('password', $password) } if ( $PSBoundParameters.ContainsKey('serverurl') ) { $payload.Add('serverurl', $serverurl) } if ( $PSBoundParameters.ContainsKey('content') ) { $payload.Add('content', $content) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('timeout') ) { $payload.Add('timeout', $timeout) } if ( $PSBoundParameters.ContainsKey('type') ) { $payload.Add('type', $type) } if ( $PSBoundParameters.ContainsKey('emailaddress') ) { $payload.Add('emailaddress', $emailaddress) } if ( $PSCmdlet.ShouldProcess("authenticationemailaction", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationemailaction -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationemailaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationemailaction: Finished" } } function Invoke-ADCUnsetAuthenticationemailaction { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for Email entity resource. .PARAMETER Name Name for the new email action. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER Content Content to be delivered to the user. "$code" string within the content will be replaced with the actual one-time-code to be sent. .PARAMETER Defaultauthenticationgroup This is the group that is added to user sessions that match current IdP policy. It can be used in policies to identify relying party trust. .PARAMETER Timeout Time after which the code expires. .PARAMETER Type Type of the email action. Default type is SMTP. Possible values = SMTP, ATHENA .PARAMETER Emailaddress An optional expression that yields user's email. When not configured, user's default mail address would be used. When configured, result of this expression is used as destination email address. .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationemailaction -name <string> An example how to unset authenticationemailaction configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationemailaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationemailaction Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Boolean]$content, [Boolean]$defaultauthenticationgroup, [Boolean]$timeout, [Boolean]$type, [Boolean]$emailaddress ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationemailaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('content') ) { $payload.Add('content', $content) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('timeout') ) { $payload.Add('timeout', $timeout) } if ( $PSBoundParameters.ContainsKey('type') ) { $payload.Add('type', $type) } if ( $PSBoundParameters.ContainsKey('emailaddress') ) { $payload.Add('emailaddress', $emailaddress) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationemailaction -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationemailaction: Finished" } } function Invoke-ADCGetAuthenticationemailaction { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for Email entity resource. .PARAMETER Name Name for the new email action. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER GetAll Retrieve all authenticationemailaction object(s). .PARAMETER Count If specified, the count of the authenticationemailaction object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationemailaction Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationemailaction -GetAll Get all authenticationemailaction data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationemailaction -Count Get the number of authenticationemailaction objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationemailaction -name <string> Get authenticationemailaction object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationemailaction -Filter @{ 'name'='<value>' } Get authenticationemailaction data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationemailaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationemailaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationemailaction: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationemailaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationemailaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationemailaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationemailaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationemailaction objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationemailaction -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationemailaction configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationemailaction -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationemailaction configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationemailaction -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationemailaction: Ended" } } function Invoke-ADCAddAuthenticationepaaction { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for epa action resource. .PARAMETER Name Name for the epa action. Must begin with a letter, number, or the underscore character (_), and must consist only of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after epa action is created. .PARAMETER Csecexpr it holds the ClientSecurityExpression to be sent to the client. .PARAMETER Killprocess String specifying the name of a process to be terminated by the endpoint analysis (EPA) tool. Multiple processes to be delimited by comma. .PARAMETER Deletefiles String specifying the path(s) and name(s) of the files to be deleted by the endpoint analysis (EPA) tool. Multiple files to be delimited by comma. .PARAMETER Defaultepagroup This is the default group that is chosen when the EPA check succeeds. .PARAMETER Quarantinegroup This is the quarantine group that is chosen when the EPA check fails if configured. .PARAMETER PassThru Return details about the created authenticationepaaction item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationepaaction -name <string> -csecexpr <string> An example how to add authenticationepaaction configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationepaaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationepaaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(Mandatory)] [string]$Csecexpr, [string]$Killprocess, [string]$Deletefiles, [string]$Defaultepagroup, [string]$Quarantinegroup, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationepaaction: Starting" } process { try { $payload = @{ name = $name csecexpr = $csecexpr } if ( $PSBoundParameters.ContainsKey('killprocess') ) { $payload.Add('killprocess', $killprocess) } if ( $PSBoundParameters.ContainsKey('deletefiles') ) { $payload.Add('deletefiles', $deletefiles) } if ( $PSBoundParameters.ContainsKey('defaultepagroup') ) { $payload.Add('defaultepagroup', $defaultepagroup) } if ( $PSBoundParameters.ContainsKey('quarantinegroup') ) { $payload.Add('quarantinegroup', $quarantinegroup) } if ( $PSCmdlet.ShouldProcess("authenticationepaaction", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationepaaction -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationepaaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationepaaction: Finished" } } function Invoke-ADCDeleteAuthenticationepaaction { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for epa action resource. .PARAMETER Name Name for the epa action. Must begin with a letter, number, or the underscore character (_), and must consist only of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after epa action is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationepaaction -Name <string> An example how to delete authenticationepaaction configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationepaaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationepaaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationepaaction: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationepaaction -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationepaaction: Finished" } } function Invoke-ADCUpdateAuthenticationepaaction { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for epa action resource. .PARAMETER Name Name for the epa action. Must begin with a letter, number, or the underscore character (_), and must consist only of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after epa action is created. .PARAMETER Csecexpr it holds the ClientSecurityExpression to be sent to the client. .PARAMETER Killprocess String specifying the name of a process to be terminated by the endpoint analysis (EPA) tool. Multiple processes to be delimited by comma. .PARAMETER Deletefiles String specifying the path(s) and name(s) of the files to be deleted by the endpoint analysis (EPA) tool. Multiple files to be delimited by comma. .PARAMETER Defaultepagroup This is the default group that is chosen when the EPA check succeeds. .PARAMETER Quarantinegroup This is the quarantine group that is chosen when the EPA check fails if configured. .PARAMETER PassThru Return details about the created authenticationepaaction item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationepaaction -name <string> An example how to update authenticationepaaction configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationepaaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationepaaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Csecexpr, [string]$Killprocess, [string]$Deletefiles, [string]$Defaultepagroup, [string]$Quarantinegroup, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationepaaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('csecexpr') ) { $payload.Add('csecexpr', $csecexpr) } if ( $PSBoundParameters.ContainsKey('killprocess') ) { $payload.Add('killprocess', $killprocess) } if ( $PSBoundParameters.ContainsKey('deletefiles') ) { $payload.Add('deletefiles', $deletefiles) } if ( $PSBoundParameters.ContainsKey('defaultepagroup') ) { $payload.Add('defaultepagroup', $defaultepagroup) } if ( $PSBoundParameters.ContainsKey('quarantinegroup') ) { $payload.Add('quarantinegroup', $quarantinegroup) } if ( $PSCmdlet.ShouldProcess("authenticationepaaction", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationepaaction -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationepaaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationepaaction: Finished" } } function Invoke-ADCUnsetAuthenticationepaaction { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for epa action resource. .PARAMETER Name Name for the epa action. Must begin with a letter, number, or the underscore character (_), and must consist only of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after epa action is created. .PARAMETER Killprocess String specifying the name of a process to be terminated by the endpoint analysis (EPA) tool. Multiple processes to be delimited by comma. .PARAMETER Deletefiles String specifying the path(s) and name(s) of the files to be deleted by the endpoint analysis (EPA) tool. Multiple files to be delimited by comma. .PARAMETER Defaultepagroup This is the default group that is chosen when the EPA check succeeds. .PARAMETER Quarantinegroup This is the quarantine group that is chosen when the EPA check fails if configured. .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationepaaction -name <string> An example how to unset authenticationepaaction configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationepaaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationepaaction Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Boolean]$killprocess, [Boolean]$deletefiles, [Boolean]$defaultepagroup, [Boolean]$quarantinegroup ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationepaaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('killprocess') ) { $payload.Add('killprocess', $killprocess) } if ( $PSBoundParameters.ContainsKey('deletefiles') ) { $payload.Add('deletefiles', $deletefiles) } if ( $PSBoundParameters.ContainsKey('defaultepagroup') ) { $payload.Add('defaultepagroup', $defaultepagroup) } if ( $PSBoundParameters.ContainsKey('quarantinegroup') ) { $payload.Add('quarantinegroup', $quarantinegroup) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationepaaction -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationepaaction: Finished" } } function Invoke-ADCGetAuthenticationepaaction { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for epa action resource. .PARAMETER Name Name for the epa action. Must begin with a letter, number, or the underscore character (_), and must consist only of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after epa action is created. .PARAMETER GetAll Retrieve all authenticationepaaction object(s). .PARAMETER Count If specified, the count of the authenticationepaaction object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationepaaction Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationepaaction -GetAll Get all authenticationepaaction data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationepaaction -Count Get the number of authenticationepaaction objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationepaaction -name <string> Get authenticationepaaction object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationepaaction -Filter @{ 'name'='<value>' } Get authenticationepaaction data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationepaaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationepaaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationepaaction: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationepaaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationepaaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationepaaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationepaaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationepaaction objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationepaaction -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationepaaction configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationepaaction -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationepaaction configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationepaaction -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationepaaction: Ended" } } function Invoke-ADCUnsetAuthenticationldapaction { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for LDAP action resource. .PARAMETER Name Name for the new LDAP action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the LDAP action is added. .PARAMETER Serverport Port on which the LDAP server accepts connections. .PARAMETER Authtimeout Number of seconds the Citrix ADC waits for a response from the RADIUS server. .PARAMETER Ldapbase Base (node) from which to start LDAP searches. If the LDAP server is running locally, the default value of base is dc=netscaler, dc=com. .PARAMETER Ldapbinddn Full distinguished name (DN) that is used to bind to the LDAP server. Default: cn=Manager,dc=netscaler,dc=com. .PARAMETER Ldapbinddnpassword Password used to bind to the LDAP server. .PARAMETER Ldaploginname LDAP login name attribute. The Citrix ADC uses the LDAP login name to query external LDAP servers or Active Directories. .PARAMETER Searchfilter String to be combined with the default LDAP user search string to form the search value. For example, if the search filter "vpnallowed=true" is combined with the LDAP login name "samaccount" and the user-supplied username is "bob", the result is the LDAP search string ""(;(vpnallowed=true)(samaccount=bob)"" (Be sure to enclose the search string in two sets of double quotation marks; both sets are needed.). .PARAMETER Groupattrname LDAP group attribute name. Used for group extraction on the LDAP server. .PARAMETER Subattributename LDAP group sub-attribute name. Used for group extraction from the LDAP server. .PARAMETER Sectype Type of security used for communications between the Citrix ADC and the LDAP server. For the PLAINTEXT setting, no encryption is required. Possible values = PLAINTEXT, TLS, SSL .PARAMETER Svrtype The type of LDAP server. Possible values = AD, NDS .PARAMETER Ssonameattribute LDAP single signon (SSO) attribute. The Citrix ADC uses the SSO name attribute to query external LDAP servers or Active Directories for an alternate username. .PARAMETER Authentication Perform LDAP authentication. If authentication is disabled, any LDAP authentication attempt returns authentication success if the user is found. CAUTION! Authentication should be disabled only for authorization group extraction or where other (non-LDAP) authentication methods are in use and either bound to a primary list or flagged as secondary. Possible values = ENABLED, DISABLED .PARAMETER Requireuser Require a successful user search for authentication. CAUTION! This field should be set to NO only if usersearch not required [Both username validation as well as password validation skipped] and (non-LDAP) authentication methods are in use and either bound to a primary list or flagged as secondary. Possible values = YES, NO .PARAMETER Passwdchange Allow password change requests. Possible values = ENABLED, DISABLED .PARAMETER Validateservercert When to validate LDAP server certs. Possible values = YES, NO .PARAMETER Ldaphostname Hostname for the LDAP server. If -validateServerCert is ON then this must be the host name on the certificate from the LDAP server. A hostname mismatch will cause a connection failure. .PARAMETER Nestedgroupextraction Allow nested group extraction, in which the Citrix ADC queries external LDAP servers to determine whether a group is part of another group. Possible values = ON, OFF .PARAMETER Maxnestinglevel If nested group extraction is ON, specifies the number of levels up to which group extraction is performed. .PARAMETER Groupnameidentifier Name that uniquely identifies a group in LDAP or Active Directory. .PARAMETER Groupsearchattribute LDAP group search attribute. Used to determine to which groups a group belongs. .PARAMETER Groupsearchsubattribute LDAP group search subattribute. Used to determine to which groups a group belongs. .PARAMETER Groupsearchfilter String to be combined with the default LDAP group search string to form the search value. For example, the group search filter ""vpnallowed=true"" when combined with the group identifier ""samaccount"" and the group name ""g1"" yields the LDAP search string ""(;(vpnallowed=true)(samaccount=g1)"". If nestedGroupExtraction is ENABLED, the filter is applied on the first level group search as well, otherwise first level groups (of which user is a direct member of) will be fetched without applying this filter. (Be sure to enclose the search string in two sets of double quotation marks; both sets are needed.). .PARAMETER Followreferrals Setting this option to ON enables following LDAP referrals received from the LDAP server. Possible values = ON, OFF .PARAMETER Maxldapreferrals Specifies the maximum number of nested referrals to follow. .PARAMETER Referraldnslookup Specifies the DNS Record lookup Type for the referrals. Possible values = A-REC, SRV-REC, MSSRV-REC .PARAMETER Mssrvrecordlocation MSSRV Specific parameter. Used to locate the DNS node to which the SRV record pertains in the domainname. The domainname is appended to it to form the srv record. Example : For "dc._msdcs", the srv record formed is _ldap._tcp.dc._msdcs.<domainname>. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER Attribute1 Expression that would be evaluated to extract attribute1 from the ldap response. .PARAMETER Attribute2 Expression that would be evaluated to extract attribute2 from the ldap response. .PARAMETER Attribute3 Expression that would be evaluated to extract attribute3 from the ldap response. .PARAMETER Attribute4 Expression that would be evaluated to extract attribute4 from the ldap response. .PARAMETER Attribute5 Expression that would be evaluated to extract attribute5 from the ldap response. .PARAMETER Attribute6 Expression that would be evaluated to extract attribute6 from the ldap response. .PARAMETER Attribute7 Expression that would be evaluated to extract attribute7 from the ldap response. .PARAMETER Attribute8 Expression that would be evaluated to extract attribute8 from the ldap response. .PARAMETER Attribute9 Expression that would be evaluated to extract attribute9 from the ldap response. .PARAMETER Attribute10 Expression that would be evaluated to extract attribute10 from the ldap response. .PARAMETER Attribute11 Expression that would be evaluated to extract attribute11 from the ldap response. .PARAMETER Attribute12 Expression that would be evaluated to extract attribute12 from the ldap response. .PARAMETER Attribute13 Expression that would be evaluated to extract attribute13 from the ldap response. .PARAMETER Attribute14 Expression that would be evaluated to extract attribute14 from the ldap response. .PARAMETER Attribute15 Expression that would be evaluated to extract attribute15 from the ldap response. .PARAMETER Attribute16 Expression that would be evaluated to extract attribute16 from the ldap response. .PARAMETER Attributes List of attribute names separated by ',' which needs to be fetched from ldap server. Note that preceeding and trailing spaces will be removed. Attribute name can be 127 bytes and total length of this string should not cross 2047 bytes. These attributes have multi-value support separated by ',' and stored as key-value pair in AAA session. .PARAMETER Otpsecret OneTimePassword(OTP) Secret key attribute on AD. This attribute is used to store and retrieve secret key used for OTP check. .PARAMETER Pushservice Name of the service used to send push notifications. .PARAMETER Email The Citrix ADC uses the email attribute to query the Active Directory for the email id of a user. .PARAMETER Kbattribute KnowledgeBasedAuthentication(KBA) attribute on AD. This attribute is used to store and retrieve preconfigured Question and Answer knowledge base used for KBA authentication. .PARAMETER Alternateemailattr The NetScaler appliance uses the alternateive email attribute to query the Active Directory for the alternative email id of a user. .PARAMETER Cloudattributes The Citrix ADC uses the cloud attributes to extract additional attributes from LDAP servers required for Citrix Cloud operations. Possible values = ENABLED, DISABLED .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationldapaction -name <string> An example how to unset authenticationldapaction configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationldapaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationldapaction Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Boolean]$serverport, [Boolean]$authtimeout, [Boolean]$ldapbase, [Boolean]$ldapbinddn, [Boolean]$ldapbinddnpassword, [Boolean]$ldaploginname, [Boolean]$searchfilter, [Boolean]$groupattrname, [Boolean]$subattributename, [Boolean]$sectype, [Boolean]$svrtype, [Boolean]$ssonameattribute, [Boolean]$authentication, [Boolean]$requireuser, [Boolean]$passwdchange, [Boolean]$validateservercert, [Boolean]$ldaphostname, [Boolean]$nestedgroupextraction, [Boolean]$maxnestinglevel, [Boolean]$groupnameidentifier, [Boolean]$groupsearchattribute, [Boolean]$groupsearchsubattribute, [Boolean]$groupsearchfilter, [Boolean]$followreferrals, [Boolean]$maxldapreferrals, [Boolean]$referraldnslookup, [Boolean]$mssrvrecordlocation, [Boolean]$defaultauthenticationgroup, [Boolean]$attribute1, [Boolean]$attribute2, [Boolean]$attribute3, [Boolean]$attribute4, [Boolean]$attribute5, [Boolean]$attribute6, [Boolean]$attribute7, [Boolean]$attribute8, [Boolean]$attribute9, [Boolean]$attribute10, [Boolean]$attribute11, [Boolean]$attribute12, [Boolean]$attribute13, [Boolean]$attribute14, [Boolean]$attribute15, [Boolean]$attribute16, [Boolean]$attributes, [Boolean]$otpsecret, [Boolean]$pushservice, [Boolean]$email, [Boolean]$kbattribute, [Boolean]$alternateemailattr, [Boolean]$cloudattributes ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationldapaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('serverport') ) { $payload.Add('serverport', $serverport) } if ( $PSBoundParameters.ContainsKey('authtimeout') ) { $payload.Add('authtimeout', $authtimeout) } if ( $PSBoundParameters.ContainsKey('ldapbase') ) { $payload.Add('ldapbase', $ldapbase) } if ( $PSBoundParameters.ContainsKey('ldapbinddn') ) { $payload.Add('ldapbinddn', $ldapbinddn) } if ( $PSBoundParameters.ContainsKey('ldapbinddnpassword') ) { $payload.Add('ldapbinddnpassword', $ldapbinddnpassword) } if ( $PSBoundParameters.ContainsKey('ldaploginname') ) { $payload.Add('ldaploginname', $ldaploginname) } if ( $PSBoundParameters.ContainsKey('searchfilter') ) { $payload.Add('searchfilter', $searchfilter) } if ( $PSBoundParameters.ContainsKey('groupattrname') ) { $payload.Add('groupattrname', $groupattrname) } if ( $PSBoundParameters.ContainsKey('subattributename') ) { $payload.Add('subattributename', $subattributename) } if ( $PSBoundParameters.ContainsKey('sectype') ) { $payload.Add('sectype', $sectype) } if ( $PSBoundParameters.ContainsKey('svrtype') ) { $payload.Add('svrtype', $svrtype) } if ( $PSBoundParameters.ContainsKey('ssonameattribute') ) { $payload.Add('ssonameattribute', $ssonameattribute) } if ( $PSBoundParameters.ContainsKey('authentication') ) { $payload.Add('authentication', $authentication) } if ( $PSBoundParameters.ContainsKey('requireuser') ) { $payload.Add('requireuser', $requireuser) } if ( $PSBoundParameters.ContainsKey('passwdchange') ) { $payload.Add('passwdchange', $passwdchange) } if ( $PSBoundParameters.ContainsKey('validateservercert') ) { $payload.Add('validateservercert', $validateservercert) } if ( $PSBoundParameters.ContainsKey('ldaphostname') ) { $payload.Add('ldaphostname', $ldaphostname) } if ( $PSBoundParameters.ContainsKey('nestedgroupextraction') ) { $payload.Add('nestedgroupextraction', $nestedgroupextraction) } if ( $PSBoundParameters.ContainsKey('maxnestinglevel') ) { $payload.Add('maxnestinglevel', $maxnestinglevel) } if ( $PSBoundParameters.ContainsKey('groupnameidentifier') ) { $payload.Add('groupnameidentifier', $groupnameidentifier) } if ( $PSBoundParameters.ContainsKey('groupsearchattribute') ) { $payload.Add('groupsearchattribute', $groupsearchattribute) } if ( $PSBoundParameters.ContainsKey('groupsearchsubattribute') ) { $payload.Add('groupsearchsubattribute', $groupsearchsubattribute) } if ( $PSBoundParameters.ContainsKey('groupsearchfilter') ) { $payload.Add('groupsearchfilter', $groupsearchfilter) } if ( $PSBoundParameters.ContainsKey('followreferrals') ) { $payload.Add('followreferrals', $followreferrals) } if ( $PSBoundParameters.ContainsKey('maxldapreferrals') ) { $payload.Add('maxldapreferrals', $maxldapreferrals) } if ( $PSBoundParameters.ContainsKey('referraldnslookup') ) { $payload.Add('referraldnslookup', $referraldnslookup) } if ( $PSBoundParameters.ContainsKey('mssrvrecordlocation') ) { $payload.Add('mssrvrecordlocation', $mssrvrecordlocation) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('attribute1') ) { $payload.Add('attribute1', $attribute1) } if ( $PSBoundParameters.ContainsKey('attribute2') ) { $payload.Add('attribute2', $attribute2) } if ( $PSBoundParameters.ContainsKey('attribute3') ) { $payload.Add('attribute3', $attribute3) } if ( $PSBoundParameters.ContainsKey('attribute4') ) { $payload.Add('attribute4', $attribute4) } if ( $PSBoundParameters.ContainsKey('attribute5') ) { $payload.Add('attribute5', $attribute5) } if ( $PSBoundParameters.ContainsKey('attribute6') ) { $payload.Add('attribute6', $attribute6) } if ( $PSBoundParameters.ContainsKey('attribute7') ) { $payload.Add('attribute7', $attribute7) } if ( $PSBoundParameters.ContainsKey('attribute8') ) { $payload.Add('attribute8', $attribute8) } if ( $PSBoundParameters.ContainsKey('attribute9') ) { $payload.Add('attribute9', $attribute9) } if ( $PSBoundParameters.ContainsKey('attribute10') ) { $payload.Add('attribute10', $attribute10) } if ( $PSBoundParameters.ContainsKey('attribute11') ) { $payload.Add('attribute11', $attribute11) } if ( $PSBoundParameters.ContainsKey('attribute12') ) { $payload.Add('attribute12', $attribute12) } if ( $PSBoundParameters.ContainsKey('attribute13') ) { $payload.Add('attribute13', $attribute13) } if ( $PSBoundParameters.ContainsKey('attribute14') ) { $payload.Add('attribute14', $attribute14) } if ( $PSBoundParameters.ContainsKey('attribute15') ) { $payload.Add('attribute15', $attribute15) } if ( $PSBoundParameters.ContainsKey('attribute16') ) { $payload.Add('attribute16', $attribute16) } if ( $PSBoundParameters.ContainsKey('attributes') ) { $payload.Add('attributes', $attributes) } if ( $PSBoundParameters.ContainsKey('otpsecret') ) { $payload.Add('otpsecret', $otpsecret) } if ( $PSBoundParameters.ContainsKey('pushservice') ) { $payload.Add('pushservice', $pushservice) } if ( $PSBoundParameters.ContainsKey('email') ) { $payload.Add('email', $email) } if ( $PSBoundParameters.ContainsKey('kbattribute') ) { $payload.Add('kbattribute', $kbattribute) } if ( $PSBoundParameters.ContainsKey('alternateemailattr') ) { $payload.Add('alternateemailattr', $alternateemailattr) } if ( $PSBoundParameters.ContainsKey('cloudattributes') ) { $payload.Add('cloudattributes', $cloudattributes) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationldapaction -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationldapaction: Finished" } } function Invoke-ADCDeleteAuthenticationldapaction { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for LDAP action resource. .PARAMETER Name Name for the new LDAP action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the LDAP action is added. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationldapaction -Name <string> An example how to delete authenticationldapaction configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationldapaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationldapaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationldapaction: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationldapaction -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationldapaction: Finished" } } function Invoke-ADCUpdateAuthenticationldapaction { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for LDAP action resource. .PARAMETER Name Name for the new LDAP action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the LDAP action is added. .PARAMETER Serverip IP address assigned to the LDAP server. .PARAMETER Servername LDAP server name as a FQDN. Mutually exclusive with LDAP IP address. .PARAMETER Serverport Port on which the LDAP server accepts connections. .PARAMETER Authtimeout Number of seconds the Citrix ADC waits for a response from the RADIUS server. .PARAMETER Ldapbase Base (node) from which to start LDAP searches. If the LDAP server is running locally, the default value of base is dc=netscaler, dc=com. .PARAMETER Ldapbinddn Full distinguished name (DN) that is used to bind to the LDAP server. Default: cn=Manager,dc=netscaler,dc=com. .PARAMETER Ldapbinddnpassword Password used to bind to the LDAP server. .PARAMETER Ldaploginname LDAP login name attribute. The Citrix ADC uses the LDAP login name to query external LDAP servers or Active Directories. .PARAMETER Searchfilter String to be combined with the default LDAP user search string to form the search value. For example, if the search filter "vpnallowed=true" is combined with the LDAP login name "samaccount" and the user-supplied username is "bob", the result is the LDAP search string ""(;(vpnallowed=true)(samaccount=bob)"" (Be sure to enclose the search string in two sets of double quotation marks; both sets are needed.). .PARAMETER Groupattrname LDAP group attribute name. Used for group extraction on the LDAP server. .PARAMETER Subattributename LDAP group sub-attribute name. Used for group extraction from the LDAP server. .PARAMETER Sectype Type of security used for communications between the Citrix ADC and the LDAP server. For the PLAINTEXT setting, no encryption is required. Possible values = PLAINTEXT, TLS, SSL .PARAMETER Svrtype The type of LDAP server. Possible values = AD, NDS .PARAMETER Ssonameattribute LDAP single signon (SSO) attribute. The Citrix ADC uses the SSO name attribute to query external LDAP servers or Active Directories for an alternate username. .PARAMETER Authentication Perform LDAP authentication. If authentication is disabled, any LDAP authentication attempt returns authentication success if the user is found. CAUTION! Authentication should be disabled only for authorization group extraction or where other (non-LDAP) authentication methods are in use and either bound to a primary list or flagged as secondary. Possible values = ENABLED, DISABLED .PARAMETER Requireuser Require a successful user search for authentication. CAUTION! This field should be set to NO only if usersearch not required [Both username validation as well as password validation skipped] and (non-LDAP) authentication methods are in use and either bound to a primary list or flagged as secondary. Possible values = YES, NO .PARAMETER Passwdchange Allow password change requests. Possible values = ENABLED, DISABLED .PARAMETER Validateservercert When to validate LDAP server certs. Possible values = YES, NO .PARAMETER Ldaphostname Hostname for the LDAP server. If -validateServerCert is ON then this must be the host name on the certificate from the LDAP server. A hostname mismatch will cause a connection failure. .PARAMETER Nestedgroupextraction Allow nested group extraction, in which the Citrix ADC queries external LDAP servers to determine whether a group is part of another group. Possible values = ON, OFF .PARAMETER Maxnestinglevel If nested group extraction is ON, specifies the number of levels up to which group extraction is performed. .PARAMETER Groupnameidentifier Name that uniquely identifies a group in LDAP or Active Directory. .PARAMETER Groupsearchattribute LDAP group search attribute. Used to determine to which groups a group belongs. .PARAMETER Groupsearchsubattribute LDAP group search subattribute. Used to determine to which groups a group belongs. .PARAMETER Groupsearchfilter String to be combined with the default LDAP group search string to form the search value. For example, the group search filter ""vpnallowed=true"" when combined with the group identifier ""samaccount"" and the group name ""g1"" yields the LDAP search string ""(;(vpnallowed=true)(samaccount=g1)"". If nestedGroupExtraction is ENABLED, the filter is applied on the first level group search as well, otherwise first level groups (of which user is a direct member of) will be fetched without applying this filter. (Be sure to enclose the search string in two sets of double quotation marks; both sets are needed.). .PARAMETER Followreferrals Setting this option to ON enables following LDAP referrals received from the LDAP server. Possible values = ON, OFF .PARAMETER Maxldapreferrals Specifies the maximum number of nested referrals to follow. .PARAMETER Referraldnslookup Specifies the DNS Record lookup Type for the referrals. Possible values = A-REC, SRV-REC, MSSRV-REC .PARAMETER Mssrvrecordlocation MSSRV Specific parameter. Used to locate the DNS node to which the SRV record pertains in the domainname. The domainname is appended to it to form the srv record. Example : For "dc._msdcs", the srv record formed is _ldap._tcp.dc._msdcs.<domainname>. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER Attribute1 Expression that would be evaluated to extract attribute1 from the ldap response. .PARAMETER Attribute2 Expression that would be evaluated to extract attribute2 from the ldap response. .PARAMETER Attribute3 Expression that would be evaluated to extract attribute3 from the ldap response. .PARAMETER Attribute4 Expression that would be evaluated to extract attribute4 from the ldap response. .PARAMETER Attribute5 Expression that would be evaluated to extract attribute5 from the ldap response. .PARAMETER Attribute6 Expression that would be evaluated to extract attribute6 from the ldap response. .PARAMETER Attribute7 Expression that would be evaluated to extract attribute7 from the ldap response. .PARAMETER Attribute8 Expression that would be evaluated to extract attribute8 from the ldap response. .PARAMETER Attribute9 Expression that would be evaluated to extract attribute9 from the ldap response. .PARAMETER Attribute10 Expression that would be evaluated to extract attribute10 from the ldap response. .PARAMETER Attribute11 Expression that would be evaluated to extract attribute11 from the ldap response. .PARAMETER Attribute12 Expression that would be evaluated to extract attribute12 from the ldap response. .PARAMETER Attribute13 Expression that would be evaluated to extract attribute13 from the ldap response. .PARAMETER Attribute14 Expression that would be evaluated to extract attribute14 from the ldap response. .PARAMETER Attribute15 Expression that would be evaluated to extract attribute15 from the ldap response. .PARAMETER Attribute16 Expression that would be evaluated to extract attribute16 from the ldap response. .PARAMETER Attributes List of attribute names separated by ',' which needs to be fetched from ldap server. Note that preceeding and trailing spaces will be removed. Attribute name can be 127 bytes and total length of this string should not cross 2047 bytes. These attributes have multi-value support separated by ',' and stored as key-value pair in AAA session. .PARAMETER Otpsecret OneTimePassword(OTP) Secret key attribute on AD. This attribute is used to store and retrieve secret key used for OTP check. .PARAMETER Sshpublickey SSH PublicKey is attribute on AD. This attribute is used to retrieve ssh PublicKey for RBA authentication. .PARAMETER Pushservice Name of the service used to send push notifications. .PARAMETER Email The Citrix ADC uses the email attribute to query the Active Directory for the email id of a user. .PARAMETER Kbattribute KnowledgeBasedAuthentication(KBA) attribute on AD. This attribute is used to store and retrieve preconfigured Question and Answer knowledge base used for KBA authentication. .PARAMETER Alternateemailattr The NetScaler appliance uses the alternateive email attribute to query the Active Directory for the alternative email id of a user. .PARAMETER Cloudattributes The Citrix ADC uses the cloud attributes to extract additional attributes from LDAP servers required for Citrix Cloud operations. Possible values = ENABLED, DISABLED .PARAMETER PassThru Return details about the created authenticationldapaction item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationldapaction -name <string> An example how to update authenticationldapaction configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationldapaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationldapaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Serverip, [ValidateScript({ $_.Length -gt 1 })] [string]$Servername, [int]$Serverport, [double]$Authtimeout, [string]$Ldapbase, [string]$Ldapbinddn, [ValidateScript({ $_.Length -gt 1 })] [string]$Ldapbinddnpassword, [string]$Ldaploginname, [ValidateScript({ $_.Length -gt 1 })] [string]$Searchfilter, [string]$Groupattrname, [string]$Subattributename, [ValidateSet('PLAINTEXT', 'TLS', 'SSL')] [string]$Sectype, [ValidateSet('AD', 'NDS')] [string]$Svrtype, [string]$Ssonameattribute, [ValidateSet('ENABLED', 'DISABLED')] [string]$Authentication, [ValidateSet('YES', 'NO')] [string]$Requireuser, [ValidateSet('ENABLED', 'DISABLED')] [string]$Passwdchange, [ValidateSet('YES', 'NO')] [string]$Validateservercert, [string]$Ldaphostname, [ValidateSet('ON', 'OFF')] [string]$Nestedgroupextraction, [double]$Maxnestinglevel, [string]$Groupnameidentifier, [string]$Groupsearchattribute, [string]$Groupsearchsubattribute, [string]$Groupsearchfilter, [ValidateSet('ON', 'OFF')] [string]$Followreferrals, [double]$Maxldapreferrals, [ValidateSet('A-REC', 'SRV-REC', 'MSSRV-REC')] [string]$Referraldnslookup, [string]$Mssrvrecordlocation, [string]$Defaultauthenticationgroup, [string]$Attribute1, [string]$Attribute2, [string]$Attribute3, [string]$Attribute4, [string]$Attribute5, [string]$Attribute6, [string]$Attribute7, [string]$Attribute8, [string]$Attribute9, [string]$Attribute10, [string]$Attribute11, [string]$Attribute12, [string]$Attribute13, [string]$Attribute14, [string]$Attribute15, [string]$Attribute16, [string]$Attributes, [ValidateScript({ $_.Length -gt 1 })] [string]$Otpsecret, [ValidateScript({ $_.Length -gt 1 })] [string]$Sshpublickey, [ValidateScript({ $_.Length -gt 1 })] [string]$Pushservice, [string]$Email, [ValidateLength(1, 127)] [string]$Kbattribute, [string]$Alternateemailattr, [ValidateSet('ENABLED', 'DISABLED')] [string]$Cloudattributes, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationldapaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('serverip') ) { $payload.Add('serverip', $serverip) } if ( $PSBoundParameters.ContainsKey('servername') ) { $payload.Add('servername', $servername) } if ( $PSBoundParameters.ContainsKey('serverport') ) { $payload.Add('serverport', $serverport) } if ( $PSBoundParameters.ContainsKey('authtimeout') ) { $payload.Add('authtimeout', $authtimeout) } if ( $PSBoundParameters.ContainsKey('ldapbase') ) { $payload.Add('ldapbase', $ldapbase) } if ( $PSBoundParameters.ContainsKey('ldapbinddn') ) { $payload.Add('ldapbinddn', $ldapbinddn) } if ( $PSBoundParameters.ContainsKey('ldapbinddnpassword') ) { $payload.Add('ldapbinddnpassword', $ldapbinddnpassword) } if ( $PSBoundParameters.ContainsKey('ldaploginname') ) { $payload.Add('ldaploginname', $ldaploginname) } if ( $PSBoundParameters.ContainsKey('searchfilter') ) { $payload.Add('searchfilter', $searchfilter) } if ( $PSBoundParameters.ContainsKey('groupattrname') ) { $payload.Add('groupattrname', $groupattrname) } if ( $PSBoundParameters.ContainsKey('subattributename') ) { $payload.Add('subattributename', $subattributename) } if ( $PSBoundParameters.ContainsKey('sectype') ) { $payload.Add('sectype', $sectype) } if ( $PSBoundParameters.ContainsKey('svrtype') ) { $payload.Add('svrtype', $svrtype) } if ( $PSBoundParameters.ContainsKey('ssonameattribute') ) { $payload.Add('ssonameattribute', $ssonameattribute) } if ( $PSBoundParameters.ContainsKey('authentication') ) { $payload.Add('authentication', $authentication) } if ( $PSBoundParameters.ContainsKey('requireuser') ) { $payload.Add('requireuser', $requireuser) } if ( $PSBoundParameters.ContainsKey('passwdchange') ) { $payload.Add('passwdchange', $passwdchange) } if ( $PSBoundParameters.ContainsKey('validateservercert') ) { $payload.Add('validateservercert', $validateservercert) } if ( $PSBoundParameters.ContainsKey('ldaphostname') ) { $payload.Add('ldaphostname', $ldaphostname) } if ( $PSBoundParameters.ContainsKey('nestedgroupextraction') ) { $payload.Add('nestedgroupextraction', $nestedgroupextraction) } if ( $PSBoundParameters.ContainsKey('maxnestinglevel') ) { $payload.Add('maxnestinglevel', $maxnestinglevel) } if ( $PSBoundParameters.ContainsKey('groupnameidentifier') ) { $payload.Add('groupnameidentifier', $groupnameidentifier) } if ( $PSBoundParameters.ContainsKey('groupsearchattribute') ) { $payload.Add('groupsearchattribute', $groupsearchattribute) } if ( $PSBoundParameters.ContainsKey('groupsearchsubattribute') ) { $payload.Add('groupsearchsubattribute', $groupsearchsubattribute) } if ( $PSBoundParameters.ContainsKey('groupsearchfilter') ) { $payload.Add('groupsearchfilter', $groupsearchfilter) } if ( $PSBoundParameters.ContainsKey('followreferrals') ) { $payload.Add('followreferrals', $followreferrals) } if ( $PSBoundParameters.ContainsKey('maxldapreferrals') ) { $payload.Add('maxldapreferrals', $maxldapreferrals) } if ( $PSBoundParameters.ContainsKey('referraldnslookup') ) { $payload.Add('referraldnslookup', $referraldnslookup) } if ( $PSBoundParameters.ContainsKey('mssrvrecordlocation') ) { $payload.Add('mssrvrecordlocation', $mssrvrecordlocation) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('attribute1') ) { $payload.Add('attribute1', $attribute1) } if ( $PSBoundParameters.ContainsKey('attribute2') ) { $payload.Add('attribute2', $attribute2) } if ( $PSBoundParameters.ContainsKey('attribute3') ) { $payload.Add('attribute3', $attribute3) } if ( $PSBoundParameters.ContainsKey('attribute4') ) { $payload.Add('attribute4', $attribute4) } if ( $PSBoundParameters.ContainsKey('attribute5') ) { $payload.Add('attribute5', $attribute5) } if ( $PSBoundParameters.ContainsKey('attribute6') ) { $payload.Add('attribute6', $attribute6) } if ( $PSBoundParameters.ContainsKey('attribute7') ) { $payload.Add('attribute7', $attribute7) } if ( $PSBoundParameters.ContainsKey('attribute8') ) { $payload.Add('attribute8', $attribute8) } if ( $PSBoundParameters.ContainsKey('attribute9') ) { $payload.Add('attribute9', $attribute9) } if ( $PSBoundParameters.ContainsKey('attribute10') ) { $payload.Add('attribute10', $attribute10) } if ( $PSBoundParameters.ContainsKey('attribute11') ) { $payload.Add('attribute11', $attribute11) } if ( $PSBoundParameters.ContainsKey('attribute12') ) { $payload.Add('attribute12', $attribute12) } if ( $PSBoundParameters.ContainsKey('attribute13') ) { $payload.Add('attribute13', $attribute13) } if ( $PSBoundParameters.ContainsKey('attribute14') ) { $payload.Add('attribute14', $attribute14) } if ( $PSBoundParameters.ContainsKey('attribute15') ) { $payload.Add('attribute15', $attribute15) } if ( $PSBoundParameters.ContainsKey('attribute16') ) { $payload.Add('attribute16', $attribute16) } if ( $PSBoundParameters.ContainsKey('attributes') ) { $payload.Add('attributes', $attributes) } if ( $PSBoundParameters.ContainsKey('otpsecret') ) { $payload.Add('otpsecret', $otpsecret) } if ( $PSBoundParameters.ContainsKey('sshpublickey') ) { $payload.Add('sshpublickey', $sshpublickey) } if ( $PSBoundParameters.ContainsKey('pushservice') ) { $payload.Add('pushservice', $pushservice) } if ( $PSBoundParameters.ContainsKey('email') ) { $payload.Add('email', $email) } if ( $PSBoundParameters.ContainsKey('kbattribute') ) { $payload.Add('kbattribute', $kbattribute) } if ( $PSBoundParameters.ContainsKey('alternateemailattr') ) { $payload.Add('alternateemailattr', $alternateemailattr) } if ( $PSBoundParameters.ContainsKey('cloudattributes') ) { $payload.Add('cloudattributes', $cloudattributes) } if ( $PSCmdlet.ShouldProcess("authenticationldapaction", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationldapaction -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationldapaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationldapaction: Finished" } } function Invoke-ADCAddAuthenticationldapaction { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for LDAP action resource. .PARAMETER Name Name for the new LDAP action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the LDAP action is added. .PARAMETER Serverip IP address assigned to the LDAP server. .PARAMETER Servername LDAP server name as a FQDN. Mutually exclusive with LDAP IP address. .PARAMETER Serverport Port on which the LDAP server accepts connections. .PARAMETER Authtimeout Number of seconds the Citrix ADC waits for a response from the RADIUS server. .PARAMETER Ldapbase Base (node) from which to start LDAP searches. If the LDAP server is running locally, the default value of base is dc=netscaler, dc=com. .PARAMETER Ldapbinddn Full distinguished name (DN) that is used to bind to the LDAP server. Default: cn=Manager,dc=netscaler,dc=com. .PARAMETER Ldapbinddnpassword Password used to bind to the LDAP server. .PARAMETER Ldaploginname LDAP login name attribute. The Citrix ADC uses the LDAP login name to query external LDAP servers or Active Directories. .PARAMETER Searchfilter String to be combined with the default LDAP user search string to form the search value. For example, if the search filter "vpnallowed=true" is combined with the LDAP login name "samaccount" and the user-supplied username is "bob", the result is the LDAP search string ""(;(vpnallowed=true)(samaccount=bob)"" (Be sure to enclose the search string in two sets of double quotation marks; both sets are needed.). .PARAMETER Groupattrname LDAP group attribute name. Used for group extraction on the LDAP server. .PARAMETER Subattributename LDAP group sub-attribute name. Used for group extraction from the LDAP server. .PARAMETER Sectype Type of security used for communications between the Citrix ADC and the LDAP server. For the PLAINTEXT setting, no encryption is required. Possible values = PLAINTEXT, TLS, SSL .PARAMETER Svrtype The type of LDAP server. Possible values = AD, NDS .PARAMETER Ssonameattribute LDAP single signon (SSO) attribute. The Citrix ADC uses the SSO name attribute to query external LDAP servers or Active Directories for an alternate username. .PARAMETER Authentication Perform LDAP authentication. If authentication is disabled, any LDAP authentication attempt returns authentication success if the user is found. CAUTION! Authentication should be disabled only for authorization group extraction or where other (non-LDAP) authentication methods are in use and either bound to a primary list or flagged as secondary. Possible values = ENABLED, DISABLED .PARAMETER Requireuser Require a successful user search for authentication. CAUTION! This field should be set to NO only if usersearch not required [Both username validation as well as password validation skipped] and (non-LDAP) authentication methods are in use and either bound to a primary list or flagged as secondary. Possible values = YES, NO .PARAMETER Passwdchange Allow password change requests. Possible values = ENABLED, DISABLED .PARAMETER Nestedgroupextraction Allow nested group extraction, in which the Citrix ADC queries external LDAP servers to determine whether a group is part of another group. Possible values = ON, OFF .PARAMETER Maxnestinglevel If nested group extraction is ON, specifies the number of levels up to which group extraction is performed. .PARAMETER Followreferrals Setting this option to ON enables following LDAP referrals received from the LDAP server. Possible values = ON, OFF .PARAMETER Maxldapreferrals Specifies the maximum number of nested referrals to follow. .PARAMETER Referraldnslookup Specifies the DNS Record lookup Type for the referrals. Possible values = A-REC, SRV-REC, MSSRV-REC .PARAMETER Mssrvrecordlocation MSSRV Specific parameter. Used to locate the DNS node to which the SRV record pertains in the domainname. The domainname is appended to it to form the srv record. Example : For "dc._msdcs", the srv record formed is _ldap._tcp.dc._msdcs.<domainname>. .PARAMETER Validateservercert When to validate LDAP server certs. Possible values = YES, NO .PARAMETER Ldaphostname Hostname for the LDAP server. If -validateServerCert is ON then this must be the host name on the certificate from the LDAP server. A hostname mismatch will cause a connection failure. .PARAMETER Groupnameidentifier Name that uniquely identifies a group in LDAP or Active Directory. .PARAMETER Groupsearchattribute LDAP group search attribute. Used to determine to which groups a group belongs. .PARAMETER Groupsearchsubattribute LDAP group search subattribute. Used to determine to which groups a group belongs. .PARAMETER Groupsearchfilter String to be combined with the default LDAP group search string to form the search value. For example, the group search filter ""vpnallowed=true"" when combined with the group identifier ""samaccount"" and the group name ""g1"" yields the LDAP search string ""(;(vpnallowed=true)(samaccount=g1)"". If nestedGroupExtraction is ENABLED, the filter is applied on the first level group search as well, otherwise first level groups (of which user is a direct member of) will be fetched without applying this filter. (Be sure to enclose the search string in two sets of double quotation marks; both sets are needed.). .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER Attribute1 Expression that would be evaluated to extract attribute1 from the ldap response. .PARAMETER Attribute2 Expression that would be evaluated to extract attribute2 from the ldap response. .PARAMETER Attribute3 Expression that would be evaluated to extract attribute3 from the ldap response. .PARAMETER Attribute4 Expression that would be evaluated to extract attribute4 from the ldap response. .PARAMETER Attribute5 Expression that would be evaluated to extract attribute5 from the ldap response. .PARAMETER Attribute6 Expression that would be evaluated to extract attribute6 from the ldap response. .PARAMETER Attribute7 Expression that would be evaluated to extract attribute7 from the ldap response. .PARAMETER Attribute8 Expression that would be evaluated to extract attribute8 from the ldap response. .PARAMETER Attribute9 Expression that would be evaluated to extract attribute9 from the ldap response. .PARAMETER Attribute10 Expression that would be evaluated to extract attribute10 from the ldap response. .PARAMETER Attribute11 Expression that would be evaluated to extract attribute11 from the ldap response. .PARAMETER Attribute12 Expression that would be evaluated to extract attribute12 from the ldap response. .PARAMETER Attribute13 Expression that would be evaluated to extract attribute13 from the ldap response. .PARAMETER Attribute14 Expression that would be evaluated to extract attribute14 from the ldap response. .PARAMETER Attribute15 Expression that would be evaluated to extract attribute15 from the ldap response. .PARAMETER Attribute16 Expression that would be evaluated to extract attribute16 from the ldap response. .PARAMETER Attributes List of attribute names separated by ',' which needs to be fetched from ldap server. Note that preceeding and trailing spaces will be removed. Attribute name can be 127 bytes and total length of this string should not cross 2047 bytes. These attributes have multi-value support separated by ',' and stored as key-value pair in AAA session. .PARAMETER Sshpublickey SSH PublicKey is attribute on AD. This attribute is used to retrieve ssh PublicKey for RBA authentication. .PARAMETER Pushservice Name of the service used to send push notifications. .PARAMETER Otpsecret OneTimePassword(OTP) Secret key attribute on AD. This attribute is used to store and retrieve secret key used for OTP check. .PARAMETER Email The Citrix ADC uses the email attribute to query the Active Directory for the email id of a user. .PARAMETER Kbattribute KnowledgeBasedAuthentication(KBA) attribute on AD. This attribute is used to store and retrieve preconfigured Question and Answer knowledge base used for KBA authentication. .PARAMETER Alternateemailattr The NetScaler appliance uses the alternateive email attribute to query the Active Directory for the alternative email id of a user. .PARAMETER Cloudattributes The Citrix ADC uses the cloud attributes to extract additional attributes from LDAP servers required for Citrix Cloud operations. Possible values = ENABLED, DISABLED .PARAMETER PassThru Return details about the created authenticationldapaction item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationldapaction -name <string> An example how to add authenticationldapaction configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationldapaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationldapaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Serverip, [ValidateScript({ $_.Length -gt 1 })] [string]$Servername, [int]$Serverport = '389', [double]$Authtimeout = '3', [string]$Ldapbase, [string]$Ldapbinddn, [ValidateScript({ $_.Length -gt 1 })] [string]$Ldapbinddnpassword, [string]$Ldaploginname, [ValidateScript({ $_.Length -gt 1 })] [string]$Searchfilter, [string]$Groupattrname, [string]$Subattributename, [ValidateSet('PLAINTEXT', 'TLS', 'SSL')] [string]$Sectype = 'PLAINTEXT', [ValidateSet('AD', 'NDS')] [string]$Svrtype = 'AAA_LDAP_SERVER_TYPE_DEFAULT', [string]$Ssonameattribute, [ValidateSet('ENABLED', 'DISABLED')] [string]$Authentication = 'ENABLED', [ValidateSet('YES', 'NO')] [string]$Requireuser = 'YES', [ValidateSet('ENABLED', 'DISABLED')] [string]$Passwdchange = 'DISABLED', [ValidateSet('ON', 'OFF')] [string]$Nestedgroupextraction = 'OFF', [double]$Maxnestinglevel = '2', [ValidateSet('ON', 'OFF')] [string]$Followreferrals = 'OFF', [double]$Maxldapreferrals = '1', [ValidateSet('A-REC', 'SRV-REC', 'MSSRV-REC')] [string]$Referraldnslookup = 'A-REC', [string]$Mssrvrecordlocation, [ValidateSet('YES', 'NO')] [string]$Validateservercert = 'NO', [string]$Ldaphostname, [string]$Groupnameidentifier, [string]$Groupsearchattribute, [string]$Groupsearchsubattribute, [string]$Groupsearchfilter, [string]$Defaultauthenticationgroup, [string]$Attribute1, [string]$Attribute2, [string]$Attribute3, [string]$Attribute4, [string]$Attribute5, [string]$Attribute6, [string]$Attribute7, [string]$Attribute8, [string]$Attribute9, [string]$Attribute10, [string]$Attribute11, [string]$Attribute12, [string]$Attribute13, [string]$Attribute14, [string]$Attribute15, [string]$Attribute16, [string]$Attributes, [ValidateScript({ $_.Length -gt 1 })] [string]$Sshpublickey, [ValidateScript({ $_.Length -gt 1 })] [string]$Pushservice, [ValidateScript({ $_.Length -gt 1 })] [string]$Otpsecret, [string]$Email = 'mail', [ValidateLength(1, 127)] [string]$Kbattribute, [string]$Alternateemailattr, [ValidateSet('ENABLED', 'DISABLED')] [string]$Cloudattributes = 'DISABLED', [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationldapaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('serverip') ) { $payload.Add('serverip', $serverip) } if ( $PSBoundParameters.ContainsKey('servername') ) { $payload.Add('servername', $servername) } if ( $PSBoundParameters.ContainsKey('serverport') ) { $payload.Add('serverport', $serverport) } if ( $PSBoundParameters.ContainsKey('authtimeout') ) { $payload.Add('authtimeout', $authtimeout) } if ( $PSBoundParameters.ContainsKey('ldapbase') ) { $payload.Add('ldapbase', $ldapbase) } if ( $PSBoundParameters.ContainsKey('ldapbinddn') ) { $payload.Add('ldapbinddn', $ldapbinddn) } if ( $PSBoundParameters.ContainsKey('ldapbinddnpassword') ) { $payload.Add('ldapbinddnpassword', $ldapbinddnpassword) } if ( $PSBoundParameters.ContainsKey('ldaploginname') ) { $payload.Add('ldaploginname', $ldaploginname) } if ( $PSBoundParameters.ContainsKey('searchfilter') ) { $payload.Add('searchfilter', $searchfilter) } if ( $PSBoundParameters.ContainsKey('groupattrname') ) { $payload.Add('groupattrname', $groupattrname) } if ( $PSBoundParameters.ContainsKey('subattributename') ) { $payload.Add('subattributename', $subattributename) } if ( $PSBoundParameters.ContainsKey('sectype') ) { $payload.Add('sectype', $sectype) } if ( $PSBoundParameters.ContainsKey('svrtype') ) { $payload.Add('svrtype', $svrtype) } if ( $PSBoundParameters.ContainsKey('ssonameattribute') ) { $payload.Add('ssonameattribute', $ssonameattribute) } if ( $PSBoundParameters.ContainsKey('authentication') ) { $payload.Add('authentication', $authentication) } if ( $PSBoundParameters.ContainsKey('requireuser') ) { $payload.Add('requireuser', $requireuser) } if ( $PSBoundParameters.ContainsKey('passwdchange') ) { $payload.Add('passwdchange', $passwdchange) } if ( $PSBoundParameters.ContainsKey('nestedgroupextraction') ) { $payload.Add('nestedgroupextraction', $nestedgroupextraction) } if ( $PSBoundParameters.ContainsKey('maxnestinglevel') ) { $payload.Add('maxnestinglevel', $maxnestinglevel) } if ( $PSBoundParameters.ContainsKey('followreferrals') ) { $payload.Add('followreferrals', $followreferrals) } if ( $PSBoundParameters.ContainsKey('maxldapreferrals') ) { $payload.Add('maxldapreferrals', $maxldapreferrals) } if ( $PSBoundParameters.ContainsKey('referraldnslookup') ) { $payload.Add('referraldnslookup', $referraldnslookup) } if ( $PSBoundParameters.ContainsKey('mssrvrecordlocation') ) { $payload.Add('mssrvrecordlocation', $mssrvrecordlocation) } if ( $PSBoundParameters.ContainsKey('validateservercert') ) { $payload.Add('validateservercert', $validateservercert) } if ( $PSBoundParameters.ContainsKey('ldaphostname') ) { $payload.Add('ldaphostname', $ldaphostname) } if ( $PSBoundParameters.ContainsKey('groupnameidentifier') ) { $payload.Add('groupnameidentifier', $groupnameidentifier) } if ( $PSBoundParameters.ContainsKey('groupsearchattribute') ) { $payload.Add('groupsearchattribute', $groupsearchattribute) } if ( $PSBoundParameters.ContainsKey('groupsearchsubattribute') ) { $payload.Add('groupsearchsubattribute', $groupsearchsubattribute) } if ( $PSBoundParameters.ContainsKey('groupsearchfilter') ) { $payload.Add('groupsearchfilter', $groupsearchfilter) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('attribute1') ) { $payload.Add('attribute1', $attribute1) } if ( $PSBoundParameters.ContainsKey('attribute2') ) { $payload.Add('attribute2', $attribute2) } if ( $PSBoundParameters.ContainsKey('attribute3') ) { $payload.Add('attribute3', $attribute3) } if ( $PSBoundParameters.ContainsKey('attribute4') ) { $payload.Add('attribute4', $attribute4) } if ( $PSBoundParameters.ContainsKey('attribute5') ) { $payload.Add('attribute5', $attribute5) } if ( $PSBoundParameters.ContainsKey('attribute6') ) { $payload.Add('attribute6', $attribute6) } if ( $PSBoundParameters.ContainsKey('attribute7') ) { $payload.Add('attribute7', $attribute7) } if ( $PSBoundParameters.ContainsKey('attribute8') ) { $payload.Add('attribute8', $attribute8) } if ( $PSBoundParameters.ContainsKey('attribute9') ) { $payload.Add('attribute9', $attribute9) } if ( $PSBoundParameters.ContainsKey('attribute10') ) { $payload.Add('attribute10', $attribute10) } if ( $PSBoundParameters.ContainsKey('attribute11') ) { $payload.Add('attribute11', $attribute11) } if ( $PSBoundParameters.ContainsKey('attribute12') ) { $payload.Add('attribute12', $attribute12) } if ( $PSBoundParameters.ContainsKey('attribute13') ) { $payload.Add('attribute13', $attribute13) } if ( $PSBoundParameters.ContainsKey('attribute14') ) { $payload.Add('attribute14', $attribute14) } if ( $PSBoundParameters.ContainsKey('attribute15') ) { $payload.Add('attribute15', $attribute15) } if ( $PSBoundParameters.ContainsKey('attribute16') ) { $payload.Add('attribute16', $attribute16) } if ( $PSBoundParameters.ContainsKey('attributes') ) { $payload.Add('attributes', $attributes) } if ( $PSBoundParameters.ContainsKey('sshpublickey') ) { $payload.Add('sshpublickey', $sshpublickey) } if ( $PSBoundParameters.ContainsKey('pushservice') ) { $payload.Add('pushservice', $pushservice) } if ( $PSBoundParameters.ContainsKey('otpsecret') ) { $payload.Add('otpsecret', $otpsecret) } if ( $PSBoundParameters.ContainsKey('email') ) { $payload.Add('email', $email) } if ( $PSBoundParameters.ContainsKey('kbattribute') ) { $payload.Add('kbattribute', $kbattribute) } if ( $PSBoundParameters.ContainsKey('alternateemailattr') ) { $payload.Add('alternateemailattr', $alternateemailattr) } if ( $PSBoundParameters.ContainsKey('cloudattributes') ) { $payload.Add('cloudattributes', $cloudattributes) } if ( $PSCmdlet.ShouldProcess("authenticationldapaction", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationldapaction -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationldapaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationldapaction: Finished" } } function Invoke-ADCGetAuthenticationldapaction { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for LDAP action resource. .PARAMETER Name Name for the new LDAP action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the LDAP action is added. .PARAMETER GetAll Retrieve all authenticationldapaction object(s). .PARAMETER Count If specified, the count of the authenticationldapaction object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldapaction Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldapaction -GetAll Get all authenticationldapaction data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldapaction -Count Get the number of authenticationldapaction objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldapaction -name <string> Get authenticationldapaction object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldapaction -Filter @{ 'name'='<value>' } Get authenticationldapaction data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationldapaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationldapaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationldapaction: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationldapaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldapaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationldapaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldapaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationldapaction objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldapaction -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationldapaction configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldapaction -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationldapaction configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldapaction -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationldapaction: Ended" } } function Invoke-ADCUpdateAuthenticationldappolicy { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for LDAP policy resource. .PARAMETER Name Name for the LDAP policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after LDAP policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to determine whether to attempt to authenticate the user with the LDAP server. .PARAMETER Reqaction Name of the LDAP action to perform if the policy matches. .PARAMETER PassThru Return details about the created authenticationldappolicy item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationldappolicy -name <string> An example how to update authenticationldappolicy configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationldappolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationldappolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Rule, [ValidateScript({ $_.Length -gt 1 })] [string]$Reqaction, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationldappolicy: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('rule') ) { $payload.Add('rule', $rule) } if ( $PSBoundParameters.ContainsKey('reqaction') ) { $payload.Add('reqaction', $reqaction) } if ( $PSCmdlet.ShouldProcess("authenticationldappolicy", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationldappolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationldappolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationldappolicy: Finished" } } function Invoke-ADCUnsetAuthenticationldappolicy { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for LDAP policy resource. .PARAMETER Name Name for the LDAP policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after LDAP policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to determine whether to attempt to authenticate the user with the LDAP server. .PARAMETER Reqaction Name of the LDAP action to perform if the policy matches. .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationldappolicy -name <string> An example how to unset authenticationldappolicy configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationldappolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationldappolicy Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Boolean]$rule, [Boolean]$reqaction ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationldappolicy: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('rule') ) { $payload.Add('rule', $rule) } if ( $PSBoundParameters.ContainsKey('reqaction') ) { $payload.Add('reqaction', $reqaction) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationldappolicy -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationldappolicy: Finished" } } function Invoke-ADCAddAuthenticationldappolicy { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for LDAP policy resource. .PARAMETER Name Name for the LDAP policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after LDAP policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to determine whether to attempt to authenticate the user with the LDAP server. .PARAMETER Reqaction Name of the LDAP action to perform if the policy matches. .PARAMETER PassThru Return details about the created authenticationldappolicy item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationldappolicy -name <string> -rule <string> An example how to add authenticationldappolicy configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationldappolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationldappolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Rule, [ValidateScript({ $_.Length -gt 1 })] [string]$Reqaction, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationldappolicy: Starting" } process { try { $payload = @{ name = $name rule = $rule } if ( $PSBoundParameters.ContainsKey('reqaction') ) { $payload.Add('reqaction', $reqaction) } if ( $PSCmdlet.ShouldProcess("authenticationldappolicy", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationldappolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationldappolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationldappolicy: Finished" } } function Invoke-ADCDeleteAuthenticationldappolicy { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for LDAP policy resource. .PARAMETER Name Name for the LDAP policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after LDAP policy is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationldappolicy -Name <string> An example how to delete authenticationldappolicy configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationldappolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationldappolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationldappolicy: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationldappolicy -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationldappolicy: Finished" } } function Invoke-ADCGetAuthenticationldappolicy { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for LDAP policy resource. .PARAMETER Name Name for the LDAP policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after LDAP policy is created. .PARAMETER GetAll Retrieve all authenticationldappolicy object(s). .PARAMETER Count If specified, the count of the authenticationldappolicy object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicy Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicy -GetAll Get all authenticationldappolicy data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicy -Count Get the number of authenticationldappolicy objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicy -name <string> Get authenticationldappolicy object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicy -Filter @{ 'name'='<value>' } Get authenticationldappolicy data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationldappolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationldappolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationldappolicy: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationldappolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationldappolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationldappolicy objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationldappolicy configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationldappolicy configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationldappolicy: Ended" } } function Invoke-ADCGetAuthenticationldappolicyauthenticationvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationvserver that can be bound to authenticationldappolicy. .PARAMETER Name Name of the LDAP policy. .PARAMETER GetAll Retrieve all authenticationldappolicy_authenticationvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationldappolicy_authenticationvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicyauthenticationvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicyauthenticationvserverbinding -GetAll Get all authenticationldappolicy_authenticationvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicyauthenticationvserverbinding -Count Get the number of authenticationldappolicy_authenticationvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicyauthenticationvserverbinding -name <string> Get authenticationldappolicy_authenticationvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicyauthenticationvserverbinding -Filter @{ 'name'='<value>' } Get authenticationldappolicy_authenticationvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationldappolicyauthenticationvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationldappolicy_authenticationvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationldappolicyauthenticationvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationldappolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationldappolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationldappolicy_authenticationvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationldappolicy_authenticationvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationldappolicy_authenticationvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationldappolicyauthenticationvserverbinding: Ended" } } function Invoke-ADCGetAuthenticationldappolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object which returns the resources bound to authenticationldappolicy. .PARAMETER Name Name of the LDAP policy. .PARAMETER GetAll Retrieve all authenticationldappolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationldappolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicybinding -GetAll Get all authenticationldappolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicybinding -name <string> Get authenticationldappolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicybinding -Filter @{ 'name'='<value>' } Get authenticationldappolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationldappolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationldappolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationldappolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationldappolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationldappolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationldappolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationldappolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationldappolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationldappolicybinding: Ended" } } function Invoke-ADCGetAuthenticationldappolicysystemglobalbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the systemglobal that can be bound to authenticationldappolicy. .PARAMETER Name Name of the LDAP policy. .PARAMETER GetAll Retrieve all authenticationldappolicy_systemglobal_binding object(s). .PARAMETER Count If specified, the count of the authenticationldappolicy_systemglobal_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicysystemglobalbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicysystemglobalbinding -GetAll Get all authenticationldappolicy_systemglobal_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicysystemglobalbinding -Count Get the number of authenticationldappolicy_systemglobal_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicysystemglobalbinding -name <string> Get authenticationldappolicy_systemglobal_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicysystemglobalbinding -Filter @{ 'name'='<value>' } Get authenticationldappolicy_systemglobal_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationldappolicysystemglobalbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationldappolicy_systemglobal_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationldappolicysystemglobalbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationldappolicy_systemglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_systemglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationldappolicy_systemglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_systemglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationldappolicy_systemglobal_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_systemglobal_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationldappolicy_systemglobal_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_systemglobal_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationldappolicy_systemglobal_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_systemglobal_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationldappolicysystemglobalbinding: Ended" } } function Invoke-ADCGetAuthenticationldappolicyvpnglobalbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the vpnglobal that can be bound to authenticationldappolicy. .PARAMETER Name Name of the LDAP policy. .PARAMETER GetAll Retrieve all authenticationldappolicy_vpnglobal_binding object(s). .PARAMETER Count If specified, the count of the authenticationldappolicy_vpnglobal_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicyvpnglobalbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicyvpnglobalbinding -GetAll Get all authenticationldappolicy_vpnglobal_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicyvpnglobalbinding -Count Get the number of authenticationldappolicy_vpnglobal_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicyvpnglobalbinding -name <string> Get authenticationldappolicy_vpnglobal_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicyvpnglobalbinding -Filter @{ 'name'='<value>' } Get authenticationldappolicy_vpnglobal_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationldappolicyvpnglobalbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationldappolicy_vpnglobal_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationldappolicyvpnglobalbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationldappolicy_vpnglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_vpnglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationldappolicy_vpnglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_vpnglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationldappolicy_vpnglobal_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_vpnglobal_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationldappolicy_vpnglobal_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_vpnglobal_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationldappolicy_vpnglobal_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_vpnglobal_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationldappolicyvpnglobalbinding: Ended" } } function Invoke-ADCGetAuthenticationldappolicyvpnvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the vpnvserver that can be bound to authenticationldappolicy. .PARAMETER Name Name of the LDAP policy. .PARAMETER GetAll Retrieve all authenticationldappolicy_vpnvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationldappolicy_vpnvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicyvpnvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicyvpnvserverbinding -GetAll Get all authenticationldappolicy_vpnvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicyvpnvserverbinding -Count Get the number of authenticationldappolicy_vpnvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicyvpnvserverbinding -name <string> Get authenticationldappolicy_vpnvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationldappolicyvpnvserverbinding -Filter @{ 'name'='<value>' } Get authenticationldappolicy_vpnvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationldappolicyvpnvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationldappolicy_vpnvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationldappolicyvpnvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationldappolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationldappolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationldappolicy_vpnvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_vpnvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationldappolicy_vpnvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_vpnvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationldappolicy_vpnvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationldappolicy_vpnvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationldappolicyvpnvserverbinding: Ended" } } function Invoke-ADCAddAuthenticationlocalpolicy { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for LOCAL policy resource. .PARAMETER Name Name for the local authentication policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after local policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to perform the authentication. .PARAMETER PassThru Return details about the created authenticationlocalpolicy item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationlocalpolicy -name <string> -rule <string> An example how to add authenticationlocalpolicy configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationlocalpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationlocalpolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name, [Parameter(Mandatory)] [string]$Rule, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationlocalpolicy: Starting" } process { try { $payload = @{ name = $name rule = $rule } if ( $PSCmdlet.ShouldProcess("authenticationlocalpolicy", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationlocalpolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationlocalpolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationlocalpolicy: Finished" } } function Invoke-ADCDeleteAuthenticationlocalpolicy { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for LOCAL policy resource. .PARAMETER Name Name for the local authentication policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after local policy is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationlocalpolicy -Name <string> An example how to delete authenticationlocalpolicy configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationlocalpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationlocalpolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationlocalpolicy: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationlocalpolicy -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationlocalpolicy: Finished" } } function Invoke-ADCUpdateAuthenticationlocalpolicy { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for LOCAL policy resource. .PARAMETER Name Name for the local authentication policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after local policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to perform the authentication. .PARAMETER PassThru Return details about the created authenticationlocalpolicy item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationlocalpolicy -name <string> An example how to update authenticationlocalpolicy configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationlocalpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationlocalpolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name, [string]$Rule, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationlocalpolicy: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('rule') ) { $payload.Add('rule', $rule) } if ( $PSCmdlet.ShouldProcess("authenticationlocalpolicy", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationlocalpolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationlocalpolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationlocalpolicy: Finished" } } function Invoke-ADCGetAuthenticationlocalpolicy { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for LOCAL policy resource. .PARAMETER Name Name for the local authentication policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after local policy is created. .PARAMETER GetAll Retrieve all authenticationlocalpolicy object(s). .PARAMETER Count If specified, the count of the authenticationlocalpolicy object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicy Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicy -GetAll Get all authenticationlocalpolicy data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicy -Count Get the number of authenticationlocalpolicy objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicy -name <string> Get authenticationlocalpolicy object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicy -Filter @{ 'name'='<value>' } Get authenticationlocalpolicy data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationlocalpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationlocalpolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationlocalpolicy: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationlocalpolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationlocalpolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationlocalpolicy objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationlocalpolicy configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationlocalpolicy configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationlocalpolicy: Ended" } } function Invoke-ADCGetAuthenticationlocalpolicyauthenticationvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationvserver that can be bound to authenticationlocalpolicy. .PARAMETER Name Name of the local authentication policy. .PARAMETER GetAll Retrieve all authenticationlocalpolicy_authenticationvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationlocalpolicy_authenticationvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicyauthenticationvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicyauthenticationvserverbinding -GetAll Get all authenticationlocalpolicy_authenticationvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicyauthenticationvserverbinding -Count Get the number of authenticationlocalpolicy_authenticationvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicyauthenticationvserverbinding -name <string> Get authenticationlocalpolicy_authenticationvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicyauthenticationvserverbinding -Filter @{ 'name'='<value>' } Get authenticationlocalpolicy_authenticationvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationlocalpolicyauthenticationvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationlocalpolicy_authenticationvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationlocalpolicyauthenticationvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationlocalpolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationlocalpolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationlocalpolicy_authenticationvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationlocalpolicy_authenticationvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationlocalpolicy_authenticationvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationlocalpolicyauthenticationvserverbinding: Ended" } } function Invoke-ADCGetAuthenticationlocalpolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object which returns the resources bound to authenticationlocalpolicy. .PARAMETER Name Name of the local authentication policy. .PARAMETER GetAll Retrieve all authenticationlocalpolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationlocalpolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicybinding -GetAll Get all authenticationlocalpolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicybinding -name <string> Get authenticationlocalpolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicybinding -Filter @{ 'name'='<value>' } Get authenticationlocalpolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationlocalpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationlocalpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [string]$Name, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationlocalpolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationlocalpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationlocalpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationlocalpolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationlocalpolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationlocalpolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationlocalpolicybinding: Ended" } } function Invoke-ADCGetAuthenticationlocalpolicysystemglobalbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the systemglobal that can be bound to authenticationlocalpolicy. .PARAMETER Name Name of the local authentication policy. .PARAMETER GetAll Retrieve all authenticationlocalpolicy_systemglobal_binding object(s). .PARAMETER Count If specified, the count of the authenticationlocalpolicy_systemglobal_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicysystemglobalbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicysystemglobalbinding -GetAll Get all authenticationlocalpolicy_systemglobal_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicysystemglobalbinding -Count Get the number of authenticationlocalpolicy_systemglobal_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicysystemglobalbinding -name <string> Get authenticationlocalpolicy_systemglobal_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicysystemglobalbinding -Filter @{ 'name'='<value>' } Get authenticationlocalpolicy_systemglobal_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationlocalpolicysystemglobalbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationlocalpolicy_systemglobal_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationlocalpolicysystemglobalbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationlocalpolicy_systemglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_systemglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationlocalpolicy_systemglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_systemglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationlocalpolicy_systemglobal_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_systemglobal_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationlocalpolicy_systemglobal_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_systemglobal_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationlocalpolicy_systemglobal_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_systemglobal_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationlocalpolicysystemglobalbinding: Ended" } } function Invoke-ADCGetAuthenticationlocalpolicyvpnglobalbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the vpnglobal that can be bound to authenticationlocalpolicy. .PARAMETER Name Name of the local authentication policy. .PARAMETER GetAll Retrieve all authenticationlocalpolicy_vpnglobal_binding object(s). .PARAMETER Count If specified, the count of the authenticationlocalpolicy_vpnglobal_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicyvpnglobalbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicyvpnglobalbinding -GetAll Get all authenticationlocalpolicy_vpnglobal_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicyvpnglobalbinding -Count Get the number of authenticationlocalpolicy_vpnglobal_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicyvpnglobalbinding -name <string> Get authenticationlocalpolicy_vpnglobal_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicyvpnglobalbinding -Filter @{ 'name'='<value>' } Get authenticationlocalpolicy_vpnglobal_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationlocalpolicyvpnglobalbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationlocalpolicy_vpnglobal_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationlocalpolicyvpnglobalbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationlocalpolicy_vpnglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_vpnglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationlocalpolicy_vpnglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_vpnglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationlocalpolicy_vpnglobal_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_vpnglobal_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationlocalpolicy_vpnglobal_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_vpnglobal_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationlocalpolicy_vpnglobal_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_vpnglobal_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationlocalpolicyvpnglobalbinding: Ended" } } function Invoke-ADCGetAuthenticationlocalpolicyvpnvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the vpnvserver that can be bound to authenticationlocalpolicy. .PARAMETER Name Name of the local authentication policy. .PARAMETER GetAll Retrieve all authenticationlocalpolicy_vpnvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationlocalpolicy_vpnvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicyvpnvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicyvpnvserverbinding -GetAll Get all authenticationlocalpolicy_vpnvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicyvpnvserverbinding -Count Get the number of authenticationlocalpolicy_vpnvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicyvpnvserverbinding -name <string> Get authenticationlocalpolicy_vpnvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationlocalpolicyvpnvserverbinding -Filter @{ 'name'='<value>' } Get authenticationlocalpolicy_vpnvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationlocalpolicyvpnvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationlocalpolicy_vpnvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationlocalpolicyvpnvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationlocalpolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationlocalpolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationlocalpolicy_vpnvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_vpnvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationlocalpolicy_vpnvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_vpnvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationlocalpolicy_vpnvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationlocalpolicy_vpnvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationlocalpolicyvpnvserverbinding: Ended" } } function Invoke-ADCAddAuthenticationloginschema { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for 0 resource. .PARAMETER Name Name for the new login schema. Login schema defines the way login form is rendered. It provides a way to customize the fields that are shown to the user. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER Authenticationschema Name of the file for reading authentication schema to be sent for Login Page UI. This file should contain xml definition of elements as per Citrix Forms Authentication Protocol to be able to render login form. If administrator does not want to prompt users for additional credentials but continue with previously obtained credentials, then "noschema" can be given as argument. Please note that this applies only to loginSchemas that are used with user-defined factors, and not the vserver factor. .PARAMETER Userexpression Expression for username extraction during login. This can be any relevant advanced policy expression. .PARAMETER Passwdexpression Expression for password extraction during login. This can be any relevant advanced policy expression. .PARAMETER Usercredentialindex The index at which user entered username should be stored in session. .PARAMETER Passwordcredentialindex The index at which user entered password should be stored in session. .PARAMETER Authenticationstrength Weight of the current authentication. .PARAMETER Ssocredentials This option indicates whether current factor credentials are the default SSO (SingleSignOn) credentials. Possible values = YES, NO .PARAMETER PassThru Return details about the created authenticationloginschema item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationloginschema -name <string> -authenticationschema <string> An example how to add authenticationloginschema configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationloginschema Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationloginschema/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Authenticationschema, [ValidateScript({ $_.Length -gt 1 })] [string]$Userexpression, [ValidateScript({ $_.Length -gt 1 })] [string]$Passwdexpression, [ValidateRange(1, 16)] [double]$Usercredentialindex, [ValidateRange(1, 16)] [double]$Passwordcredentialindex, [ValidateRange(0, 65535)] [double]$Authenticationstrength, [ValidateSet('YES', 'NO')] [string]$Ssocredentials = 'NO', [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationloginschema: Starting" } process { try { $payload = @{ name = $name authenticationschema = $authenticationschema } if ( $PSBoundParameters.ContainsKey('userexpression') ) { $payload.Add('userexpression', $userexpression) } if ( $PSBoundParameters.ContainsKey('passwdexpression') ) { $payload.Add('passwdexpression', $passwdexpression) } if ( $PSBoundParameters.ContainsKey('usercredentialindex') ) { $payload.Add('usercredentialindex', $usercredentialindex) } if ( $PSBoundParameters.ContainsKey('passwordcredentialindex') ) { $payload.Add('passwordcredentialindex', $passwordcredentialindex) } if ( $PSBoundParameters.ContainsKey('authenticationstrength') ) { $payload.Add('authenticationstrength', $authenticationstrength) } if ( $PSBoundParameters.ContainsKey('ssocredentials') ) { $payload.Add('ssocredentials', $ssocredentials) } if ( $PSCmdlet.ShouldProcess("authenticationloginschema", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationloginschema -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationloginschema -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationloginschema: Finished" } } function Invoke-ADCDeleteAuthenticationloginschema { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for 0 resource. .PARAMETER Name Name for the new login schema. Login schema defines the way login form is rendered. It provides a way to customize the fields that are shown to the user. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationloginschema -Name <string> An example how to delete authenticationloginschema configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationloginschema Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationloginschema/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationloginschema: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationloginschema -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationloginschema: Finished" } } function Invoke-ADCUpdateAuthenticationloginschema { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for 0 resource. .PARAMETER Name Name for the new login schema. Login schema defines the way login form is rendered. It provides a way to customize the fields that are shown to the user. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER Authenticationschema Name of the file for reading authentication schema to be sent for Login Page UI. This file should contain xml definition of elements as per Citrix Forms Authentication Protocol to be able to render login form. If administrator does not want to prompt users for additional credentials but continue with previously obtained credentials, then "noschema" can be given as argument. Please note that this applies only to loginSchemas that are used with user-defined factors, and not the vserver factor. .PARAMETER Userexpression Expression for username extraction during login. This can be any relevant advanced policy expression. .PARAMETER Passwdexpression Expression for password extraction during login. This can be any relevant advanced policy expression. .PARAMETER Usercredentialindex The index at which user entered username should be stored in session. .PARAMETER Passwordcredentialindex The index at which user entered password should be stored in session. .PARAMETER Authenticationstrength Weight of the current authentication. .PARAMETER Ssocredentials This option indicates whether current factor credentials are the default SSO (SingleSignOn) credentials. Possible values = YES, NO .PARAMETER PassThru Return details about the created authenticationloginschema item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationloginschema -name <string> An example how to update authenticationloginschema configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationloginschema Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationloginschema/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Authenticationschema, [ValidateScript({ $_.Length -gt 1 })] [string]$Userexpression, [ValidateScript({ $_.Length -gt 1 })] [string]$Passwdexpression, [ValidateRange(1, 16)] [double]$Usercredentialindex, [ValidateRange(1, 16)] [double]$Passwordcredentialindex, [ValidateRange(0, 65535)] [double]$Authenticationstrength, [ValidateSet('YES', 'NO')] [string]$Ssocredentials, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationloginschema: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('authenticationschema') ) { $payload.Add('authenticationschema', $authenticationschema) } if ( $PSBoundParameters.ContainsKey('userexpression') ) { $payload.Add('userexpression', $userexpression) } if ( $PSBoundParameters.ContainsKey('passwdexpression') ) { $payload.Add('passwdexpression', $passwdexpression) } if ( $PSBoundParameters.ContainsKey('usercredentialindex') ) { $payload.Add('usercredentialindex', $usercredentialindex) } if ( $PSBoundParameters.ContainsKey('passwordcredentialindex') ) { $payload.Add('passwordcredentialindex', $passwordcredentialindex) } if ( $PSBoundParameters.ContainsKey('authenticationstrength') ) { $payload.Add('authenticationstrength', $authenticationstrength) } if ( $PSBoundParameters.ContainsKey('ssocredentials') ) { $payload.Add('ssocredentials', $ssocredentials) } if ( $PSCmdlet.ShouldProcess("authenticationloginschema", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationloginschema -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationloginschema -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationloginschema: Finished" } } function Invoke-ADCUnsetAuthenticationloginschema { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for 0 resource. .PARAMETER Name Name for the new login schema. Login schema defines the way login form is rendered. It provides a way to customize the fields that are shown to the user. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER Userexpression Expression for username extraction during login. This can be any relevant advanced policy expression. .PARAMETER Passwdexpression Expression for password extraction during login. This can be any relevant advanced policy expression. .PARAMETER Usercredentialindex The index at which user entered username should be stored in session. .PARAMETER Passwordcredentialindex The index at which user entered password should be stored in session. .PARAMETER Authenticationstrength Weight of the current authentication. .PARAMETER Ssocredentials This option indicates whether current factor credentials are the default SSO (SingleSignOn) credentials. Possible values = YES, NO .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationloginschema -name <string> An example how to unset authenticationloginschema configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationloginschema Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationloginschema Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Boolean]$userexpression, [Boolean]$passwdexpression, [Boolean]$usercredentialindex, [Boolean]$passwordcredentialindex, [Boolean]$authenticationstrength, [Boolean]$ssocredentials ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationloginschema: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('userexpression') ) { $payload.Add('userexpression', $userexpression) } if ( $PSBoundParameters.ContainsKey('passwdexpression') ) { $payload.Add('passwdexpression', $passwdexpression) } if ( $PSBoundParameters.ContainsKey('usercredentialindex') ) { $payload.Add('usercredentialindex', $usercredentialindex) } if ( $PSBoundParameters.ContainsKey('passwordcredentialindex') ) { $payload.Add('passwordcredentialindex', $passwordcredentialindex) } if ( $PSBoundParameters.ContainsKey('authenticationstrength') ) { $payload.Add('authenticationstrength', $authenticationstrength) } if ( $PSBoundParameters.ContainsKey('ssocredentials') ) { $payload.Add('ssocredentials', $ssocredentials) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationloginschema -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationloginschema: Finished" } } function Invoke-ADCGetAuthenticationloginschema { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for 0 resource. .PARAMETER Name Name for the new login schema. Login schema defines the way login form is rendered. It provides a way to customize the fields that are shown to the user. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER GetAll Retrieve all authenticationloginschema object(s). .PARAMETER Count If specified, the count of the authenticationloginschema object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschema Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschema -GetAll Get all authenticationloginschema data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschema -Count Get the number of authenticationloginschema objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschema -name <string> Get authenticationloginschema object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschema -Filter @{ 'name'='<value>' } Get authenticationloginschema data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationloginschema Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationloginschema/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationloginschema: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationloginschema objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschema -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationloginschema objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschema -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationloginschema objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschema -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationloginschema configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschema -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationloginschema configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschema -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationloginschema: Ended" } } function Invoke-ADCAddAuthenticationloginschemapolicy { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for 0 resource. .PARAMETER Name Name for the LoginSchema policy. This is used for selecting parameters for user logon. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the policy is created. .PARAMETER Rule Expression which is evaluated to choose a profile for authentication. The following requirements apply only to the Citrix ADC CLI: * If the expression includes one or more spaces, enclose the entire expression in double quotation marks. * If the expression itself includes double quotation marks, escape the quotations by using the \ character. * Alternatively, you can use single quotation marks to enclose the rule, in which case you do not have to escape the double quotation marks. .PARAMETER Action Name of the profile to apply to requests or connections that match this policy. * NOOP - Do not take any specific action when this policy evaluates to true. This is useful to implicitly go to a different policy set. * RESET - Reset the client connection by closing it. The client program, such as a browser, will handle this and may inform the user. The client may then resend the request if desired. * DROP - Drop the request without sending a response to the user. .PARAMETER Undefaction Action to perform if the result of policy evaluation is undefined (UNDEF). An UNDEF event indicates an internal error condition. Only the above built-in actions can be used. .PARAMETER Comment Any comments to preserve information about this policy. .PARAMETER Logaction Name of messagelog action to use when a request matches this policy. .PARAMETER PassThru Return details about the created authenticationloginschemapolicy item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationloginschemapolicy -name <string> -rule <string> -action <string> An example how to add authenticationloginschemapolicy configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationloginschemapolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationloginschemapolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Rule, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Action, [string]$Undefaction, [string]$Comment, [string]$Logaction, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationloginschemapolicy: Starting" } process { try { $payload = @{ name = $name rule = $rule action = $action } if ( $PSBoundParameters.ContainsKey('undefaction') ) { $payload.Add('undefaction', $undefaction) } if ( $PSBoundParameters.ContainsKey('comment') ) { $payload.Add('comment', $comment) } if ( $PSBoundParameters.ContainsKey('logaction') ) { $payload.Add('logaction', $logaction) } if ( $PSCmdlet.ShouldProcess("authenticationloginschemapolicy", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationloginschemapolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationloginschemapolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationloginschemapolicy: Finished" } } function Invoke-ADCDeleteAuthenticationloginschemapolicy { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for 0 resource. .PARAMETER Name Name for the LoginSchema policy. This is used for selecting parameters for user logon. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the policy is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationloginschemapolicy -Name <string> An example how to delete authenticationloginschemapolicy configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationloginschemapolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationloginschemapolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationloginschemapolicy: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationloginschemapolicy -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationloginschemapolicy: Finished" } } function Invoke-ADCUpdateAuthenticationloginschemapolicy { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for 0 resource. .PARAMETER Name Name for the LoginSchema policy. This is used for selecting parameters for user logon. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the policy is created. .PARAMETER Rule Expression which is evaluated to choose a profile for authentication. The following requirements apply only to the Citrix ADC CLI: * If the expression includes one or more spaces, enclose the entire expression in double quotation marks. * If the expression itself includes double quotation marks, escape the quotations by using the \ character. * Alternatively, you can use single quotation marks to enclose the rule, in which case you do not have to escape the double quotation marks. .PARAMETER Action Name of the profile to apply to requests or connections that match this policy. * NOOP - Do not take any specific action when this policy evaluates to true. This is useful to implicitly go to a different policy set. * RESET - Reset the client connection by closing it. The client program, such as a browser, will handle this and may inform the user. The client may then resend the request if desired. * DROP - Drop the request without sending a response to the user. .PARAMETER Undefaction Action to perform if the result of policy evaluation is undefined (UNDEF). An UNDEF event indicates an internal error condition. Only the above built-in actions can be used. .PARAMETER Comment Any comments to preserve information about this policy. .PARAMETER Logaction Name of messagelog action to use when a request matches this policy. .PARAMETER PassThru Return details about the created authenticationloginschemapolicy item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationloginschemapolicy -name <string> An example how to update authenticationloginschemapolicy configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationloginschemapolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationloginschemapolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Rule, [ValidateScript({ $_.Length -gt 1 })] [string]$Action, [string]$Undefaction, [string]$Comment, [string]$Logaction, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationloginschemapolicy: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('rule') ) { $payload.Add('rule', $rule) } if ( $PSBoundParameters.ContainsKey('action') ) { $payload.Add('action', $action) } if ( $PSBoundParameters.ContainsKey('undefaction') ) { $payload.Add('undefaction', $undefaction) } if ( $PSBoundParameters.ContainsKey('comment') ) { $payload.Add('comment', $comment) } if ( $PSBoundParameters.ContainsKey('logaction') ) { $payload.Add('logaction', $logaction) } if ( $PSCmdlet.ShouldProcess("authenticationloginschemapolicy", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationloginschemapolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationloginschemapolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationloginschemapolicy: Finished" } } function Invoke-ADCUnsetAuthenticationloginschemapolicy { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for 0 resource. .PARAMETER Name Name for the LoginSchema policy. This is used for selecting parameters for user logon. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the policy is created. .PARAMETER Undefaction Action to perform if the result of policy evaluation is undefined (UNDEF). An UNDEF event indicates an internal error condition. Only the above built-in actions can be used. .PARAMETER Comment Any comments to preserve information about this policy. .PARAMETER Logaction Name of messagelog action to use when a request matches this policy. .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationloginschemapolicy -name <string> An example how to unset authenticationloginschemapolicy configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationloginschemapolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationloginschemapolicy Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Boolean]$undefaction, [Boolean]$comment, [Boolean]$logaction ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationloginschemapolicy: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('undefaction') ) { $payload.Add('undefaction', $undefaction) } if ( $PSBoundParameters.ContainsKey('comment') ) { $payload.Add('comment', $comment) } if ( $PSBoundParameters.ContainsKey('logaction') ) { $payload.Add('logaction', $logaction) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationloginschemapolicy -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationloginschemapolicy: Finished" } } function Invoke-ADCRenameAuthenticationloginschemapolicy { <# .SYNOPSIS Rename Authentication configuration Object. .DESCRIPTION Configuration for 0 resource. .PARAMETER Name Name for the LoginSchema policy. This is used for selecting parameters for user logon. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the policy is created. .PARAMETER Newname New name for the LoginSchema policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) hash (#), space ( ), at (@), equals (=), colon (:), and underscore characters. .PARAMETER PassThru Return details about the created authenticationloginschemapolicy item. .EXAMPLE PS C:\>Invoke-ADCRenameAuthenticationloginschemapolicy -name <string> -newname <string> An example how to rename authenticationloginschemapolicy configuration Object(s). .NOTES File Name : Invoke-ADCRenameAuthenticationloginschemapolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationloginschemapolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Newname, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCRenameAuthenticationloginschemapolicy: Starting" } process { try { $payload = @{ name = $name newname = $newname } if ( $PSCmdlet.ShouldProcess("authenticationloginschemapolicy", "Rename Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationloginschemapolicy -Action rename -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationloginschemapolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCRenameAuthenticationloginschemapolicy: Finished" } } function Invoke-ADCGetAuthenticationloginschemapolicy { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for 0 resource. .PARAMETER Name Name for the LoginSchema policy. This is used for selecting parameters for user logon. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the policy is created. .PARAMETER GetAll Retrieve all authenticationloginschemapolicy object(s). .PARAMETER Count If specified, the count of the authenticationloginschemapolicy object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschemapolicy Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschemapolicy -GetAll Get all authenticationloginschemapolicy data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschemapolicy -Count Get the number of authenticationloginschemapolicy objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschemapolicy -name <string> Get authenticationloginschemapolicy object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschemapolicy -Filter @{ 'name'='<value>' } Get authenticationloginschemapolicy data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationloginschemapolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationloginschemapolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationloginschemapolicy: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationloginschemapolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschemapolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationloginschemapolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschemapolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationloginschemapolicy objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschemapolicy -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationloginschemapolicy configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschemapolicy -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationloginschemapolicy configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschemapolicy -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationloginschemapolicy: Ended" } } function Invoke-ADCGetAuthenticationloginschemapolicyauthenticationvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationvserver that can be bound to authenticationloginschemapolicy. .PARAMETER Name Name of the LoginSchema policy for which to display detailed information. .PARAMETER GetAll Retrieve all authenticationloginschemapolicy_authenticationvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationloginschemapolicy_authenticationvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschemapolicyauthenticationvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschemapolicyauthenticationvserverbinding -GetAll Get all authenticationloginschemapolicy_authenticationvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschemapolicyauthenticationvserverbinding -Count Get the number of authenticationloginschemapolicy_authenticationvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschemapolicyauthenticationvserverbinding -name <string> Get authenticationloginschemapolicy_authenticationvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschemapolicyauthenticationvserverbinding -Filter @{ 'name'='<value>' } Get authenticationloginschemapolicy_authenticationvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationloginschemapolicyauthenticationvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationloginschemapolicy_authenticationvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationloginschemapolicyauthenticationvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationloginschemapolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschemapolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationloginschemapolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschemapolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationloginschemapolicy_authenticationvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschemapolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationloginschemapolicy_authenticationvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschemapolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationloginschemapolicy_authenticationvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschemapolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationloginschemapolicyauthenticationvserverbinding: Ended" } } function Invoke-ADCGetAuthenticationloginschemapolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object which returns the resources bound to authenticationloginschemapolicy. .PARAMETER Name Name of the LoginSchema policy for which to display detailed information. .PARAMETER GetAll Retrieve all authenticationloginschemapolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationloginschemapolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschemapolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschemapolicybinding -GetAll Get all authenticationloginschemapolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschemapolicybinding -name <string> Get authenticationloginschemapolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschemapolicybinding -Filter @{ 'name'='<value>' } Get authenticationloginschemapolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationloginschemapolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationloginschemapolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationloginschemapolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationloginschemapolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschemapolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationloginschemapolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschemapolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationloginschemapolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschemapolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationloginschemapolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschemapolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationloginschemapolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschemapolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationloginschemapolicybinding: Ended" } } function Invoke-ADCGetAuthenticationloginschemapolicyvpnvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the vpnvserver that can be bound to authenticationloginschemapolicy. .PARAMETER Name Name of the LoginSchema policy for which to display detailed information. .PARAMETER GetAll Retrieve all authenticationloginschemapolicy_vpnvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationloginschemapolicy_vpnvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschemapolicyvpnvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschemapolicyvpnvserverbinding -GetAll Get all authenticationloginschemapolicy_vpnvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschemapolicyvpnvserverbinding -Count Get the number of authenticationloginschemapolicy_vpnvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschemapolicyvpnvserverbinding -name <string> Get authenticationloginschemapolicy_vpnvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationloginschemapolicyvpnvserverbinding -Filter @{ 'name'='<value>' } Get authenticationloginschemapolicy_vpnvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationloginschemapolicyvpnvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationloginschemapolicy_vpnvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationloginschemapolicyvpnvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationloginschemapolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschemapolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationloginschemapolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschemapolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationloginschemapolicy_vpnvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschemapolicy_vpnvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationloginschemapolicy_vpnvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschemapolicy_vpnvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationloginschemapolicy_vpnvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationloginschemapolicy_vpnvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationloginschemapolicyvpnvserverbinding: Ended" } } function Invoke-ADCUnsetAuthenticationnegotiateaction { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for Negotiate action resource. .PARAMETER Name Name for the AD KDC server profile (negotiate action). Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after AD KDC server profile is created. .PARAMETER Domain Domain name of the service principal that represnts Citrix ADC. .PARAMETER Domainuser User name of the account that is mapped with Citrix ADC principal. This can be given along with domain and password when keytab file is not available. If username is given along with keytab file, then that keytab file will be searched for this user's credentials. .PARAMETER Domainuserpasswd Password of the account that is mapped to the Citrix ADC principal. .PARAMETER Ou Active Directory organizational units (OU) attribute. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER Ntlmpath The path to the site that is enabled for NTLM authentication, including FQDN of the server. This is used when clients fallback to NTLM. .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationnegotiateaction -name <string> An example how to unset authenticationnegotiateaction configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationnegotiateaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationnegotiateaction Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Boolean]$domain, [Boolean]$domainuser, [Boolean]$domainuserpasswd, [Boolean]$ou, [Boolean]$defaultauthenticationgroup, [Boolean]$ntlmpath ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationnegotiateaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('domain') ) { $payload.Add('domain', $domain) } if ( $PSBoundParameters.ContainsKey('domainuser') ) { $payload.Add('domainuser', $domainuser) } if ( $PSBoundParameters.ContainsKey('domainuserpasswd') ) { $payload.Add('domainuserpasswd', $domainuserpasswd) } if ( $PSBoundParameters.ContainsKey('ou') ) { $payload.Add('ou', $ou) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('ntlmpath') ) { $payload.Add('ntlmpath', $ntlmpath) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationnegotiateaction -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationnegotiateaction: Finished" } } function Invoke-ADCDeleteAuthenticationnegotiateaction { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for Negotiate action resource. .PARAMETER Name Name for the AD KDC server profile (negotiate action). Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after AD KDC server profile is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationnegotiateaction -Name <string> An example how to delete authenticationnegotiateaction configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationnegotiateaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationnegotiateaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationnegotiateaction: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationnegotiateaction -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationnegotiateaction: Finished" } } function Invoke-ADCUpdateAuthenticationnegotiateaction { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for Negotiate action resource. .PARAMETER Name Name for the AD KDC server profile (negotiate action). Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after AD KDC server profile is created. .PARAMETER Domain Domain name of the service principal that represnts Citrix ADC. .PARAMETER Domainuser User name of the account that is mapped with Citrix ADC principal. This can be given along with domain and password when keytab file is not available. If username is given along with keytab file, then that keytab file will be searched for this user's credentials. .PARAMETER Domainuserpasswd Password of the account that is mapped to the Citrix ADC principal. .PARAMETER Ou Active Directory organizational units (OU) attribute. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER Keytab The path to the keytab file that is used to decrypt kerberos tickets presented to Citrix ADC. If keytab is not available, domain/username/password can be specified in the negotiate action configuration. .PARAMETER Ntlmpath The path to the site that is enabled for NTLM authentication, including FQDN of the server. This is used when clients fallback to NTLM. .PARAMETER PassThru Return details about the created authenticationnegotiateaction item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationnegotiateaction -name <string> An example how to update authenticationnegotiateaction configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationnegotiateaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationnegotiateaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Domain, [ValidateScript({ $_.Length -gt 1 })] [string]$Domainuser, [ValidateScript({ $_.Length -gt 1 })] [string]$Domainuserpasswd, [ValidateScript({ $_.Length -gt 1 })] [string]$Ou, [string]$Defaultauthenticationgroup, [ValidateScript({ $_.Length -gt 1 })] [string]$Keytab, [ValidateScript({ $_.Length -gt 1 })] [string]$Ntlmpath, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationnegotiateaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('domain') ) { $payload.Add('domain', $domain) } if ( $PSBoundParameters.ContainsKey('domainuser') ) { $payload.Add('domainuser', $domainuser) } if ( $PSBoundParameters.ContainsKey('domainuserpasswd') ) { $payload.Add('domainuserpasswd', $domainuserpasswd) } if ( $PSBoundParameters.ContainsKey('ou') ) { $payload.Add('ou', $ou) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('keytab') ) { $payload.Add('keytab', $keytab) } if ( $PSBoundParameters.ContainsKey('ntlmpath') ) { $payload.Add('ntlmpath', $ntlmpath) } if ( $PSCmdlet.ShouldProcess("authenticationnegotiateaction", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationnegotiateaction -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationnegotiateaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationnegotiateaction: Finished" } } function Invoke-ADCAddAuthenticationnegotiateaction { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for Negotiate action resource. .PARAMETER Name Name for the AD KDC server profile (negotiate action). Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after AD KDC server profile is created. .PARAMETER Domain Domain name of the service principal that represnts Citrix ADC. .PARAMETER Domainuser User name of the account that is mapped with Citrix ADC principal. This can be given along with domain and password when keytab file is not available. If username is given along with keytab file, then that keytab file will be searched for this user's credentials. .PARAMETER Domainuserpasswd Password of the account that is mapped to the Citrix ADC principal. .PARAMETER Ou Active Directory organizational units (OU) attribute. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER Keytab The path to the keytab file that is used to decrypt kerberos tickets presented to Citrix ADC. If keytab is not available, domain/username/password can be specified in the negotiate action configuration. .PARAMETER Ntlmpath The path to the site that is enabled for NTLM authentication, including FQDN of the server. This is used when clients fallback to NTLM. .PARAMETER PassThru Return details about the created authenticationnegotiateaction item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationnegotiateaction -name <string> An example how to add authenticationnegotiateaction configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationnegotiateaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationnegotiateaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Domain, [ValidateScript({ $_.Length -gt 1 })] [string]$Domainuser, [ValidateScript({ $_.Length -gt 1 })] [string]$Domainuserpasswd, [ValidateScript({ $_.Length -gt 1 })] [string]$Ou, [string]$Defaultauthenticationgroup, [ValidateScript({ $_.Length -gt 1 })] [string]$Keytab, [ValidateScript({ $_.Length -gt 1 })] [string]$Ntlmpath, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationnegotiateaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('domain') ) { $payload.Add('domain', $domain) } if ( $PSBoundParameters.ContainsKey('domainuser') ) { $payload.Add('domainuser', $domainuser) } if ( $PSBoundParameters.ContainsKey('domainuserpasswd') ) { $payload.Add('domainuserpasswd', $domainuserpasswd) } if ( $PSBoundParameters.ContainsKey('ou') ) { $payload.Add('ou', $ou) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('keytab') ) { $payload.Add('keytab', $keytab) } if ( $PSBoundParameters.ContainsKey('ntlmpath') ) { $payload.Add('ntlmpath', $ntlmpath) } if ( $PSCmdlet.ShouldProcess("authenticationnegotiateaction", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationnegotiateaction -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationnegotiateaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationnegotiateaction: Finished" } } function Invoke-ADCGetAuthenticationnegotiateaction { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for Negotiate action resource. .PARAMETER Name Name for the AD KDC server profile (negotiate action). Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after AD KDC server profile is created. .PARAMETER GetAll Retrieve all authenticationnegotiateaction object(s). .PARAMETER Count If specified, the count of the authenticationnegotiateaction object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiateaction Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiateaction -GetAll Get all authenticationnegotiateaction data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiateaction -Count Get the number of authenticationnegotiateaction objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiateaction -name <string> Get authenticationnegotiateaction object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiateaction -Filter @{ 'name'='<value>' } Get authenticationnegotiateaction data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationnegotiateaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationnegotiateaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationnegotiateaction: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationnegotiateaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiateaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationnegotiateaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiateaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationnegotiateaction objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiateaction -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationnegotiateaction configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiateaction -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationnegotiateaction configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiateaction -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationnegotiateaction: Ended" } } function Invoke-ADCDeleteAuthenticationnegotiatepolicy { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for Negotiate Policy resource. .PARAMETER Name Name for the negotiate authentication policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after AD KCD (negotiate) policy is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationnegotiatepolicy -Name <string> An example how to delete authenticationnegotiatepolicy configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationnegotiatepolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationnegotiatepolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationnegotiatepolicy: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationnegotiatepolicy -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationnegotiatepolicy: Finished" } } function Invoke-ADCUpdateAuthenticationnegotiatepolicy { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for Negotiate Policy resource. .PARAMETER Name Name for the negotiate authentication policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after AD KCD (negotiate) policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to determine whether to attempt to authenticate the user with the AD KCD server. .PARAMETER Reqaction Name of the negotiate action to perform if the policy matches. .PARAMETER PassThru Return details about the created authenticationnegotiatepolicy item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationnegotiatepolicy -name <string> An example how to update authenticationnegotiatepolicy configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationnegotiatepolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationnegotiatepolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Rule, [ValidateScript({ $_.Length -gt 1 })] [string]$Reqaction, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationnegotiatepolicy: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('rule') ) { $payload.Add('rule', $rule) } if ( $PSBoundParameters.ContainsKey('reqaction') ) { $payload.Add('reqaction', $reqaction) } if ( $PSCmdlet.ShouldProcess("authenticationnegotiatepolicy", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationnegotiatepolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationnegotiatepolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationnegotiatepolicy: Finished" } } function Invoke-ADCAddAuthenticationnegotiatepolicy { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for Negotiate Policy resource. .PARAMETER Name Name for the negotiate authentication policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after AD KCD (negotiate) policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to determine whether to attempt to authenticate the user with the AD KCD server. .PARAMETER Reqaction Name of the negotiate action to perform if the policy matches. .PARAMETER PassThru Return details about the created authenticationnegotiatepolicy item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationnegotiatepolicy -name <string> -rule <string> -reqaction <string> An example how to add authenticationnegotiatepolicy configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationnegotiatepolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationnegotiatepolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Rule, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Reqaction, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationnegotiatepolicy: Starting" } process { try { $payload = @{ name = $name rule = $rule reqaction = $reqaction } if ( $PSCmdlet.ShouldProcess("authenticationnegotiatepolicy", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationnegotiatepolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationnegotiatepolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationnegotiatepolicy: Finished" } } function Invoke-ADCGetAuthenticationnegotiatepolicy { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for Negotiate Policy resource. .PARAMETER Name Name for the negotiate authentication policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after AD KCD (negotiate) policy is created. .PARAMETER GetAll Retrieve all authenticationnegotiatepolicy object(s). .PARAMETER Count If specified, the count of the authenticationnegotiatepolicy object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicy Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicy -GetAll Get all authenticationnegotiatepolicy data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicy -Count Get the number of authenticationnegotiatepolicy objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicy -name <string> Get authenticationnegotiatepolicy object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicy -Filter @{ 'name'='<value>' } Get authenticationnegotiatepolicy data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationnegotiatepolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationnegotiatepolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationnegotiatepolicy: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationnegotiatepolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationnegotiatepolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationnegotiatepolicy objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationnegotiatepolicy configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationnegotiatepolicy configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationnegotiatepolicy: Ended" } } function Invoke-ADCGetAuthenticationnegotiatepolicyauthenticationvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationvserver that can be bound to authenticationnegotiatepolicy. .PARAMETER Name Name of the negotiate policy. .PARAMETER GetAll Retrieve all authenticationnegotiatepolicy_authenticationvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationnegotiatepolicy_authenticationvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicyauthenticationvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicyauthenticationvserverbinding -GetAll Get all authenticationnegotiatepolicy_authenticationvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicyauthenticationvserverbinding -Count Get the number of authenticationnegotiatepolicy_authenticationvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicyauthenticationvserverbinding -name <string> Get authenticationnegotiatepolicy_authenticationvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicyauthenticationvserverbinding -Filter @{ 'name'='<value>' } Get authenticationnegotiatepolicy_authenticationvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationnegotiatepolicyauthenticationvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationnegotiatepolicy_authenticationvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationnegotiatepolicyauthenticationvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationnegotiatepolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationnegotiatepolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationnegotiatepolicy_authenticationvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationnegotiatepolicy_authenticationvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationnegotiatepolicy_authenticationvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationnegotiatepolicyauthenticationvserverbinding: Ended" } } function Invoke-ADCGetAuthenticationnegotiatepolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object which returns the resources bound to authenticationnegotiatepolicy. .PARAMETER Name Name of the negotiate policy. .PARAMETER GetAll Retrieve all authenticationnegotiatepolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationnegotiatepolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicybinding -GetAll Get all authenticationnegotiatepolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicybinding -name <string> Get authenticationnegotiatepolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicybinding -Filter @{ 'name'='<value>' } Get authenticationnegotiatepolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationnegotiatepolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationnegotiatepolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationnegotiatepolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationnegotiatepolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationnegotiatepolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationnegotiatepolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationnegotiatepolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationnegotiatepolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationnegotiatepolicybinding: Ended" } } function Invoke-ADCGetAuthenticationnegotiatepolicyvpnglobalbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the vpnglobal that can be bound to authenticationnegotiatepolicy. .PARAMETER Name Name of the negotiate policy. .PARAMETER GetAll Retrieve all authenticationnegotiatepolicy_vpnglobal_binding object(s). .PARAMETER Count If specified, the count of the authenticationnegotiatepolicy_vpnglobal_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicyvpnglobalbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicyvpnglobalbinding -GetAll Get all authenticationnegotiatepolicy_vpnglobal_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicyvpnglobalbinding -Count Get the number of authenticationnegotiatepolicy_vpnglobal_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicyvpnglobalbinding -name <string> Get authenticationnegotiatepolicy_vpnglobal_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicyvpnglobalbinding -Filter @{ 'name'='<value>' } Get authenticationnegotiatepolicy_vpnglobal_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationnegotiatepolicyvpnglobalbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationnegotiatepolicy_vpnglobal_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationnegotiatepolicyvpnglobalbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationnegotiatepolicy_vpnglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy_vpnglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationnegotiatepolicy_vpnglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy_vpnglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationnegotiatepolicy_vpnglobal_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy_vpnglobal_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationnegotiatepolicy_vpnglobal_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy_vpnglobal_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationnegotiatepolicy_vpnglobal_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy_vpnglobal_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationnegotiatepolicyvpnglobalbinding: Ended" } } function Invoke-ADCGetAuthenticationnegotiatepolicyvpnvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the vpnvserver that can be bound to authenticationnegotiatepolicy. .PARAMETER Name Name of the negotiate policy. .PARAMETER GetAll Retrieve all authenticationnegotiatepolicy_vpnvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationnegotiatepolicy_vpnvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicyvpnvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicyvpnvserverbinding -GetAll Get all authenticationnegotiatepolicy_vpnvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicyvpnvserverbinding -Count Get the number of authenticationnegotiatepolicy_vpnvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicyvpnvserverbinding -name <string> Get authenticationnegotiatepolicy_vpnvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnegotiatepolicyvpnvserverbinding -Filter @{ 'name'='<value>' } Get authenticationnegotiatepolicy_vpnvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationnegotiatepolicyvpnvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationnegotiatepolicy_vpnvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationnegotiatepolicyvpnvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationnegotiatepolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationnegotiatepolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationnegotiatepolicy_vpnvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy_vpnvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationnegotiatepolicy_vpnvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy_vpnvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationnegotiatepolicy_vpnvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnegotiatepolicy_vpnvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationnegotiatepolicyvpnvserverbinding: Ended" } } function Invoke-ADCAddAuthenticationnoauthaction { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for no authentication action resource. .PARAMETER Name Name for the new no-authentication action. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER Defaultauthenticationgroup This is the group that is added to user sessions that match current policy. .PARAMETER PassThru Return details about the created authenticationnoauthaction item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationnoauthaction -name <string> An example how to add authenticationnoauthaction configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationnoauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationnoauthaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [string]$Defaultauthenticationgroup, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationnoauthaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSCmdlet.ShouldProcess("authenticationnoauthaction", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationnoauthaction -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationnoauthaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationnoauthaction: Finished" } } function Invoke-ADCDeleteAuthenticationnoauthaction { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for no authentication action resource. .PARAMETER Name Name for the new no-authentication action. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationnoauthaction -Name <string> An example how to delete authenticationnoauthaction configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationnoauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationnoauthaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationnoauthaction: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationnoauthaction -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationnoauthaction: Finished" } } function Invoke-ADCUpdateAuthenticationnoauthaction { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for no authentication action resource. .PARAMETER Name Name for the new no-authentication action. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER Defaultauthenticationgroup This is the group that is added to user sessions that match current policy. .PARAMETER PassThru Return details about the created authenticationnoauthaction item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationnoauthaction -name <string> An example how to update authenticationnoauthaction configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationnoauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationnoauthaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [string]$Defaultauthenticationgroup, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationnoauthaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSCmdlet.ShouldProcess("authenticationnoauthaction", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationnoauthaction -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationnoauthaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationnoauthaction: Finished" } } function Invoke-ADCUnsetAuthenticationnoauthaction { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for no authentication action resource. .PARAMETER Name Name for the new no-authentication action. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER Defaultauthenticationgroup This is the group that is added to user sessions that match current policy. .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationnoauthaction -name <string> An example how to unset authenticationnoauthaction configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationnoauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationnoauthaction Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Boolean]$defaultauthenticationgroup ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationnoauthaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationnoauthaction -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationnoauthaction: Finished" } } function Invoke-ADCGetAuthenticationnoauthaction { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for no authentication action resource. .PARAMETER Name Name for the new no-authentication action. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER GetAll Retrieve all authenticationnoauthaction object(s). .PARAMETER Count If specified, the count of the authenticationnoauthaction object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnoauthaction Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnoauthaction -GetAll Get all authenticationnoauthaction data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnoauthaction -Count Get the number of authenticationnoauthaction objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnoauthaction -name <string> Get authenticationnoauthaction object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationnoauthaction -Filter @{ 'name'='<value>' } Get authenticationnoauthaction data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationnoauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationnoauthaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationnoauthaction: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationnoauthaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnoauthaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationnoauthaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnoauthaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationnoauthaction objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnoauthaction -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationnoauthaction configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnoauthaction -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationnoauthaction configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationnoauthaction -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationnoauthaction: Ended" } } function Invoke-ADCDeleteAuthenticationoauthaction { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for OAuth authentication action resource. .PARAMETER Name Name for the OAuth Authentication action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the profile is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationoauthaction -Name <string> An example how to delete authenticationoauthaction configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationoauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationoauthaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationoauthaction: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationoauthaction -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationoauthaction: Finished" } } function Invoke-ADCUpdateAuthenticationoauthaction { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for OAuth authentication action resource. .PARAMETER Name Name for the OAuth Authentication action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the profile is created. .PARAMETER Oauthtype Type of the OAuth implementation. Default value is generic implementation that is applicable for most deployments. Possible values = GENERIC, INTUNE, ATHENA .PARAMETER Authorizationendpoint Authorization endpoint/url to which unauthenticated user will be redirected. Citrix ADC redirects user to this endpoint by adding query parameters including clientid. If this parameter not specified then as default value we take Token Endpoint/URL value. Please note that Authorization Endpoint or Token Endpoint is mandatory for oauthAction. .PARAMETER Tokenendpoint URL to which OAuth token will be posted to verify its authenticity. User obtains this token from Authorization server upon successful authentication. Citrix ADC will validate presented token by posting it to the URL configured. .PARAMETER Idtokendecryptendpoint URL to which obtained idtoken will be posted to get a decrypted user identity. Encrypted idtoken will be obtained by posting OAuth token to token endpoint. In order to decrypt idtoken, Citrix ADC posts request to the URL configured. .PARAMETER Clientid Unique identity of the client/user who is getting authenticated. Authorization server infers client configuration using this ID. .PARAMETER Clientsecret Secret string established by user and authorization server. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER Attribute1 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute1. .PARAMETER Attribute2 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute2. .PARAMETER Attribute3 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute3. .PARAMETER Attribute4 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute4. .PARAMETER Attribute5 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute5. .PARAMETER Attribute6 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute6. .PARAMETER Attribute7 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute7. .PARAMETER Attribute8 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute8. .PARAMETER Attribute9 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute9. .PARAMETER Attribute10 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute10. .PARAMETER Attribute11 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute11. .PARAMETER Attribute12 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute12. .PARAMETER Attribute13 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute13. .PARAMETER Attribute14 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute14. .PARAMETER Attribute15 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute15. .PARAMETER Attribute16 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute16. .PARAMETER Attributes List of attribute names separated by ',' which needs to be extracted. Note that preceding and trailing spaces will be removed. Attribute name can be 127 bytes and total length of this string should not cross 1023 bytes. These attributes have multi-value support separated by ',' and stored as key-value pair in AAA session. .PARAMETER Tenantid TenantID of the application. This is usually specific to providers such as Microsoft and usually refers to the deployment identifier. .PARAMETER Graphendpoint URL of the Graph API service to learn Enterprise Mobility Services (EMS) endpoints. .PARAMETER Refreshinterval Interval at which services are monitored for necessary configuration. .PARAMETER Certendpoint URL of the endpoint that contains JWKs (Json Web Key) for JWT (Json Web Token) verification. .PARAMETER Audience Audience for which token sent by Authorization server is applicable. This is typically entity name or url that represents the recipient. .PARAMETER Usernamefield Attribute in the token from which username should be extracted. .PARAMETER Skewtime This option specifies the allowed clock skew in number of minutes that Citrix ADC allows on an incoming token. For example, if skewTime is 10, then token would be valid from (current time - 10) min to (current time + 10) min, ie 20min in all. .PARAMETER Issuer Identity of the server whose tokens are to be accepted. .PARAMETER Userinfourl URL to which OAuth access token will be posted to obtain user information. .PARAMETER Certfilepath Path to the file that contains JWKs (Json Web Key) for JWT (Json Web Token) verification. .PARAMETER Granttype Grant type support. value can be code or password. Possible values = CODE, PASSWORD .PARAMETER Authentication If authentication is disabled, password is not sent in the request. . Possible values = ENABLED, DISABLED .PARAMETER Introspecturl URL to which access token would be posted for validation. .PARAMETER Allowedalgorithms Multivalued option to specify allowed token verification algorithms. . Possible values = HS256, RS256, RS512 .PARAMETER Pkce Option to enable/disable PKCE flow during authentication. . Possible values = ENABLED, DISABLED .PARAMETER Tokenendpointauthmethod Option to select the variant of token authentication method. This method is used while exchanging code with IdP. . Possible values = client_secret_post, client_secret_jwt, private_key_jwt .PARAMETER Metadataurl Well-known configuration endpoint of the Authorization Server. Citrix ADC fetches server details from this endpoint. . .PARAMETER Resourceuri Resource URL for Oauth configuration. .PARAMETER PassThru Return details about the created authenticationoauthaction item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationoauthaction -name <string> An example how to update authenticationoauthaction configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationoauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationoauthaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [ValidateSet('GENERIC', 'INTUNE', 'ATHENA')] [string]$Oauthtype, [string]$Authorizationendpoint, [string]$Tokenendpoint, [string]$Idtokendecryptendpoint, [ValidateScript({ $_.Length -gt 1 })] [string]$Clientid, [ValidateScript({ $_.Length -gt 1 })] [string]$Clientsecret, [string]$Defaultauthenticationgroup, [string]$Attribute1, [string]$Attribute2, [string]$Attribute3, [string]$Attribute4, [string]$Attribute5, [string]$Attribute6, [string]$Attribute7, [string]$Attribute8, [string]$Attribute9, [string]$Attribute10, [string]$Attribute11, [string]$Attribute12, [string]$Attribute13, [string]$Attribute14, [string]$Attribute15, [string]$Attribute16, [string]$Attributes, [string]$Tenantid, [string]$Graphendpoint, [double]$Refreshinterval, [string]$Certendpoint, [string]$Audience, [ValidateScript({ $_.Length -gt 1 })] [string]$Usernamefield, [double]$Skewtime, [string]$Issuer, [string]$Userinfourl, [string]$Certfilepath, [ValidateSet('CODE', 'PASSWORD')] [string]$Granttype, [ValidateSet('ENABLED', 'DISABLED')] [string]$Authentication, [string]$Introspecturl, [ValidateSet('HS256', 'RS256', 'RS512')] [string[]]$Allowedalgorithms, [ValidateSet('ENABLED', 'DISABLED')] [string]$Pkce, [ValidateSet('client_secret_post', 'client_secret_jwt', 'private_key_jwt')] [string]$Tokenendpointauthmethod, [string]$Metadataurl, [string]$Resourceuri, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationoauthaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('oauthtype') ) { $payload.Add('oauthtype', $oauthtype) } if ( $PSBoundParameters.ContainsKey('authorizationendpoint') ) { $payload.Add('authorizationendpoint', $authorizationendpoint) } if ( $PSBoundParameters.ContainsKey('tokenendpoint') ) { $payload.Add('tokenendpoint', $tokenendpoint) } if ( $PSBoundParameters.ContainsKey('idtokendecryptendpoint') ) { $payload.Add('idtokendecryptendpoint', $idtokendecryptendpoint) } if ( $PSBoundParameters.ContainsKey('clientid') ) { $payload.Add('clientid', $clientid) } if ( $PSBoundParameters.ContainsKey('clientsecret') ) { $payload.Add('clientsecret', $clientsecret) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('attribute1') ) { $payload.Add('attribute1', $attribute1) } if ( $PSBoundParameters.ContainsKey('attribute2') ) { $payload.Add('attribute2', $attribute2) } if ( $PSBoundParameters.ContainsKey('attribute3') ) { $payload.Add('attribute3', $attribute3) } if ( $PSBoundParameters.ContainsKey('attribute4') ) { $payload.Add('attribute4', $attribute4) } if ( $PSBoundParameters.ContainsKey('attribute5') ) { $payload.Add('attribute5', $attribute5) } if ( $PSBoundParameters.ContainsKey('attribute6') ) { $payload.Add('attribute6', $attribute6) } if ( $PSBoundParameters.ContainsKey('attribute7') ) { $payload.Add('attribute7', $attribute7) } if ( $PSBoundParameters.ContainsKey('attribute8') ) { $payload.Add('attribute8', $attribute8) } if ( $PSBoundParameters.ContainsKey('attribute9') ) { $payload.Add('attribute9', $attribute9) } if ( $PSBoundParameters.ContainsKey('attribute10') ) { $payload.Add('attribute10', $attribute10) } if ( $PSBoundParameters.ContainsKey('attribute11') ) { $payload.Add('attribute11', $attribute11) } if ( $PSBoundParameters.ContainsKey('attribute12') ) { $payload.Add('attribute12', $attribute12) } if ( $PSBoundParameters.ContainsKey('attribute13') ) { $payload.Add('attribute13', $attribute13) } if ( $PSBoundParameters.ContainsKey('attribute14') ) { $payload.Add('attribute14', $attribute14) } if ( $PSBoundParameters.ContainsKey('attribute15') ) { $payload.Add('attribute15', $attribute15) } if ( $PSBoundParameters.ContainsKey('attribute16') ) { $payload.Add('attribute16', $attribute16) } if ( $PSBoundParameters.ContainsKey('attributes') ) { $payload.Add('attributes', $attributes) } if ( $PSBoundParameters.ContainsKey('tenantid') ) { $payload.Add('tenantid', $tenantid) } if ( $PSBoundParameters.ContainsKey('graphendpoint') ) { $payload.Add('graphendpoint', $graphendpoint) } if ( $PSBoundParameters.ContainsKey('refreshinterval') ) { $payload.Add('refreshinterval', $refreshinterval) } if ( $PSBoundParameters.ContainsKey('certendpoint') ) { $payload.Add('certendpoint', $certendpoint) } if ( $PSBoundParameters.ContainsKey('audience') ) { $payload.Add('audience', $audience) } if ( $PSBoundParameters.ContainsKey('usernamefield') ) { $payload.Add('usernamefield', $usernamefield) } if ( $PSBoundParameters.ContainsKey('skewtime') ) { $payload.Add('skewtime', $skewtime) } if ( $PSBoundParameters.ContainsKey('issuer') ) { $payload.Add('issuer', $issuer) } if ( $PSBoundParameters.ContainsKey('userinfourl') ) { $payload.Add('userinfourl', $userinfourl) } if ( $PSBoundParameters.ContainsKey('certfilepath') ) { $payload.Add('certfilepath', $certfilepath) } if ( $PSBoundParameters.ContainsKey('granttype') ) { $payload.Add('granttype', $granttype) } if ( $PSBoundParameters.ContainsKey('authentication') ) { $payload.Add('authentication', $authentication) } if ( $PSBoundParameters.ContainsKey('introspecturl') ) { $payload.Add('introspecturl', $introspecturl) } if ( $PSBoundParameters.ContainsKey('allowedalgorithms') ) { $payload.Add('allowedalgorithms', $allowedalgorithms) } if ( $PSBoundParameters.ContainsKey('pkce') ) { $payload.Add('pkce', $pkce) } if ( $PSBoundParameters.ContainsKey('tokenendpointauthmethod') ) { $payload.Add('tokenendpointauthmethod', $tokenendpointauthmethod) } if ( $PSBoundParameters.ContainsKey('metadataurl') ) { $payload.Add('metadataurl', $metadataurl) } if ( $PSBoundParameters.ContainsKey('resourceuri') ) { $payload.Add('resourceuri', $resourceuri) } if ( $PSCmdlet.ShouldProcess("authenticationoauthaction", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationoauthaction -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationoauthaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationoauthaction: Finished" } } function Invoke-ADCAddAuthenticationoauthaction { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for OAuth authentication action resource. .PARAMETER Name Name for the OAuth Authentication action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the profile is created. .PARAMETER Oauthtype Type of the OAuth implementation. Default value is generic implementation that is applicable for most deployments. Possible values = GENERIC, INTUNE, ATHENA .PARAMETER Authorizationendpoint Authorization endpoint/url to which unauthenticated user will be redirected. Citrix ADC redirects user to this endpoint by adding query parameters including clientid. If this parameter not specified then as default value we take Token Endpoint/URL value. Please note that Authorization Endpoint or Token Endpoint is mandatory for oauthAction. .PARAMETER Tokenendpoint URL to which OAuth token will be posted to verify its authenticity. User obtains this token from Authorization server upon successful authentication. Citrix ADC will validate presented token by posting it to the URL configured. .PARAMETER Idtokendecryptendpoint URL to which obtained idtoken will be posted to get a decrypted user identity. Encrypted idtoken will be obtained by posting OAuth token to token endpoint. In order to decrypt idtoken, Citrix ADC posts request to the URL configured. .PARAMETER Clientid Unique identity of the client/user who is getting authenticated. Authorization server infers client configuration using this ID. .PARAMETER Clientsecret Secret string established by user and authorization server. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER Attribute1 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute1. .PARAMETER Attribute2 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute2. .PARAMETER Attribute3 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute3. .PARAMETER Attribute4 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute4. .PARAMETER Attribute5 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute5. .PARAMETER Attribute6 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute6. .PARAMETER Attribute7 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute7. .PARAMETER Attribute8 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute8. .PARAMETER Attribute9 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute9. .PARAMETER Attribute10 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute10. .PARAMETER Attribute11 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute11. .PARAMETER Attribute12 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute12. .PARAMETER Attribute13 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute13. .PARAMETER Attribute14 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute14. .PARAMETER Attribute15 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute15. .PARAMETER Attribute16 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute16. .PARAMETER Attributes List of attribute names separated by ',' which needs to be extracted. Note that preceding and trailing spaces will be removed. Attribute name can be 127 bytes and total length of this string should not cross 1023 bytes. These attributes have multi-value support separated by ',' and stored as key-value pair in AAA session. .PARAMETER Tenantid TenantID of the application. This is usually specific to providers such as Microsoft and usually refers to the deployment identifier. .PARAMETER Graphendpoint URL of the Graph API service to learn Enterprise Mobility Services (EMS) endpoints. .PARAMETER Refreshinterval Interval at which services are monitored for necessary configuration. .PARAMETER Certendpoint URL of the endpoint that contains JWKs (Json Web Key) for JWT (Json Web Token) verification. .PARAMETER Audience Audience for which token sent by Authorization server is applicable. This is typically entity name or url that represents the recipient. .PARAMETER Usernamefield Attribute in the token from which username should be extracted. .PARAMETER Skewtime This option specifies the allowed clock skew in number of minutes that Citrix ADC allows on an incoming token. For example, if skewTime is 10, then token would be valid from (current time - 10) min to (current time + 10) min, ie 20min in all. .PARAMETER Issuer Identity of the server whose tokens are to be accepted. .PARAMETER Userinfourl URL to which OAuth access token will be posted to obtain user information. .PARAMETER Certfilepath Path to the file that contains JWKs (Json Web Key) for JWT (Json Web Token) verification. .PARAMETER Granttype Grant type support. value can be code or password. Possible values = CODE, PASSWORD .PARAMETER Authentication If authentication is disabled, password is not sent in the request. . Possible values = ENABLED, DISABLED .PARAMETER Introspecturl URL to which access token would be posted for validation. .PARAMETER Allowedalgorithms Multivalued option to specify allowed token verification algorithms. . Possible values = HS256, RS256, RS512 .PARAMETER Pkce Option to enable/disable PKCE flow during authentication. . Possible values = ENABLED, DISABLED .PARAMETER Tokenendpointauthmethod Option to select the variant of token authentication method. This method is used while exchanging code with IdP. . Possible values = client_secret_post, client_secret_jwt, private_key_jwt .PARAMETER Metadataurl Well-known configuration endpoint of the Authorization Server. Citrix ADC fetches server details from this endpoint. . .PARAMETER Resourceuri Resource URL for Oauth configuration. .PARAMETER PassThru Return details about the created authenticationoauthaction item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationoauthaction -name <string> An example how to add authenticationoauthaction configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationoauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationoauthaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [ValidateSet('GENERIC', 'INTUNE', 'ATHENA')] [string]$Oauthtype = 'GENERIC', [string]$Authorizationendpoint, [string]$Tokenendpoint, [string]$Idtokendecryptendpoint, [ValidateScript({ $_.Length -gt 1 })] [string]$Clientid, [ValidateScript({ $_.Length -gt 1 })] [string]$Clientsecret, [string]$Defaultauthenticationgroup, [string]$Attribute1, [string]$Attribute2, [string]$Attribute3, [string]$Attribute4, [string]$Attribute5, [string]$Attribute6, [string]$Attribute7, [string]$Attribute8, [string]$Attribute9, [string]$Attribute10, [string]$Attribute11, [string]$Attribute12, [string]$Attribute13, [string]$Attribute14, [string]$Attribute15, [string]$Attribute16, [string]$Attributes, [string]$Tenantid, [string]$Graphendpoint, [double]$Refreshinterval = '1440', [string]$Certendpoint, [string]$Audience, [ValidateScript({ $_.Length -gt 1 })] [string]$Usernamefield, [double]$Skewtime = '5', [string]$Issuer, [string]$Userinfourl, [string]$Certfilepath, [ValidateSet('CODE', 'PASSWORD')] [string]$Granttype = 'CODE', [ValidateSet('ENABLED', 'DISABLED')] [string]$Authentication = 'ENABLED', [string]$Introspecturl, [ValidateSet('HS256', 'RS256', 'RS512')] [string[]]$Allowedalgorithms = 'OAUTH_ALG_ALL', [ValidateSet('ENABLED', 'DISABLED')] [string]$Pkce = 'ENABLED', [ValidateSet('client_secret_post', 'client_secret_jwt', 'private_key_jwt')] [string]$Tokenendpointauthmethod = 'client_secret_post', [string]$Metadataurl, [string]$Resourceuri, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationoauthaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('oauthtype') ) { $payload.Add('oauthtype', $oauthtype) } if ( $PSBoundParameters.ContainsKey('authorizationendpoint') ) { $payload.Add('authorizationendpoint', $authorizationendpoint) } if ( $PSBoundParameters.ContainsKey('tokenendpoint') ) { $payload.Add('tokenendpoint', $tokenendpoint) } if ( $PSBoundParameters.ContainsKey('idtokendecryptendpoint') ) { $payload.Add('idtokendecryptendpoint', $idtokendecryptendpoint) } if ( $PSBoundParameters.ContainsKey('clientid') ) { $payload.Add('clientid', $clientid) } if ( $PSBoundParameters.ContainsKey('clientsecret') ) { $payload.Add('clientsecret', $clientsecret) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('attribute1') ) { $payload.Add('attribute1', $attribute1) } if ( $PSBoundParameters.ContainsKey('attribute2') ) { $payload.Add('attribute2', $attribute2) } if ( $PSBoundParameters.ContainsKey('attribute3') ) { $payload.Add('attribute3', $attribute3) } if ( $PSBoundParameters.ContainsKey('attribute4') ) { $payload.Add('attribute4', $attribute4) } if ( $PSBoundParameters.ContainsKey('attribute5') ) { $payload.Add('attribute5', $attribute5) } if ( $PSBoundParameters.ContainsKey('attribute6') ) { $payload.Add('attribute6', $attribute6) } if ( $PSBoundParameters.ContainsKey('attribute7') ) { $payload.Add('attribute7', $attribute7) } if ( $PSBoundParameters.ContainsKey('attribute8') ) { $payload.Add('attribute8', $attribute8) } if ( $PSBoundParameters.ContainsKey('attribute9') ) { $payload.Add('attribute9', $attribute9) } if ( $PSBoundParameters.ContainsKey('attribute10') ) { $payload.Add('attribute10', $attribute10) } if ( $PSBoundParameters.ContainsKey('attribute11') ) { $payload.Add('attribute11', $attribute11) } if ( $PSBoundParameters.ContainsKey('attribute12') ) { $payload.Add('attribute12', $attribute12) } if ( $PSBoundParameters.ContainsKey('attribute13') ) { $payload.Add('attribute13', $attribute13) } if ( $PSBoundParameters.ContainsKey('attribute14') ) { $payload.Add('attribute14', $attribute14) } if ( $PSBoundParameters.ContainsKey('attribute15') ) { $payload.Add('attribute15', $attribute15) } if ( $PSBoundParameters.ContainsKey('attribute16') ) { $payload.Add('attribute16', $attribute16) } if ( $PSBoundParameters.ContainsKey('attributes') ) { $payload.Add('attributes', $attributes) } if ( $PSBoundParameters.ContainsKey('tenantid') ) { $payload.Add('tenantid', $tenantid) } if ( $PSBoundParameters.ContainsKey('graphendpoint') ) { $payload.Add('graphendpoint', $graphendpoint) } if ( $PSBoundParameters.ContainsKey('refreshinterval') ) { $payload.Add('refreshinterval', $refreshinterval) } if ( $PSBoundParameters.ContainsKey('certendpoint') ) { $payload.Add('certendpoint', $certendpoint) } if ( $PSBoundParameters.ContainsKey('audience') ) { $payload.Add('audience', $audience) } if ( $PSBoundParameters.ContainsKey('usernamefield') ) { $payload.Add('usernamefield', $usernamefield) } if ( $PSBoundParameters.ContainsKey('skewtime') ) { $payload.Add('skewtime', $skewtime) } if ( $PSBoundParameters.ContainsKey('issuer') ) { $payload.Add('issuer', $issuer) } if ( $PSBoundParameters.ContainsKey('userinfourl') ) { $payload.Add('userinfourl', $userinfourl) } if ( $PSBoundParameters.ContainsKey('certfilepath') ) { $payload.Add('certfilepath', $certfilepath) } if ( $PSBoundParameters.ContainsKey('granttype') ) { $payload.Add('granttype', $granttype) } if ( $PSBoundParameters.ContainsKey('authentication') ) { $payload.Add('authentication', $authentication) } if ( $PSBoundParameters.ContainsKey('introspecturl') ) { $payload.Add('introspecturl', $introspecturl) } if ( $PSBoundParameters.ContainsKey('allowedalgorithms') ) { $payload.Add('allowedalgorithms', $allowedalgorithms) } if ( $PSBoundParameters.ContainsKey('pkce') ) { $payload.Add('pkce', $pkce) } if ( $PSBoundParameters.ContainsKey('tokenendpointauthmethod') ) { $payload.Add('tokenendpointauthmethod', $tokenendpointauthmethod) } if ( $PSBoundParameters.ContainsKey('metadataurl') ) { $payload.Add('metadataurl', $metadataurl) } if ( $PSBoundParameters.ContainsKey('resourceuri') ) { $payload.Add('resourceuri', $resourceuri) } if ( $PSCmdlet.ShouldProcess("authenticationoauthaction", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationoauthaction -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationoauthaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationoauthaction: Finished" } } function Invoke-ADCUnsetAuthenticationoauthaction { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for OAuth authentication action resource. .PARAMETER Name Name for the OAuth Authentication action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the profile is created. .PARAMETER Oauthtype Type of the OAuth implementation. Default value is generic implementation that is applicable for most deployments. Possible values = GENERIC, INTUNE, ATHENA .PARAMETER Idtokendecryptendpoint URL to which obtained idtoken will be posted to get a decrypted user identity. Encrypted idtoken will be obtained by posting OAuth token to token endpoint. In order to decrypt idtoken, Citrix ADC posts request to the URL configured. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER Attribute1 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute1. .PARAMETER Attribute2 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute2. .PARAMETER Attribute3 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute3. .PARAMETER Attribute4 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute4. .PARAMETER Attribute5 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute5. .PARAMETER Attribute6 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute6. .PARAMETER Attribute7 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute7. .PARAMETER Attribute8 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute8. .PARAMETER Attribute9 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute9. .PARAMETER Attribute10 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute10. .PARAMETER Attribute11 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute11. .PARAMETER Attribute12 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute12. .PARAMETER Attribute13 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute13. .PARAMETER Attribute14 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute14. .PARAMETER Attribute15 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute15. .PARAMETER Attribute16 Name of the attribute to be extracted from OAuth Token and to be stored in the attribute16. .PARAMETER Attributes List of attribute names separated by ',' which needs to be extracted. Note that preceding and trailing spaces will be removed. Attribute name can be 127 bytes and total length of this string should not cross 1023 bytes. These attributes have multi-value support separated by ',' and stored as key-value pair in AAA session. .PARAMETER Graphendpoint URL of the Graph API service to learn Enterprise Mobility Services (EMS) endpoints. .PARAMETER Refreshinterval Interval at which services are monitored for necessary configuration. .PARAMETER Certendpoint URL of the endpoint that contains JWKs (Json Web Key) for JWT (Json Web Token) verification. .PARAMETER Audience Audience for which token sent by Authorization server is applicable. This is typically entity name or url that represents the recipient. .PARAMETER Usernamefield Attribute in the token from which username should be extracted. .PARAMETER Skewtime This option specifies the allowed clock skew in number of minutes that Citrix ADC allows on an incoming token. For example, if skewTime is 10, then token would be valid from (current time - 10) min to (current time + 10) min, ie 20min in all. .PARAMETER Issuer Identity of the server whose tokens are to be accepted. .PARAMETER Userinfourl URL to which OAuth access token will be posted to obtain user information. .PARAMETER Certfilepath Path to the file that contains JWKs (Json Web Key) for JWT (Json Web Token) verification. .PARAMETER Authentication If authentication is disabled, password is not sent in the request. . Possible values = ENABLED, DISABLED .PARAMETER Introspecturl URL to which access token would be posted for validation. .PARAMETER Allowedalgorithms Multivalued option to specify allowed token verification algorithms. . Possible values = HS256, RS256, RS512 .PARAMETER Pkce Option to enable/disable PKCE flow during authentication. . Possible values = ENABLED, DISABLED .PARAMETER Tokenendpointauthmethod Option to select the variant of token authentication method. This method is used while exchanging code with IdP. . Possible values = client_secret_post, client_secret_jwt, private_key_jwt .PARAMETER Metadataurl Well-known configuration endpoint of the Authorization Server. Citrix ADC fetches server details from this endpoint. . .PARAMETER Resourceuri Resource URL for Oauth configuration. .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationoauthaction -name <string> An example how to unset authenticationoauthaction configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationoauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationoauthaction Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Boolean]$oauthtype, [Boolean]$idtokendecryptendpoint, [Boolean]$defaultauthenticationgroup, [Boolean]$attribute1, [Boolean]$attribute2, [Boolean]$attribute3, [Boolean]$attribute4, [Boolean]$attribute5, [Boolean]$attribute6, [Boolean]$attribute7, [Boolean]$attribute8, [Boolean]$attribute9, [Boolean]$attribute10, [Boolean]$attribute11, [Boolean]$attribute12, [Boolean]$attribute13, [Boolean]$attribute14, [Boolean]$attribute15, [Boolean]$attribute16, [Boolean]$attributes, [Boolean]$graphendpoint, [Boolean]$refreshinterval, [Boolean]$certendpoint, [Boolean]$audience, [Boolean]$usernamefield, [Boolean]$skewtime, [Boolean]$issuer, [Boolean]$userinfourl, [Boolean]$certfilepath, [Boolean]$authentication, [Boolean]$introspecturl, [Boolean]$allowedalgorithms, [Boolean]$pkce, [Boolean]$tokenendpointauthmethod, [Boolean]$metadataurl, [Boolean]$resourceuri ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationoauthaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('oauthtype') ) { $payload.Add('oauthtype', $oauthtype) } if ( $PSBoundParameters.ContainsKey('idtokendecryptendpoint') ) { $payload.Add('idtokendecryptendpoint', $idtokendecryptendpoint) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('attribute1') ) { $payload.Add('attribute1', $attribute1) } if ( $PSBoundParameters.ContainsKey('attribute2') ) { $payload.Add('attribute2', $attribute2) } if ( $PSBoundParameters.ContainsKey('attribute3') ) { $payload.Add('attribute3', $attribute3) } if ( $PSBoundParameters.ContainsKey('attribute4') ) { $payload.Add('attribute4', $attribute4) } if ( $PSBoundParameters.ContainsKey('attribute5') ) { $payload.Add('attribute5', $attribute5) } if ( $PSBoundParameters.ContainsKey('attribute6') ) { $payload.Add('attribute6', $attribute6) } if ( $PSBoundParameters.ContainsKey('attribute7') ) { $payload.Add('attribute7', $attribute7) } if ( $PSBoundParameters.ContainsKey('attribute8') ) { $payload.Add('attribute8', $attribute8) } if ( $PSBoundParameters.ContainsKey('attribute9') ) { $payload.Add('attribute9', $attribute9) } if ( $PSBoundParameters.ContainsKey('attribute10') ) { $payload.Add('attribute10', $attribute10) } if ( $PSBoundParameters.ContainsKey('attribute11') ) { $payload.Add('attribute11', $attribute11) } if ( $PSBoundParameters.ContainsKey('attribute12') ) { $payload.Add('attribute12', $attribute12) } if ( $PSBoundParameters.ContainsKey('attribute13') ) { $payload.Add('attribute13', $attribute13) } if ( $PSBoundParameters.ContainsKey('attribute14') ) { $payload.Add('attribute14', $attribute14) } if ( $PSBoundParameters.ContainsKey('attribute15') ) { $payload.Add('attribute15', $attribute15) } if ( $PSBoundParameters.ContainsKey('attribute16') ) { $payload.Add('attribute16', $attribute16) } if ( $PSBoundParameters.ContainsKey('attributes') ) { $payload.Add('attributes', $attributes) } if ( $PSBoundParameters.ContainsKey('graphendpoint') ) { $payload.Add('graphendpoint', $graphendpoint) } if ( $PSBoundParameters.ContainsKey('refreshinterval') ) { $payload.Add('refreshinterval', $refreshinterval) } if ( $PSBoundParameters.ContainsKey('certendpoint') ) { $payload.Add('certendpoint', $certendpoint) } if ( $PSBoundParameters.ContainsKey('audience') ) { $payload.Add('audience', $audience) } if ( $PSBoundParameters.ContainsKey('usernamefield') ) { $payload.Add('usernamefield', $usernamefield) } if ( $PSBoundParameters.ContainsKey('skewtime') ) { $payload.Add('skewtime', $skewtime) } if ( $PSBoundParameters.ContainsKey('issuer') ) { $payload.Add('issuer', $issuer) } if ( $PSBoundParameters.ContainsKey('userinfourl') ) { $payload.Add('userinfourl', $userinfourl) } if ( $PSBoundParameters.ContainsKey('certfilepath') ) { $payload.Add('certfilepath', $certfilepath) } if ( $PSBoundParameters.ContainsKey('authentication') ) { $payload.Add('authentication', $authentication) } if ( $PSBoundParameters.ContainsKey('introspecturl') ) { $payload.Add('introspecturl', $introspecturl) } if ( $PSBoundParameters.ContainsKey('allowedalgorithms') ) { $payload.Add('allowedalgorithms', $allowedalgorithms) } if ( $PSBoundParameters.ContainsKey('pkce') ) { $payload.Add('pkce', $pkce) } if ( $PSBoundParameters.ContainsKey('tokenendpointauthmethod') ) { $payload.Add('tokenendpointauthmethod', $tokenendpointauthmethod) } if ( $PSBoundParameters.ContainsKey('metadataurl') ) { $payload.Add('metadataurl', $metadataurl) } if ( $PSBoundParameters.ContainsKey('resourceuri') ) { $payload.Add('resourceuri', $resourceuri) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationoauthaction -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationoauthaction: Finished" } } function Invoke-ADCGetAuthenticationoauthaction { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for OAuth authentication action resource. .PARAMETER Name Name for the OAuth Authentication action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the profile is created. .PARAMETER GetAll Retrieve all authenticationoauthaction object(s). .PARAMETER Count If specified, the count of the authenticationoauthaction object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthaction Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthaction -GetAll Get all authenticationoauthaction data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthaction -Count Get the number of authenticationoauthaction objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthaction -name <string> Get authenticationoauthaction object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthaction -Filter @{ 'name'='<value>' } Get authenticationoauthaction data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationoauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationoauthaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationoauthaction: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationoauthaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationoauthaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationoauthaction objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthaction -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationoauthaction configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthaction -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationoauthaction configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthaction -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationoauthaction: Ended" } } function Invoke-ADCAddAuthenticationoauthidppolicy { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for AAA OAuth IdentityProvider (IdP) policy resource. .PARAMETER Name Name for the OAuth Identity Provider (IdP) authentication policy. This is used for configuring Citrix ADC as OAuth Identity Provider. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. .PARAMETER Rule Expression that the policy uses to determine whether to respond to the specified request. .PARAMETER Action Name of the profile to apply to requests or connections that match this policy. .PARAMETER Undefaction Action to perform if the result of policy evaluation is undefined (UNDEF). An UNDEF event indicates an internal error condition. Only DROP/RESET actions can be used. .PARAMETER Comment Any comments to preserve information about this policy. .PARAMETER Logaction Name of messagelog action to use when a request matches this policy. .PARAMETER PassThru Return details about the created authenticationoauthidppolicy item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationoauthidppolicy -name <string> -rule <string> -action <string> An example how to add authenticationoauthidppolicy configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationoauthidppolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationoauthidppolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Rule, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Action, [string]$Undefaction, [string]$Comment, [string]$Logaction, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationoauthidppolicy: Starting" } process { try { $payload = @{ name = $name rule = $rule action = $action } if ( $PSBoundParameters.ContainsKey('undefaction') ) { $payload.Add('undefaction', $undefaction) } if ( $PSBoundParameters.ContainsKey('comment') ) { $payload.Add('comment', $comment) } if ( $PSBoundParameters.ContainsKey('logaction') ) { $payload.Add('logaction', $logaction) } if ( $PSCmdlet.ShouldProcess("authenticationoauthidppolicy", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationoauthidppolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationoauthidppolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationoauthidppolicy: Finished" } } function Invoke-ADCDeleteAuthenticationoauthidppolicy { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for AAA OAuth IdentityProvider (IdP) policy resource. .PARAMETER Name Name for the OAuth Identity Provider (IdP) authentication policy. This is used for configuring Citrix ADC as OAuth Identity Provider. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationoauthidppolicy -Name <string> An example how to delete authenticationoauthidppolicy configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationoauthidppolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationoauthidppolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationoauthidppolicy: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationoauthidppolicy -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationoauthidppolicy: Finished" } } function Invoke-ADCUpdateAuthenticationoauthidppolicy { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for AAA OAuth IdentityProvider (IdP) policy resource. .PARAMETER Name Name for the OAuth Identity Provider (IdP) authentication policy. This is used for configuring Citrix ADC as OAuth Identity Provider. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. .PARAMETER Rule Expression that the policy uses to determine whether to respond to the specified request. .PARAMETER Action Name of the profile to apply to requests or connections that match this policy. .PARAMETER Undefaction Action to perform if the result of policy evaluation is undefined (UNDEF). An UNDEF event indicates an internal error condition. Only DROP/RESET actions can be used. .PARAMETER Comment Any comments to preserve information about this policy. .PARAMETER Logaction Name of messagelog action to use when a request matches this policy. .PARAMETER PassThru Return details about the created authenticationoauthidppolicy item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationoauthidppolicy -name <string> An example how to update authenticationoauthidppolicy configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationoauthidppolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationoauthidppolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Rule, [ValidateScript({ $_.Length -gt 1 })] [string]$Action, [string]$Undefaction, [string]$Comment, [string]$Logaction, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationoauthidppolicy: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('rule') ) { $payload.Add('rule', $rule) } if ( $PSBoundParameters.ContainsKey('action') ) { $payload.Add('action', $action) } if ( $PSBoundParameters.ContainsKey('undefaction') ) { $payload.Add('undefaction', $undefaction) } if ( $PSBoundParameters.ContainsKey('comment') ) { $payload.Add('comment', $comment) } if ( $PSBoundParameters.ContainsKey('logaction') ) { $payload.Add('logaction', $logaction) } if ( $PSCmdlet.ShouldProcess("authenticationoauthidppolicy", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationoauthidppolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationoauthidppolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationoauthidppolicy: Finished" } } function Invoke-ADCUnsetAuthenticationoauthidppolicy { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for AAA OAuth IdentityProvider (IdP) policy resource. .PARAMETER Name Name for the OAuth Identity Provider (IdP) authentication policy. This is used for configuring Citrix ADC as OAuth Identity Provider. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. .PARAMETER Undefaction Action to perform if the result of policy evaluation is undefined (UNDEF). An UNDEF event indicates an internal error condition. Only DROP/RESET actions can be used. .PARAMETER Comment Any comments to preserve information about this policy. .PARAMETER Logaction Name of messagelog action to use when a request matches this policy. .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationoauthidppolicy -name <string> An example how to unset authenticationoauthidppolicy configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationoauthidppolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationoauthidppolicy Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Boolean]$undefaction, [Boolean]$comment, [Boolean]$logaction ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationoauthidppolicy: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('undefaction') ) { $payload.Add('undefaction', $undefaction) } if ( $PSBoundParameters.ContainsKey('comment') ) { $payload.Add('comment', $comment) } if ( $PSBoundParameters.ContainsKey('logaction') ) { $payload.Add('logaction', $logaction) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationoauthidppolicy -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationoauthidppolicy: Finished" } } function Invoke-ADCRenameAuthenticationoauthidppolicy { <# .SYNOPSIS Rename Authentication configuration Object. .DESCRIPTION Configuration for AAA OAuth IdentityProvider (IdP) policy resource. .PARAMETER Name Name for the OAuth Identity Provider (IdP) authentication policy. This is used for configuring Citrix ADC as OAuth Identity Provider. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. .PARAMETER Newname New name for the OAuth IdentityProvider policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) hash (#), space ( ), at (@), equals (=), colon (:), and underscore characters. .PARAMETER PassThru Return details about the created authenticationoauthidppolicy item. .EXAMPLE PS C:\>Invoke-ADCRenameAuthenticationoauthidppolicy -name <string> -newname <string> An example how to rename authenticationoauthidppolicy configuration Object(s). .NOTES File Name : Invoke-ADCRenameAuthenticationoauthidppolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationoauthidppolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Newname, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCRenameAuthenticationoauthidppolicy: Starting" } process { try { $payload = @{ name = $name newname = $newname } if ( $PSCmdlet.ShouldProcess("authenticationoauthidppolicy", "Rename Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationoauthidppolicy -Action rename -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationoauthidppolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCRenameAuthenticationoauthidppolicy: Finished" } } function Invoke-ADCGetAuthenticationoauthidppolicy { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for AAA OAuth IdentityProvider (IdP) policy resource. .PARAMETER Name Name for the OAuth Identity Provider (IdP) authentication policy. This is used for configuring Citrix ADC as OAuth Identity Provider. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. .PARAMETER GetAll Retrieve all authenticationoauthidppolicy object(s). .PARAMETER Count If specified, the count of the authenticationoauthidppolicy object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidppolicy Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidppolicy -GetAll Get all authenticationoauthidppolicy data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidppolicy -Count Get the number of authenticationoauthidppolicy objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidppolicy -name <string> Get authenticationoauthidppolicy object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidppolicy -Filter @{ 'name'='<value>' } Get authenticationoauthidppolicy data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationoauthidppolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationoauthidppolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationoauthidppolicy: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationoauthidppolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidppolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationoauthidppolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidppolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationoauthidppolicy objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidppolicy -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationoauthidppolicy configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidppolicy -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationoauthidppolicy configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidppolicy -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationoauthidppolicy: Ended" } } function Invoke-ADCGetAuthenticationoauthidppolicyauthenticationvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationvserver that can be bound to authenticationoauthidppolicy. .PARAMETER Name Name of the OAuth IdentityProvider (IdP) policy for which to display detailed information. .PARAMETER GetAll Retrieve all authenticationoauthidppolicy_authenticationvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationoauthidppolicy_authenticationvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidppolicyauthenticationvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidppolicyauthenticationvserverbinding -GetAll Get all authenticationoauthidppolicy_authenticationvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidppolicyauthenticationvserverbinding -Count Get the number of authenticationoauthidppolicy_authenticationvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidppolicyauthenticationvserverbinding -name <string> Get authenticationoauthidppolicy_authenticationvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidppolicyauthenticationvserverbinding -Filter @{ 'name'='<value>' } Get authenticationoauthidppolicy_authenticationvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationoauthidppolicyauthenticationvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationoauthidppolicy_authenticationvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationoauthidppolicyauthenticationvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationoauthidppolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidppolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationoauthidppolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidppolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationoauthidppolicy_authenticationvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidppolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationoauthidppolicy_authenticationvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidppolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationoauthidppolicy_authenticationvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidppolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationoauthidppolicyauthenticationvserverbinding: Ended" } } function Invoke-ADCGetAuthenticationoauthidppolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object which returns the resources bound to authenticationoauthidppolicy. .PARAMETER Name Name of the OAuth IdentityProvider (IdP) policy for which to display detailed information. .PARAMETER GetAll Retrieve all authenticationoauthidppolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationoauthidppolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidppolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidppolicybinding -GetAll Get all authenticationoauthidppolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidppolicybinding -name <string> Get authenticationoauthidppolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidppolicybinding -Filter @{ 'name'='<value>' } Get authenticationoauthidppolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationoauthidppolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationoauthidppolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationoauthidppolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationoauthidppolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidppolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationoauthidppolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidppolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationoauthidppolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidppolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationoauthidppolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidppolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationoauthidppolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidppolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationoauthidppolicybinding: Ended" } } function Invoke-ADCGetAuthenticationoauthidppolicyvpnvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the vpnvserver that can be bound to authenticationoauthidppolicy. .PARAMETER Name Name of the OAuth IdentityProvider (IdP) policy for which to display detailed information. .PARAMETER GetAll Retrieve all authenticationoauthidppolicy_vpnvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationoauthidppolicy_vpnvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidppolicyvpnvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidppolicyvpnvserverbinding -GetAll Get all authenticationoauthidppolicy_vpnvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidppolicyvpnvserverbinding -Count Get the number of authenticationoauthidppolicy_vpnvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidppolicyvpnvserverbinding -name <string> Get authenticationoauthidppolicy_vpnvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidppolicyvpnvserverbinding -Filter @{ 'name'='<value>' } Get authenticationoauthidppolicy_vpnvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationoauthidppolicyvpnvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationoauthidppolicy_vpnvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationoauthidppolicyvpnvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationoauthidppolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidppolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationoauthidppolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidppolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationoauthidppolicy_vpnvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidppolicy_vpnvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationoauthidppolicy_vpnvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidppolicy_vpnvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationoauthidppolicy_vpnvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidppolicy_vpnvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationoauthidppolicyvpnvserverbinding: Ended" } } function Invoke-ADCAddAuthenticationoauthidpprofile { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for OAuth Identity Provider (IdP) profile resource. .PARAMETER Name Name for the new OAuth Identity Provider (IdP) single sign-on profile. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER Clientid Unique identity of the relying party requesting for authentication. .PARAMETER Clientsecret Unique secret string to authorize relying party at authorization server. .PARAMETER Redirecturl URL endpoint on relying party to which the OAuth token is to be sent. .PARAMETER Issuer The name to be used in requests sent from Citrix ADC to IdP to uniquely identify Citrix ADC. .PARAMETER Configservice Name of the entity that is used to obtain configuration for the current authentication request. It is used only in Citrix Cloud. .PARAMETER Audience Audience for which token is being sent by Citrix ADC IdP. This is typically entity name or url that represents the recipient. .PARAMETER Skewtime This option specifies the duration for which the token sent by Citrix ADC IdP is valid. For example, if skewTime is 10, then token would be valid from (current time - 10) min to (current time + 10) min, ie 20min in all. .PARAMETER Defaultauthenticationgroup This group will be part of AAA session's internal group list. This will be helpful to admin in Nfactor flow to decide right AAA configuration for Relaying Party. In authentication policy AAA.USER.IS_MEMBER_OF("<default_auth_group>") is way to use this feature. .PARAMETER Relyingpartymetadataurl This is the endpoint at which Citrix ADC IdP can get details about Relying Party (RP) being configured. Metadata response should include endpoints for jwks_uri for RP public key(s). .PARAMETER Refreshinterval Interval at which Relying Party metadata is refreshed. .PARAMETER Encrypttoken Option to encrypt token when Citrix ADC IDP sends one. Possible values = ON, OFF .PARAMETER Signatureservice Name of the service in cloud used to sign the data. This is applicable only if signature if offloaded to cloud. .PARAMETER Signaturealg Algorithm to be used to sign OpenID tokens. Possible values = RS256, RS512 .PARAMETER Attributes Name-Value pairs of attributes to be inserted in idtoken. Configuration format is name=value_expr@@@name2=value2_expr@@@. '@@@' is used as delimiter between Name-Value pairs. name is a literal string whose value is 127 characters and does not contain '=' character. Value is advanced policy expression terminated by @@@ delimiter. Last value need not contain the delimiter. .PARAMETER Sendpassword Option to send encrypted password in idtoken. Possible values = ON, OFF .PARAMETER PassThru Return details about the created authenticationoauthidpprofile item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationoauthidpprofile -name <string> An example how to add authenticationoauthidpprofile configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationoauthidpprofile Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationoauthidpprofile/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Clientid, [ValidateScript({ $_.Length -gt 1 })] [string]$Clientsecret, [ValidateScript({ $_.Length -gt 1 })] [string]$Redirecturl, [ValidateScript({ $_.Length -gt 1 })] [string]$Issuer, [ValidateScript({ $_.Length -gt 1 })] [string]$Configservice, [string]$Audience, [double]$Skewtime = '5', [string]$Defaultauthenticationgroup, [string]$Relyingpartymetadataurl, [double]$Refreshinterval = '50', [ValidateSet('ON', 'OFF')] [string]$Encrypttoken = 'OFF', [ValidateScript({ $_.Length -gt 1 })] [string]$Signatureservice, [ValidateSet('RS256', 'RS512')] [string]$Signaturealg = 'RS256', [string]$Attributes, [ValidateSet('ON', 'OFF')] [string]$Sendpassword = 'OFF', [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationoauthidpprofile: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('clientid') ) { $payload.Add('clientid', $clientid) } if ( $PSBoundParameters.ContainsKey('clientsecret') ) { $payload.Add('clientsecret', $clientsecret) } if ( $PSBoundParameters.ContainsKey('redirecturl') ) { $payload.Add('redirecturl', $redirecturl) } if ( $PSBoundParameters.ContainsKey('issuer') ) { $payload.Add('issuer', $issuer) } if ( $PSBoundParameters.ContainsKey('configservice') ) { $payload.Add('configservice', $configservice) } if ( $PSBoundParameters.ContainsKey('audience') ) { $payload.Add('audience', $audience) } if ( $PSBoundParameters.ContainsKey('skewtime') ) { $payload.Add('skewtime', $skewtime) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('relyingpartymetadataurl') ) { $payload.Add('relyingpartymetadataurl', $relyingpartymetadataurl) } if ( $PSBoundParameters.ContainsKey('refreshinterval') ) { $payload.Add('refreshinterval', $refreshinterval) } if ( $PSBoundParameters.ContainsKey('encrypttoken') ) { $payload.Add('encrypttoken', $encrypttoken) } if ( $PSBoundParameters.ContainsKey('signatureservice') ) { $payload.Add('signatureservice', $signatureservice) } if ( $PSBoundParameters.ContainsKey('signaturealg') ) { $payload.Add('signaturealg', $signaturealg) } if ( $PSBoundParameters.ContainsKey('attributes') ) { $payload.Add('attributes', $attributes) } if ( $PSBoundParameters.ContainsKey('sendpassword') ) { $payload.Add('sendpassword', $sendpassword) } if ( $PSCmdlet.ShouldProcess("authenticationoauthidpprofile", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationoauthidpprofile -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationoauthidpprofile -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationoauthidpprofile: Finished" } } function Invoke-ADCDeleteAuthenticationoauthidpprofile { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for OAuth Identity Provider (IdP) profile resource. .PARAMETER Name Name for the new OAuth Identity Provider (IdP) single sign-on profile. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationoauthidpprofile -Name <string> An example how to delete authenticationoauthidpprofile configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationoauthidpprofile Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationoauthidpprofile/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationoauthidpprofile: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationoauthidpprofile -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationoauthidpprofile: Finished" } } function Invoke-ADCUpdateAuthenticationoauthidpprofile { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for OAuth Identity Provider (IdP) profile resource. .PARAMETER Name Name for the new OAuth Identity Provider (IdP) single sign-on profile. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER Clientid Unique identity of the relying party requesting for authentication. .PARAMETER Clientsecret Unique secret string to authorize relying party at authorization server. .PARAMETER Redirecturl URL endpoint on relying party to which the OAuth token is to be sent. .PARAMETER Issuer The name to be used in requests sent from Citrix ADC to IdP to uniquely identify Citrix ADC. .PARAMETER Configservice Name of the entity that is used to obtain configuration for the current authentication request. It is used only in Citrix Cloud. .PARAMETER Audience Audience for which token is being sent by Citrix ADC IdP. This is typically entity name or url that represents the recipient. .PARAMETER Skewtime This option specifies the duration for which the token sent by Citrix ADC IdP is valid. For example, if skewTime is 10, then token would be valid from (current time - 10) min to (current time + 10) min, ie 20min in all. .PARAMETER Defaultauthenticationgroup This group will be part of AAA session's internal group list. This will be helpful to admin in Nfactor flow to decide right AAA configuration for Relaying Party. In authentication policy AAA.USER.IS_MEMBER_OF("<default_auth_group>") is way to use this feature. .PARAMETER Relyingpartymetadataurl This is the endpoint at which Citrix ADC IdP can get details about Relying Party (RP) being configured. Metadata response should include endpoints for jwks_uri for RP public key(s). .PARAMETER Refreshinterval Interval at which Relying Party metadata is refreshed. .PARAMETER Encrypttoken Option to encrypt token when Citrix ADC IDP sends one. Possible values = ON, OFF .PARAMETER Signatureservice Name of the service in cloud used to sign the data. This is applicable only if signature if offloaded to cloud. .PARAMETER Signaturealg Algorithm to be used to sign OpenID tokens. Possible values = RS256, RS512 .PARAMETER Attributes Name-Value pairs of attributes to be inserted in idtoken. Configuration format is name=value_expr@@@name2=value2_expr@@@. '@@@' is used as delimiter between Name-Value pairs. name is a literal string whose value is 127 characters and does not contain '=' character. Value is advanced policy expression terminated by @@@ delimiter. Last value need not contain the delimiter. .PARAMETER Sendpassword Option to send encrypted password in idtoken. Possible values = ON, OFF .PARAMETER PassThru Return details about the created authenticationoauthidpprofile item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationoauthidpprofile -name <string> An example how to update authenticationoauthidpprofile configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationoauthidpprofile Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationoauthidpprofile/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Clientid, [ValidateScript({ $_.Length -gt 1 })] [string]$Clientsecret, [ValidateScript({ $_.Length -gt 1 })] [string]$Redirecturl, [ValidateScript({ $_.Length -gt 1 })] [string]$Issuer, [ValidateScript({ $_.Length -gt 1 })] [string]$Configservice, [string]$Audience, [double]$Skewtime, [string]$Defaultauthenticationgroup, [string]$Relyingpartymetadataurl, [double]$Refreshinterval, [ValidateSet('ON', 'OFF')] [string]$Encrypttoken, [ValidateScript({ $_.Length -gt 1 })] [string]$Signatureservice, [ValidateSet('RS256', 'RS512')] [string]$Signaturealg, [string]$Attributes, [ValidateSet('ON', 'OFF')] [string]$Sendpassword, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationoauthidpprofile: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('clientid') ) { $payload.Add('clientid', $clientid) } if ( $PSBoundParameters.ContainsKey('clientsecret') ) { $payload.Add('clientsecret', $clientsecret) } if ( $PSBoundParameters.ContainsKey('redirecturl') ) { $payload.Add('redirecturl', $redirecturl) } if ( $PSBoundParameters.ContainsKey('issuer') ) { $payload.Add('issuer', $issuer) } if ( $PSBoundParameters.ContainsKey('configservice') ) { $payload.Add('configservice', $configservice) } if ( $PSBoundParameters.ContainsKey('audience') ) { $payload.Add('audience', $audience) } if ( $PSBoundParameters.ContainsKey('skewtime') ) { $payload.Add('skewtime', $skewtime) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('relyingpartymetadataurl') ) { $payload.Add('relyingpartymetadataurl', $relyingpartymetadataurl) } if ( $PSBoundParameters.ContainsKey('refreshinterval') ) { $payload.Add('refreshinterval', $refreshinterval) } if ( $PSBoundParameters.ContainsKey('encrypttoken') ) { $payload.Add('encrypttoken', $encrypttoken) } if ( $PSBoundParameters.ContainsKey('signatureservice') ) { $payload.Add('signatureservice', $signatureservice) } if ( $PSBoundParameters.ContainsKey('signaturealg') ) { $payload.Add('signaturealg', $signaturealg) } if ( $PSBoundParameters.ContainsKey('attributes') ) { $payload.Add('attributes', $attributes) } if ( $PSBoundParameters.ContainsKey('sendpassword') ) { $payload.Add('sendpassword', $sendpassword) } if ( $PSCmdlet.ShouldProcess("authenticationoauthidpprofile", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationoauthidpprofile -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationoauthidpprofile -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationoauthidpprofile: Finished" } } function Invoke-ADCUnsetAuthenticationoauthidpprofile { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for OAuth Identity Provider (IdP) profile resource. .PARAMETER Name Name for the new OAuth Identity Provider (IdP) single sign-on profile. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER Issuer The name to be used in requests sent from Citrix ADC to IdP to uniquely identify Citrix ADC. .PARAMETER Configservice Name of the entity that is used to obtain configuration for the current authentication request. It is used only in Citrix Cloud. .PARAMETER Audience Audience for which token is being sent by Citrix ADC IdP. This is typically entity name or url that represents the recipient. .PARAMETER Skewtime This option specifies the duration for which the token sent by Citrix ADC IdP is valid. For example, if skewTime is 10, then token would be valid from (current time - 10) min to (current time + 10) min, ie 20min in all. .PARAMETER Defaultauthenticationgroup This group will be part of AAA session's internal group list. This will be helpful to admin in Nfactor flow to decide right AAA configuration for Relaying Party. In authentication policy AAA.USER.IS_MEMBER_OF("<default_auth_group>") is way to use this feature. .PARAMETER Relyingpartymetadataurl This is the endpoint at which Citrix ADC IdP can get details about Relying Party (RP) being configured. Metadata response should include endpoints for jwks_uri for RP public key(s). .PARAMETER Refreshinterval Interval at which Relying Party metadata is refreshed. .PARAMETER Encrypttoken Option to encrypt token when Citrix ADC IDP sends one. Possible values = ON, OFF .PARAMETER Signatureservice Name of the service in cloud used to sign the data. This is applicable only if signature if offloaded to cloud. .PARAMETER Signaturealg Algorithm to be used to sign OpenID tokens. Possible values = RS256, RS512 .PARAMETER Attributes Name-Value pairs of attributes to be inserted in idtoken. Configuration format is name=value_expr@@@name2=value2_expr@@@. '@@@' is used as delimiter between Name-Value pairs. name is a literal string whose value is 127 characters and does not contain '=' character. Value is advanced policy expression terminated by @@@ delimiter. Last value need not contain the delimiter. .PARAMETER Sendpassword Option to send encrypted password in idtoken. Possible values = ON, OFF .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationoauthidpprofile -name <string> An example how to unset authenticationoauthidpprofile configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationoauthidpprofile Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationoauthidpprofile Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Boolean]$issuer, [Boolean]$configservice, [Boolean]$audience, [Boolean]$skewtime, [Boolean]$defaultauthenticationgroup, [Boolean]$relyingpartymetadataurl, [Boolean]$refreshinterval, [Boolean]$encrypttoken, [Boolean]$signatureservice, [Boolean]$signaturealg, [Boolean]$attributes, [Boolean]$sendpassword ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationoauthidpprofile: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('issuer') ) { $payload.Add('issuer', $issuer) } if ( $PSBoundParameters.ContainsKey('configservice') ) { $payload.Add('configservice', $configservice) } if ( $PSBoundParameters.ContainsKey('audience') ) { $payload.Add('audience', $audience) } if ( $PSBoundParameters.ContainsKey('skewtime') ) { $payload.Add('skewtime', $skewtime) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('relyingpartymetadataurl') ) { $payload.Add('relyingpartymetadataurl', $relyingpartymetadataurl) } if ( $PSBoundParameters.ContainsKey('refreshinterval') ) { $payload.Add('refreshinterval', $refreshinterval) } if ( $PSBoundParameters.ContainsKey('encrypttoken') ) { $payload.Add('encrypttoken', $encrypttoken) } if ( $PSBoundParameters.ContainsKey('signatureservice') ) { $payload.Add('signatureservice', $signatureservice) } if ( $PSBoundParameters.ContainsKey('signaturealg') ) { $payload.Add('signaturealg', $signaturealg) } if ( $PSBoundParameters.ContainsKey('attributes') ) { $payload.Add('attributes', $attributes) } if ( $PSBoundParameters.ContainsKey('sendpassword') ) { $payload.Add('sendpassword', $sendpassword) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationoauthidpprofile -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationoauthidpprofile: Finished" } } function Invoke-ADCGetAuthenticationoauthidpprofile { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for OAuth Identity Provider (IdP) profile resource. .PARAMETER Name Name for the new OAuth Identity Provider (IdP) single sign-on profile. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER GetAll Retrieve all authenticationoauthidpprofile object(s). .PARAMETER Count If specified, the count of the authenticationoauthidpprofile object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidpprofile Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidpprofile -GetAll Get all authenticationoauthidpprofile data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidpprofile -Count Get the number of authenticationoauthidpprofile objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidpprofile -name <string> Get authenticationoauthidpprofile object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationoauthidpprofile -Filter @{ 'name'='<value>' } Get authenticationoauthidpprofile data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationoauthidpprofile Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationoauthidpprofile/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationoauthidpprofile: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationoauthidpprofile objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidpprofile -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationoauthidpprofile objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidpprofile -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationoauthidpprofile objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidpprofile -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationoauthidpprofile configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidpprofile -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationoauthidpprofile configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationoauthidpprofile -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationoauthidpprofile: Ended" } } function Invoke-ADCRenameAuthenticationpolicy { <# .SYNOPSIS Rename Authentication configuration Object. .DESCRIPTION Configuration for Authentication Policy resource. .PARAMETER Name Name for the advance AUTHENTICATION policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after AUTHENTICATION policy is created. .PARAMETER Newname New name for the authentication policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) hash (#), space ( ), at (@), equals (=), colon (:), and underscore characters. .PARAMETER PassThru Return details about the created authenticationpolicy item. .EXAMPLE PS C:\>Invoke-ADCRenameAuthenticationpolicy -name <string> -newname <string> An example how to rename authenticationpolicy configuration Object(s). .NOTES File Name : Invoke-ADCRenameAuthenticationpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationpolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Newname, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCRenameAuthenticationpolicy: Starting" } process { try { $payload = @{ name = $name newname = $newname } if ( $PSCmdlet.ShouldProcess("authenticationpolicy", "Rename Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationpolicy -Action rename -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationpolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCRenameAuthenticationpolicy: Finished" } } function Invoke-ADCUpdateAuthenticationpolicy { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for Authentication Policy resource. .PARAMETER Name Name for the advance AUTHENTICATION policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after AUTHENTICATION policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to determine whether to attempt to authenticate the user with the AUTHENTICATION server. .PARAMETER Action Name of the authentication action to be performed if the policy matches. .PARAMETER Undefaction Action to perform if the result of policy evaluation is undefined (UNDEF). An UNDEF event indicates an internal error condition. Only the above built-in actions can be used. .PARAMETER Comment Any comments to preserve information about this policy. .PARAMETER Logaction Name of messagelog action to use when a request matches this policy. .PARAMETER PassThru Return details about the created authenticationpolicy item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationpolicy -name <string> An example how to update authenticationpolicy configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationpolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Rule, [string]$Action, [string]$Undefaction, [string]$Comment, [string]$Logaction, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationpolicy: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('rule') ) { $payload.Add('rule', $rule) } if ( $PSBoundParameters.ContainsKey('action') ) { $payload.Add('action', $action) } if ( $PSBoundParameters.ContainsKey('undefaction') ) { $payload.Add('undefaction', $undefaction) } if ( $PSBoundParameters.ContainsKey('comment') ) { $payload.Add('comment', $comment) } if ( $PSBoundParameters.ContainsKey('logaction') ) { $payload.Add('logaction', $logaction) } if ( $PSCmdlet.ShouldProcess("authenticationpolicy", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationpolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationpolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationpolicy: Finished" } } function Invoke-ADCUnsetAuthenticationpolicy { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for Authentication Policy resource. .PARAMETER Name Name for the advance AUTHENTICATION policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after AUTHENTICATION policy is created. .PARAMETER Undefaction Action to perform if the result of policy evaluation is undefined (UNDEF). An UNDEF event indicates an internal error condition. Only the above built-in actions can be used. .PARAMETER Comment Any comments to preserve information about this policy. .PARAMETER Logaction Name of messagelog action to use when a request matches this policy. .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationpolicy -name <string> An example how to unset authenticationpolicy configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationpolicy Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Boolean]$undefaction, [Boolean]$comment, [Boolean]$logaction ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationpolicy: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('undefaction') ) { $payload.Add('undefaction', $undefaction) } if ( $PSBoundParameters.ContainsKey('comment') ) { $payload.Add('comment', $comment) } if ( $PSBoundParameters.ContainsKey('logaction') ) { $payload.Add('logaction', $logaction) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationpolicy -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationpolicy: Finished" } } function Invoke-ADCDeleteAuthenticationpolicy { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for Authentication Policy resource. .PARAMETER Name Name for the advance AUTHENTICATION policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after AUTHENTICATION policy is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationpolicy -Name <string> An example how to delete authenticationpolicy configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationpolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationpolicy: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationpolicy -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationpolicy: Finished" } } function Invoke-ADCAddAuthenticationpolicy { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for Authentication Policy resource. .PARAMETER Name Name for the advance AUTHENTICATION policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after AUTHENTICATION policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to determine whether to attempt to authenticate the user with the AUTHENTICATION server. .PARAMETER Action Name of the authentication action to be performed if the policy matches. .PARAMETER Undefaction Action to perform if the result of policy evaluation is undefined (UNDEF). An UNDEF event indicates an internal error condition. Only the above built-in actions can be used. .PARAMETER Comment Any comments to preserve information about this policy. .PARAMETER Logaction Name of messagelog action to use when a request matches this policy. .PARAMETER PassThru Return details about the created authenticationpolicy item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationpolicy -name <string> -rule <string> -action <string> An example how to add authenticationpolicy configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationpolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(Mandatory)] [string]$Rule, [Parameter(Mandatory)] [string]$Action, [string]$Undefaction, [string]$Comment, [string]$Logaction, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationpolicy: Starting" } process { try { $payload = @{ name = $name rule = $rule action = $action } if ( $PSBoundParameters.ContainsKey('undefaction') ) { $payload.Add('undefaction', $undefaction) } if ( $PSBoundParameters.ContainsKey('comment') ) { $payload.Add('comment', $comment) } if ( $PSBoundParameters.ContainsKey('logaction') ) { $payload.Add('logaction', $logaction) } if ( $PSCmdlet.ShouldProcess("authenticationpolicy", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationpolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationpolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationpolicy: Finished" } } function Invoke-ADCGetAuthenticationpolicy { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for Authentication Policy resource. .PARAMETER Name Name for the advance AUTHENTICATION policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after AUTHENTICATION policy is created. .PARAMETER GetAll Retrieve all authenticationpolicy object(s). .PARAMETER Count If specified, the count of the authenticationpolicy object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicy Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicy -GetAll Get all authenticationpolicy data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicy -Count Get the number of authenticationpolicy objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicy -name <string> Get authenticationpolicy object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicy -Filter @{ 'name'='<value>' } Get authenticationpolicy data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationpolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationpolicy: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationpolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationpolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationpolicy objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationpolicy configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationpolicy configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationpolicy: Ended" } } function Invoke-ADCAddAuthenticationpolicylabel { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for authentication policy label resource. .PARAMETER Labelname Name for the new authentication policy label. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. .PARAMETER Type Type of feature (aaatm or rba) against which to match the policies bound to this policy label. Possible values = AAATM_REQ, RBA_REQ .PARAMETER Comment Any comments to preserve information about this authentication policy label. .PARAMETER Loginschema Login schema associated with authentication policy label. Login schema defines the UI rendering by providing customization option of the fields. If user intervention is not needed for a given factor such as group extraction, a loginSchema whose authentication schema is "noschema" should be used. .PARAMETER PassThru Return details about the created authenticationpolicylabel item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationpolicylabel -labelname <string> An example how to add authenticationpolicylabel configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationpolicylabel Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationpolicylabel/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Labelname, [ValidateSet('AAATM_REQ', 'RBA_REQ')] [string]$Type = 'AAATM_REQ', [string]$Comment, [string]$Loginschema, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationpolicylabel: Starting" } process { try { $payload = @{ labelname = $labelname } if ( $PSBoundParameters.ContainsKey('type') ) { $payload.Add('type', $type) } if ( $PSBoundParameters.ContainsKey('comment') ) { $payload.Add('comment', $comment) } if ( $PSBoundParameters.ContainsKey('loginschema') ) { $payload.Add('loginschema', $loginschema) } if ( $PSCmdlet.ShouldProcess("authenticationpolicylabel", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationpolicylabel -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationpolicylabel -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationpolicylabel: Finished" } } function Invoke-ADCDeleteAuthenticationpolicylabel { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for authentication policy label resource. .PARAMETER Labelname Name for the new authentication policy label. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationpolicylabel -Labelname <string> An example how to delete authenticationpolicylabel configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationpolicylabel Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationpolicylabel/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Labelname ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationpolicylabel: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$labelname", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationpolicylabel -NitroPath nitro/v1/config -Resource $labelname -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationpolicylabel: Finished" } } function Invoke-ADCRenameAuthenticationpolicylabel { <# .SYNOPSIS Rename Authentication configuration Object. .DESCRIPTION Configuration for authentication policy label resource. .PARAMETER Labelname Name for the new authentication policy label. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. .PARAMETER Newname The new name of the auth policy label. .PARAMETER PassThru Return details about the created authenticationpolicylabel item. .EXAMPLE PS C:\>Invoke-ADCRenameAuthenticationpolicylabel -labelname <string> -newname <string> An example how to rename authenticationpolicylabel configuration Object(s). .NOTES File Name : Invoke-ADCRenameAuthenticationpolicylabel Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationpolicylabel/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Labelname, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Newname, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCRenameAuthenticationpolicylabel: Starting" } process { try { $payload = @{ labelname = $labelname newname = $newname } if ( $PSCmdlet.ShouldProcess("authenticationpolicylabel", "Rename Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationpolicylabel -Action rename -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationpolicylabel -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCRenameAuthenticationpolicylabel: Finished" } } function Invoke-ADCGetAuthenticationpolicylabel { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for authentication policy label resource. .PARAMETER Labelname Name for the new authentication policy label. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. .PARAMETER GetAll Retrieve all authenticationpolicylabel object(s). .PARAMETER Count If specified, the count of the authenticationpolicylabel object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicylabel Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicylabel -GetAll Get all authenticationpolicylabel data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicylabel -Count Get the number of authenticationpolicylabel objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicylabel -name <string> Get authenticationpolicylabel object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicylabel -Filter @{ 'name'='<value>' } Get authenticationpolicylabel data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationpolicylabel Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationpolicylabel/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [string]$Labelname, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationpolicylabel: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationpolicylabel objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicylabel -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationpolicylabel objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicylabel -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationpolicylabel objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicylabel -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationpolicylabel configuration for property 'labelname'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicylabel -NitroPath nitro/v1/config -Resource $labelname -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationpolicylabel configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicylabel -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationpolicylabel: Ended" } } function Invoke-ADCAddAuthenticationpolicylabelauthenticationpolicybinding { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationpolicy that can be bound to authenticationpolicylabel. .PARAMETER Labelname Name of the authentication policy label to which to bind the policy. .PARAMETER Policyname Name of the authentication policy to bind to the policy label. .PARAMETER Priority Specifies the priority of the policy. .PARAMETER Gotopriorityexpression Expression specifying the priority of the next policy which will get evaluated if the current policy rule evaluates to TRUE. .PARAMETER Nextfactor On success invoke label. .PARAMETER PassThru Return details about the created authenticationpolicylabel_authenticationpolicy_binding item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationpolicylabelauthenticationpolicybinding -labelname <string> -policyname <string> -priority <double> An example how to add authenticationpolicylabel_authenticationpolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationpolicylabelauthenticationpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationpolicylabel_authenticationpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Labelname, [Parameter(Mandatory)] [string]$Policyname, [Parameter(Mandatory)] [double]$Priority, [string]$Gotopriorityexpression, [string]$Nextfactor, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationpolicylabelauthenticationpolicybinding: Starting" } process { try { $payload = @{ labelname = $labelname policyname = $policyname priority = $priority } if ( $PSBoundParameters.ContainsKey('gotopriorityexpression') ) { $payload.Add('gotopriorityexpression', $gotopriorityexpression) } if ( $PSBoundParameters.ContainsKey('nextfactor') ) { $payload.Add('nextfactor', $nextfactor) } if ( $PSCmdlet.ShouldProcess("authenticationpolicylabel_authenticationpolicy_binding", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationpolicylabel_authenticationpolicy_binding -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationpolicylabelauthenticationpolicybinding -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationpolicylabelauthenticationpolicybinding: Finished" } } function Invoke-ADCDeleteAuthenticationpolicylabelauthenticationpolicybinding { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationpolicy that can be bound to authenticationpolicylabel. .PARAMETER Labelname Name of the authentication policy label to which to bind the policy. .PARAMETER Policyname Name of the authentication policy to bind to the policy label. .PARAMETER Priority Specifies the priority of the policy. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationpolicylabelauthenticationpolicybinding -Labelname <string> An example how to delete authenticationpolicylabel_authenticationpolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationpolicylabelauthenticationpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationpolicylabel_authenticationpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Labelname, [string]$Policyname, [double]$Priority ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationpolicylabelauthenticationpolicybinding: Starting" } process { try { $arguments = @{ } if ( $PSBoundParameters.ContainsKey('Policyname') ) { $arguments.Add('policyname', $Policyname) } if ( $PSBoundParameters.ContainsKey('Priority') ) { $arguments.Add('priority', $Priority) } if ( $PSCmdlet.ShouldProcess("$labelname", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationpolicylabel_authenticationpolicy_binding -NitroPath nitro/v1/config -Resource $labelname -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationpolicylabelauthenticationpolicybinding: Finished" } } function Invoke-ADCGetAuthenticationpolicylabelauthenticationpolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationpolicy that can be bound to authenticationpolicylabel. .PARAMETER Labelname Name of the authentication policy label to which to bind the policy. .PARAMETER GetAll Retrieve all authenticationpolicylabel_authenticationpolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationpolicylabel_authenticationpolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicylabelauthenticationpolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicylabelauthenticationpolicybinding -GetAll Get all authenticationpolicylabel_authenticationpolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicylabelauthenticationpolicybinding -Count Get the number of authenticationpolicylabel_authenticationpolicy_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicylabelauthenticationpolicybinding -name <string> Get authenticationpolicylabel_authenticationpolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicylabelauthenticationpolicybinding -Filter @{ 'name'='<value>' } Get authenticationpolicylabel_authenticationpolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationpolicylabelauthenticationpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationpolicylabel_authenticationpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [string]$Labelname, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationpolicylabelauthenticationpolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationpolicylabel_authenticationpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicylabel_authenticationpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationpolicylabel_authenticationpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicylabel_authenticationpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationpolicylabel_authenticationpolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicylabel_authenticationpolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationpolicylabel_authenticationpolicy_binding configuration for property 'labelname'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicylabel_authenticationpolicy_binding -NitroPath nitro/v1/config -Resource $labelname -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationpolicylabel_authenticationpolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicylabel_authenticationpolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationpolicylabelauthenticationpolicybinding: Ended" } } function Invoke-ADCGetAuthenticationpolicylabelbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object which returns the resources bound to authenticationpolicylabel. .PARAMETER Labelname Name of the authorization policy label. .PARAMETER GetAll Retrieve all authenticationpolicylabel_binding object(s). .PARAMETER Count If specified, the count of the authenticationpolicylabel_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicylabelbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicylabelbinding -GetAll Get all authenticationpolicylabel_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicylabelbinding -name <string> Get authenticationpolicylabel_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicylabelbinding -Filter @{ 'name'='<value>' } Get authenticationpolicylabel_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationpolicylabelbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationpolicylabel_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [string]$Labelname, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationpolicylabelbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationpolicylabel_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicylabel_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationpolicylabel_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicylabel_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationpolicylabel_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicylabel_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationpolicylabel_binding configuration for property 'labelname'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicylabel_binding -NitroPath nitro/v1/config -Resource $labelname -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationpolicylabel_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicylabel_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationpolicylabelbinding: Ended" } } function Invoke-ADCGetAuthenticationpolicyauthenticationpolicylabelbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationpolicylabel that can be bound to authenticationpolicy. .PARAMETER Name Name of the advance authentication policy. .PARAMETER GetAll Retrieve all authenticationpolicy_authenticationpolicylabel_binding object(s). .PARAMETER Count If specified, the count of the authenticationpolicy_authenticationpolicylabel_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicyauthenticationpolicylabelbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicyauthenticationpolicylabelbinding -GetAll Get all authenticationpolicy_authenticationpolicylabel_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicyauthenticationpolicylabelbinding -Count Get the number of authenticationpolicy_authenticationpolicylabel_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicyauthenticationpolicylabelbinding -name <string> Get authenticationpolicy_authenticationpolicylabel_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicyauthenticationpolicylabelbinding -Filter @{ 'name'='<value>' } Get authenticationpolicy_authenticationpolicylabel_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationpolicyauthenticationpolicylabelbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationpolicy_authenticationpolicylabel_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationpolicyauthenticationpolicylabelbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationpolicy_authenticationpolicylabel_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy_authenticationpolicylabel_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationpolicy_authenticationpolicylabel_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy_authenticationpolicylabel_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationpolicy_authenticationpolicylabel_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy_authenticationpolicylabel_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationpolicy_authenticationpolicylabel_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy_authenticationpolicylabel_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationpolicy_authenticationpolicylabel_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy_authenticationpolicylabel_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationpolicyauthenticationpolicylabelbinding: Ended" } } function Invoke-ADCGetAuthenticationpolicyauthenticationvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationvserver that can be bound to authenticationpolicy. .PARAMETER Name Name of the advance authentication policy. .PARAMETER GetAll Retrieve all authenticationpolicy_authenticationvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationpolicy_authenticationvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicyauthenticationvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicyauthenticationvserverbinding -GetAll Get all authenticationpolicy_authenticationvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicyauthenticationvserverbinding -Count Get the number of authenticationpolicy_authenticationvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicyauthenticationvserverbinding -name <string> Get authenticationpolicy_authenticationvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicyauthenticationvserverbinding -Filter @{ 'name'='<value>' } Get authenticationpolicy_authenticationvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationpolicyauthenticationvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationpolicy_authenticationvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationpolicyauthenticationvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationpolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationpolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationpolicy_authenticationvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationpolicy_authenticationvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationpolicy_authenticationvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationpolicyauthenticationvserverbinding: Ended" } } function Invoke-ADCGetAuthenticationpolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object which returns the resources bound to authenticationpolicy. .PARAMETER Name Name of the advance authentication policy. .PARAMETER GetAll Retrieve all authenticationpolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationpolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicybinding -GetAll Get all authenticationpolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicybinding -name <string> Get authenticationpolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicybinding -Filter @{ 'name'='<value>' } Get authenticationpolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationpolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationpolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationpolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationpolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationpolicybinding: Ended" } } function Invoke-ADCGetAuthenticationpolicysystemglobalbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the systemglobal that can be bound to authenticationpolicy. .PARAMETER Name Name of the advance authentication policy. .PARAMETER GetAll Retrieve all authenticationpolicy_systemglobal_binding object(s). .PARAMETER Count If specified, the count of the authenticationpolicy_systemglobal_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicysystemglobalbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicysystemglobalbinding -GetAll Get all authenticationpolicy_systemglobal_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicysystemglobalbinding -Count Get the number of authenticationpolicy_systemglobal_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicysystemglobalbinding -name <string> Get authenticationpolicy_systemglobal_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpolicysystemglobalbinding -Filter @{ 'name'='<value>' } Get authenticationpolicy_systemglobal_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationpolicysystemglobalbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationpolicy_systemglobal_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationpolicysystemglobalbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationpolicy_systemglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy_systemglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationpolicy_systemglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy_systemglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationpolicy_systemglobal_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy_systemglobal_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationpolicy_systemglobal_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy_systemglobal_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationpolicy_systemglobal_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpolicy_systemglobal_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationpolicysystemglobalbinding: Ended" } } function Invoke-ADCAddAuthenticationpushservice { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for Service details for sending push notifications resource. .PARAMETER Name Name for the push service. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at sign (@), equal sign (=), and hyphen (-) characters. Cannot be changed after the profile is created. CLI Users: If the name includes one or more spaces, enclose the name in double or single quotation marks (for example, "my push service" or 'my push service'). . .PARAMETER Clientid Unique identity for communicating with Citrix Push server in cloud. .PARAMETER Clientsecret Unique secret for communicating with Citrix Push server in cloud. .PARAMETER Customerid Customer id/name of the account in cloud that is used to create clientid/secret pair. .PARAMETER Refreshinterval Interval at which certificates or idtoken is refreshed. .PARAMETER PassThru Return details about the created authenticationpushservice item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationpushservice -name <string> An example how to add authenticationpushservice configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationpushservice Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationpushservice/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [ValidateLength(1, 127)] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Clientid, [ValidateScript({ $_.Length -gt 1 })] [string]$Clientsecret, [ValidateScript({ $_.Length -gt 1 })] [string]$Customerid, [double]$Refreshinterval = '50', [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationpushservice: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('clientid') ) { $payload.Add('clientid', $clientid) } if ( $PSBoundParameters.ContainsKey('clientsecret') ) { $payload.Add('clientsecret', $clientsecret) } if ( $PSBoundParameters.ContainsKey('customerid') ) { $payload.Add('customerid', $customerid) } if ( $PSBoundParameters.ContainsKey('refreshinterval') ) { $payload.Add('refreshinterval', $refreshinterval) } if ( $PSCmdlet.ShouldProcess("authenticationpushservice", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationpushservice -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationpushservice -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationpushservice: Finished" } } function Invoke-ADCDeleteAuthenticationpushservice { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for Service details for sending push notifications resource. .PARAMETER Name Name for the push service. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at sign (@), equal sign (=), and hyphen (-) characters. Cannot be changed after the profile is created. CLI Users: If the name includes one or more spaces, enclose the name in double or single quotation marks (for example, "my push service" or 'my push service'). . .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationpushservice -Name <string> An example how to delete authenticationpushservice configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationpushservice Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationpushservice/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationpushservice: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationpushservice -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationpushservice: Finished" } } function Invoke-ADCUpdateAuthenticationpushservice { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for Service details for sending push notifications resource. .PARAMETER Name Name for the push service. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at sign (@), equal sign (=), and hyphen (-) characters. Cannot be changed after the profile is created. CLI Users: If the name includes one or more spaces, enclose the name in double or single quotation marks (for example, "my push service" or 'my push service'). . .PARAMETER Clientid Unique identity for communicating with Citrix Push server in cloud. .PARAMETER Clientsecret Unique secret for communicating with Citrix Push server in cloud. .PARAMETER Customerid Customer id/name of the account in cloud that is used to create clientid/secret pair. .PARAMETER Refreshinterval Interval at which certificates or idtoken is refreshed. .PARAMETER PassThru Return details about the created authenticationpushservice item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationpushservice -name <string> An example how to update authenticationpushservice configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationpushservice Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationpushservice/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [ValidateLength(1, 127)] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Clientid, [ValidateScript({ $_.Length -gt 1 })] [string]$Clientsecret, [ValidateScript({ $_.Length -gt 1 })] [string]$Customerid, [double]$Refreshinterval, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationpushservice: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('clientid') ) { $payload.Add('clientid', $clientid) } if ( $PSBoundParameters.ContainsKey('clientsecret') ) { $payload.Add('clientsecret', $clientsecret) } if ( $PSBoundParameters.ContainsKey('customerid') ) { $payload.Add('customerid', $customerid) } if ( $PSBoundParameters.ContainsKey('refreshinterval') ) { $payload.Add('refreshinterval', $refreshinterval) } if ( $PSCmdlet.ShouldProcess("authenticationpushservice", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationpushservice -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationpushservice -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationpushservice: Finished" } } function Invoke-ADCUnsetAuthenticationpushservice { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for Service details for sending push notifications resource. .PARAMETER Name Name for the push service. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at sign (@), equal sign (=), and hyphen (-) characters. Cannot be changed after the profile is created. CLI Users: If the name includes one or more spaces, enclose the name in double or single quotation marks (for example, "my push service" or 'my push service'). . .PARAMETER Refreshinterval Interval at which certificates or idtoken is refreshed. .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationpushservice -name <string> An example how to unset authenticationpushservice configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationpushservice Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationpushservice Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [ValidateLength(1, 127)] [string]$Name, [Boolean]$refreshinterval ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationpushservice: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('refreshinterval') ) { $payload.Add('refreshinterval', $refreshinterval) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationpushservice -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationpushservice: Finished" } } function Invoke-ADCGetAuthenticationpushservice { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for Service details for sending push notifications resource. .PARAMETER Name Name for the push service. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at sign (@), equal sign (=), and hyphen (-) characters. Cannot be changed after the profile is created. CLI Users: If the name includes one or more spaces, enclose the name in double or single quotation marks (for example, "my push service" or 'my push service'). . .PARAMETER GetAll Retrieve all authenticationpushservice object(s). .PARAMETER Count If specified, the count of the authenticationpushservice object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpushservice Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpushservice -GetAll Get all authenticationpushservice data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpushservice -Count Get the number of authenticationpushservice objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpushservice -name <string> Get authenticationpushservice object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationpushservice -Filter @{ 'name'='<value>' } Get authenticationpushservice data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationpushservice Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationpushservice/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [ValidateLength(1, 127)] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationpushservice: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationpushservice objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpushservice -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationpushservice objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpushservice -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationpushservice objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpushservice -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationpushservice configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpushservice -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationpushservice configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationpushservice -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationpushservice: Ended" } } function Invoke-ADCUnsetAuthenticationradiusaction { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for RADIUS action resource. .PARAMETER Name Name for the RADIUS action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the RADIUS action is added. .PARAMETER Serverport Port number on which the RADIUS server listens for connections. .PARAMETER Authtimeout Number of seconds the Citrix ADC waits for a response from the RADIUS server. .PARAMETER Radnasip If enabled, the Citrix ADC IP address (NSIP) is sent to the RADIUS server as the Network Access Server IP (NASIP) address. The RADIUS protocol defines the meaning and use of the NASIP address. Possible values = ENABLED, DISABLED .PARAMETER Radnasid If configured, this string is sent to the RADIUS server as the Network Access Server ID (NASID). .PARAMETER Radvendorid RADIUS vendor ID attribute, used for RADIUS group extraction. .PARAMETER Radattributetype RADIUS attribute type, used for RADIUS group extraction. .PARAMETER Radgroupsprefix RADIUS groups prefix string. This groups prefix precedes the group names within a RADIUS attribute for RADIUS group extraction. .PARAMETER Radgroupseparator RADIUS group separator string The group separator delimits group names within a RADIUS attribute for RADIUS group extraction. .PARAMETER Passencoding Encoding type for passwords in RADIUS packets that the Citrix ADC sends to the RADIUS server. Possible values = pap, chap, mschapv1, mschapv2 .PARAMETER Ipvendorid Vendor ID of the intranet IP attribute in the RADIUS response. NOTE: A value of 0 indicates that the attribute is not vendor encoded. .PARAMETER Ipattributetype Remote IP address attribute type in a RADIUS response. .PARAMETER Accounting Whether the RADIUS server is currently accepting accounting messages. Possible values = ON, OFF .PARAMETER Pwdvendorid Vendor ID of the attribute, in the RADIUS response, used to extract the user password. .PARAMETER Pwdattributetype Vendor-specific password attribute type in a RADIUS response. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER Callingstationid Send Calling-Station-ID of the client to the RADIUS server. IP Address of the client is sent as its Calling-Station-ID. Possible values = ENABLED, DISABLED .PARAMETER Authservretry Number of retry by the Citrix ADC before getting response from the RADIUS server. .PARAMETER Authentication Configure the RADIUS server state to accept or refuse authentication messages. Possible values = ON, OFF .PARAMETER Tunnelendpointclientip Send Tunnel Endpoint Client IP address to the RADIUS server. Possible values = ENABLED, DISABLED .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationradiusaction -name <string> An example how to unset authenticationradiusaction configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationradiusaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationradiusaction Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Boolean]$serverport, [Boolean]$authtimeout, [Boolean]$radnasip, [Boolean]$radnasid, [Boolean]$radvendorid, [Boolean]$radattributetype, [Boolean]$radgroupsprefix, [Boolean]$radgroupseparator, [Boolean]$passencoding, [Boolean]$ipvendorid, [Boolean]$ipattributetype, [Boolean]$accounting, [Boolean]$pwdvendorid, [Boolean]$pwdattributetype, [Boolean]$defaultauthenticationgroup, [Boolean]$callingstationid, [Boolean]$authservretry, [Boolean]$authentication, [Boolean]$tunnelendpointclientip ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationradiusaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('serverport') ) { $payload.Add('serverport', $serverport) } if ( $PSBoundParameters.ContainsKey('authtimeout') ) { $payload.Add('authtimeout', $authtimeout) } if ( $PSBoundParameters.ContainsKey('radnasip') ) { $payload.Add('radnasip', $radnasip) } if ( $PSBoundParameters.ContainsKey('radnasid') ) { $payload.Add('radnasid', $radnasid) } if ( $PSBoundParameters.ContainsKey('radvendorid') ) { $payload.Add('radvendorid', $radvendorid) } if ( $PSBoundParameters.ContainsKey('radattributetype') ) { $payload.Add('radattributetype', $radattributetype) } if ( $PSBoundParameters.ContainsKey('radgroupsprefix') ) { $payload.Add('radgroupsprefix', $radgroupsprefix) } if ( $PSBoundParameters.ContainsKey('radgroupseparator') ) { $payload.Add('radgroupseparator', $radgroupseparator) } if ( $PSBoundParameters.ContainsKey('passencoding') ) { $payload.Add('passencoding', $passencoding) } if ( $PSBoundParameters.ContainsKey('ipvendorid') ) { $payload.Add('ipvendorid', $ipvendorid) } if ( $PSBoundParameters.ContainsKey('ipattributetype') ) { $payload.Add('ipattributetype', $ipattributetype) } if ( $PSBoundParameters.ContainsKey('accounting') ) { $payload.Add('accounting', $accounting) } if ( $PSBoundParameters.ContainsKey('pwdvendorid') ) { $payload.Add('pwdvendorid', $pwdvendorid) } if ( $PSBoundParameters.ContainsKey('pwdattributetype') ) { $payload.Add('pwdattributetype', $pwdattributetype) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('callingstationid') ) { $payload.Add('callingstationid', $callingstationid) } if ( $PSBoundParameters.ContainsKey('authservretry') ) { $payload.Add('authservretry', $authservretry) } if ( $PSBoundParameters.ContainsKey('authentication') ) { $payload.Add('authentication', $authentication) } if ( $PSBoundParameters.ContainsKey('tunnelendpointclientip') ) { $payload.Add('tunnelendpointclientip', $tunnelendpointclientip) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationradiusaction -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationradiusaction: Finished" } } function Invoke-ADCDeleteAuthenticationradiusaction { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for RADIUS action resource. .PARAMETER Name Name for the RADIUS action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the RADIUS action is added. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationradiusaction -Name <string> An example how to delete authenticationradiusaction configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationradiusaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationradiusaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationradiusaction: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationradiusaction -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationradiusaction: Finished" } } function Invoke-ADCUpdateAuthenticationradiusaction { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for RADIUS action resource. .PARAMETER Name Name for the RADIUS action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the RADIUS action is added. .PARAMETER Serverip IP address assigned to the RADIUS server. .PARAMETER Servername RADIUS server name as a FQDN. Mutually exclusive with RADIUS IP address. .PARAMETER Serverport Port number on which the RADIUS server listens for connections. .PARAMETER Authtimeout Number of seconds the Citrix ADC waits for a response from the RADIUS server. .PARAMETER Radkey Key shared between the RADIUS server and the Citrix ADC. Required to allow the Citrix ADC to communicate with the RADIUS server. .PARAMETER Radnasip If enabled, the Citrix ADC IP address (NSIP) is sent to the RADIUS server as the Network Access Server IP (NASIP) address. The RADIUS protocol defines the meaning and use of the NASIP address. Possible values = ENABLED, DISABLED .PARAMETER Radnasid If configured, this string is sent to the RADIUS server as the Network Access Server ID (NASID). .PARAMETER Radvendorid RADIUS vendor ID attribute, used for RADIUS group extraction. .PARAMETER Radattributetype RADIUS attribute type, used for RADIUS group extraction. .PARAMETER Radgroupsprefix RADIUS groups prefix string. This groups prefix precedes the group names within a RADIUS attribute for RADIUS group extraction. .PARAMETER Radgroupseparator RADIUS group separator string The group separator delimits group names within a RADIUS attribute for RADIUS group extraction. .PARAMETER Passencoding Encoding type for passwords in RADIUS packets that the Citrix ADC sends to the RADIUS server. Possible values = pap, chap, mschapv1, mschapv2 .PARAMETER Ipvendorid Vendor ID of the intranet IP attribute in the RADIUS response. NOTE: A value of 0 indicates that the attribute is not vendor encoded. .PARAMETER Ipattributetype Remote IP address attribute type in a RADIUS response. .PARAMETER Accounting Whether the RADIUS server is currently accepting accounting messages. Possible values = ON, OFF .PARAMETER Pwdvendorid Vendor ID of the attribute, in the RADIUS response, used to extract the user password. .PARAMETER Pwdattributetype Vendor-specific password attribute type in a RADIUS response. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER Callingstationid Send Calling-Station-ID of the client to the RADIUS server. IP Address of the client is sent as its Calling-Station-ID. Possible values = ENABLED, DISABLED .PARAMETER Authservretry Number of retry by the Citrix ADC before getting response from the RADIUS server. .PARAMETER Authentication Configure the RADIUS server state to accept or refuse authentication messages. Possible values = ON, OFF .PARAMETER Tunnelendpointclientip Send Tunnel Endpoint Client IP address to the RADIUS server. Possible values = ENABLED, DISABLED .PARAMETER PassThru Return details about the created authenticationradiusaction item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationradiusaction -name <string> An example how to update authenticationradiusaction configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationradiusaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationradiusaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Serverip, [ValidateScript({ $_.Length -gt 1 })] [string]$Servername, [int]$Serverport, [double]$Authtimeout, [ValidateScript({ $_.Length -gt 1 })] [string]$Radkey, [ValidateSet('ENABLED', 'DISABLED')] [string]$Radnasip, [string]$Radnasid, [double]$Radvendorid, [double]$Radattributetype, [string]$Radgroupsprefix, [string]$Radgroupseparator, [ValidateSet('pap', 'chap', 'mschapv1', 'mschapv2')] [string]$Passencoding, [double]$Ipvendorid, [double]$Ipattributetype, [ValidateSet('ON', 'OFF')] [string]$Accounting, [double]$Pwdvendorid, [double]$Pwdattributetype, [string]$Defaultauthenticationgroup, [ValidateSet('ENABLED', 'DISABLED')] [string]$Callingstationid, [ValidateRange(1, 10)] [double]$Authservretry, [ValidateSet('ON', 'OFF')] [string]$Authentication, [ValidateSet('ENABLED', 'DISABLED')] [string]$Tunnelendpointclientip, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationradiusaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('serverip') ) { $payload.Add('serverip', $serverip) } if ( $PSBoundParameters.ContainsKey('servername') ) { $payload.Add('servername', $servername) } if ( $PSBoundParameters.ContainsKey('serverport') ) { $payload.Add('serverport', $serverport) } if ( $PSBoundParameters.ContainsKey('authtimeout') ) { $payload.Add('authtimeout', $authtimeout) } if ( $PSBoundParameters.ContainsKey('radkey') ) { $payload.Add('radkey', $radkey) } if ( $PSBoundParameters.ContainsKey('radnasip') ) { $payload.Add('radnasip', $radnasip) } if ( $PSBoundParameters.ContainsKey('radnasid') ) { $payload.Add('radnasid', $radnasid) } if ( $PSBoundParameters.ContainsKey('radvendorid') ) { $payload.Add('radvendorid', $radvendorid) } if ( $PSBoundParameters.ContainsKey('radattributetype') ) { $payload.Add('radattributetype', $radattributetype) } if ( $PSBoundParameters.ContainsKey('radgroupsprefix') ) { $payload.Add('radgroupsprefix', $radgroupsprefix) } if ( $PSBoundParameters.ContainsKey('radgroupseparator') ) { $payload.Add('radgroupseparator', $radgroupseparator) } if ( $PSBoundParameters.ContainsKey('passencoding') ) { $payload.Add('passencoding', $passencoding) } if ( $PSBoundParameters.ContainsKey('ipvendorid') ) { $payload.Add('ipvendorid', $ipvendorid) } if ( $PSBoundParameters.ContainsKey('ipattributetype') ) { $payload.Add('ipattributetype', $ipattributetype) } if ( $PSBoundParameters.ContainsKey('accounting') ) { $payload.Add('accounting', $accounting) } if ( $PSBoundParameters.ContainsKey('pwdvendorid') ) { $payload.Add('pwdvendorid', $pwdvendorid) } if ( $PSBoundParameters.ContainsKey('pwdattributetype') ) { $payload.Add('pwdattributetype', $pwdattributetype) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('callingstationid') ) { $payload.Add('callingstationid', $callingstationid) } if ( $PSBoundParameters.ContainsKey('authservretry') ) { $payload.Add('authservretry', $authservretry) } if ( $PSBoundParameters.ContainsKey('authentication') ) { $payload.Add('authentication', $authentication) } if ( $PSBoundParameters.ContainsKey('tunnelendpointclientip') ) { $payload.Add('tunnelendpointclientip', $tunnelendpointclientip) } if ( $PSCmdlet.ShouldProcess("authenticationradiusaction", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationradiusaction -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationradiusaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationradiusaction: Finished" } } function Invoke-ADCAddAuthenticationradiusaction { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for RADIUS action resource. .PARAMETER Name Name for the RADIUS action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the RADIUS action is added. .PARAMETER Serverip IP address assigned to the RADIUS server. .PARAMETER Servername RADIUS server name as a FQDN. Mutually exclusive with RADIUS IP address. .PARAMETER Serverport Port number on which the RADIUS server listens for connections. .PARAMETER Authtimeout Number of seconds the Citrix ADC waits for a response from the RADIUS server. .PARAMETER Radkey Key shared between the RADIUS server and the Citrix ADC. Required to allow the Citrix ADC to communicate with the RADIUS server. .PARAMETER Radnasip If enabled, the Citrix ADC IP address (NSIP) is sent to the RADIUS server as the Network Access Server IP (NASIP) address. The RADIUS protocol defines the meaning and use of the NASIP address. Possible values = ENABLED, DISABLED .PARAMETER Radnasid If configured, this string is sent to the RADIUS server as the Network Access Server ID (NASID). .PARAMETER Radvendorid RADIUS vendor ID attribute, used for RADIUS group extraction. .PARAMETER Radattributetype RADIUS attribute type, used for RADIUS group extraction. .PARAMETER Radgroupsprefix RADIUS groups prefix string. This groups prefix precedes the group names within a RADIUS attribute for RADIUS group extraction. .PARAMETER Radgroupseparator RADIUS group separator string The group separator delimits group names within a RADIUS attribute for RADIUS group extraction. .PARAMETER Passencoding Encoding type for passwords in RADIUS packets that the Citrix ADC sends to the RADIUS server. Possible values = pap, chap, mschapv1, mschapv2 .PARAMETER Ipvendorid Vendor ID of the intranet IP attribute in the RADIUS response. NOTE: A value of 0 indicates that the attribute is not vendor encoded. .PARAMETER Ipattributetype Remote IP address attribute type in a RADIUS response. .PARAMETER Accounting Whether the RADIUS server is currently accepting accounting messages. Possible values = ON, OFF .PARAMETER Pwdvendorid Vendor ID of the attribute, in the RADIUS response, used to extract the user password. .PARAMETER Pwdattributetype Vendor-specific password attribute type in a RADIUS response. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER Callingstationid Send Calling-Station-ID of the client to the RADIUS server. IP Address of the client is sent as its Calling-Station-ID. Possible values = ENABLED, DISABLED .PARAMETER Authservretry Number of retry by the Citrix ADC before getting response from the RADIUS server. .PARAMETER Authentication Configure the RADIUS server state to accept or refuse authentication messages. Possible values = ON, OFF .PARAMETER Tunnelendpointclientip Send Tunnel Endpoint Client IP address to the RADIUS server. Possible values = ENABLED, DISABLED .PARAMETER PassThru Return details about the created authenticationradiusaction item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationradiusaction -name <string> -radkey <string> An example how to add authenticationradiusaction configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationradiusaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationradiusaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Serverip, [ValidateScript({ $_.Length -gt 1 })] [string]$Servername, [int]$Serverport, [double]$Authtimeout = '3', [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Radkey, [ValidateSet('ENABLED', 'DISABLED')] [string]$Radnasip, [string]$Radnasid, [double]$Radvendorid, [double]$Radattributetype, [string]$Radgroupsprefix, [string]$Radgroupseparator, [ValidateSet('pap', 'chap', 'mschapv1', 'mschapv2')] [string]$Passencoding = 'pap', [double]$Ipvendorid, [double]$Ipattributetype, [ValidateSet('ON', 'OFF')] [string]$Accounting, [double]$Pwdvendorid, [double]$Pwdattributetype, [string]$Defaultauthenticationgroup, [ValidateSet('ENABLED', 'DISABLED')] [string]$Callingstationid = 'DISABLED', [ValidateRange(1, 10)] [double]$Authservretry = '3', [ValidateSet('ON', 'OFF')] [string]$Authentication = 'ON', [ValidateSet('ENABLED', 'DISABLED')] [string]$Tunnelendpointclientip = 'DISABLED', [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationradiusaction: Starting" } process { try { $payload = @{ name = $name radkey = $radkey } if ( $PSBoundParameters.ContainsKey('serverip') ) { $payload.Add('serverip', $serverip) } if ( $PSBoundParameters.ContainsKey('servername') ) { $payload.Add('servername', $servername) } if ( $PSBoundParameters.ContainsKey('serverport') ) { $payload.Add('serverport', $serverport) } if ( $PSBoundParameters.ContainsKey('authtimeout') ) { $payload.Add('authtimeout', $authtimeout) } if ( $PSBoundParameters.ContainsKey('radnasip') ) { $payload.Add('radnasip', $radnasip) } if ( $PSBoundParameters.ContainsKey('radnasid') ) { $payload.Add('radnasid', $radnasid) } if ( $PSBoundParameters.ContainsKey('radvendorid') ) { $payload.Add('radvendorid', $radvendorid) } if ( $PSBoundParameters.ContainsKey('radattributetype') ) { $payload.Add('radattributetype', $radattributetype) } if ( $PSBoundParameters.ContainsKey('radgroupsprefix') ) { $payload.Add('radgroupsprefix', $radgroupsprefix) } if ( $PSBoundParameters.ContainsKey('radgroupseparator') ) { $payload.Add('radgroupseparator', $radgroupseparator) } if ( $PSBoundParameters.ContainsKey('passencoding') ) { $payload.Add('passencoding', $passencoding) } if ( $PSBoundParameters.ContainsKey('ipvendorid') ) { $payload.Add('ipvendorid', $ipvendorid) } if ( $PSBoundParameters.ContainsKey('ipattributetype') ) { $payload.Add('ipattributetype', $ipattributetype) } if ( $PSBoundParameters.ContainsKey('accounting') ) { $payload.Add('accounting', $accounting) } if ( $PSBoundParameters.ContainsKey('pwdvendorid') ) { $payload.Add('pwdvendorid', $pwdvendorid) } if ( $PSBoundParameters.ContainsKey('pwdattributetype') ) { $payload.Add('pwdattributetype', $pwdattributetype) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('callingstationid') ) { $payload.Add('callingstationid', $callingstationid) } if ( $PSBoundParameters.ContainsKey('authservretry') ) { $payload.Add('authservretry', $authservretry) } if ( $PSBoundParameters.ContainsKey('authentication') ) { $payload.Add('authentication', $authentication) } if ( $PSBoundParameters.ContainsKey('tunnelendpointclientip') ) { $payload.Add('tunnelendpointclientip', $tunnelendpointclientip) } if ( $PSCmdlet.ShouldProcess("authenticationradiusaction", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationradiusaction -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationradiusaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationradiusaction: Finished" } } function Invoke-ADCGetAuthenticationradiusaction { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for RADIUS action resource. .PARAMETER Name Name for the RADIUS action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the RADIUS action is added. .PARAMETER GetAll Retrieve all authenticationradiusaction object(s). .PARAMETER Count If specified, the count of the authenticationradiusaction object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiusaction Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiusaction -GetAll Get all authenticationradiusaction data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiusaction -Count Get the number of authenticationradiusaction objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiusaction -name <string> Get authenticationradiusaction object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiusaction -Filter @{ 'name'='<value>' } Get authenticationradiusaction data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationradiusaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationradiusaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationradiusaction: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationradiusaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiusaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationradiusaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiusaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationradiusaction objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiusaction -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationradiusaction configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiusaction -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationradiusaction configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiusaction -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationradiusaction: Ended" } } function Invoke-ADCUpdateAuthenticationradiuspolicy { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for RADIUS policy resource. .PARAMETER Name Name for the RADIUS authentication policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after RADIUS policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to determine whether to attempt to authenticate the user with the RADIUS server. .PARAMETER Reqaction Name of the RADIUS action to perform if the policy matches. .PARAMETER PassThru Return details about the created authenticationradiuspolicy item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationradiuspolicy -name <string> An example how to update authenticationradiuspolicy configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationradiuspolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationradiuspolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Rule, [ValidateScript({ $_.Length -gt 1 })] [string]$Reqaction, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationradiuspolicy: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('rule') ) { $payload.Add('rule', $rule) } if ( $PSBoundParameters.ContainsKey('reqaction') ) { $payload.Add('reqaction', $reqaction) } if ( $PSCmdlet.ShouldProcess("authenticationradiuspolicy", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationradiuspolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationradiuspolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationradiuspolicy: Finished" } } function Invoke-ADCUnsetAuthenticationradiuspolicy { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for RADIUS policy resource. .PARAMETER Name Name for the RADIUS authentication policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after RADIUS policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to determine whether to attempt to authenticate the user with the RADIUS server. .PARAMETER Reqaction Name of the RADIUS action to perform if the policy matches. .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationradiuspolicy -name <string> An example how to unset authenticationradiuspolicy configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationradiuspolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationradiuspolicy Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Boolean]$rule, [Boolean]$reqaction ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationradiuspolicy: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('rule') ) { $payload.Add('rule', $rule) } if ( $PSBoundParameters.ContainsKey('reqaction') ) { $payload.Add('reqaction', $reqaction) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationradiuspolicy -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationradiuspolicy: Finished" } } function Invoke-ADCAddAuthenticationradiuspolicy { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for RADIUS policy resource. .PARAMETER Name Name for the RADIUS authentication policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after RADIUS policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to determine whether to attempt to authenticate the user with the RADIUS server. .PARAMETER Reqaction Name of the RADIUS action to perform if the policy matches. .PARAMETER PassThru Return details about the created authenticationradiuspolicy item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationradiuspolicy -name <string> -rule <string> An example how to add authenticationradiuspolicy configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationradiuspolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationradiuspolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(Mandatory)] [string]$Rule, [ValidateScript({ $_.Length -gt 1 })] [string]$Reqaction, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationradiuspolicy: Starting" } process { try { $payload = @{ name = $name rule = $rule } if ( $PSBoundParameters.ContainsKey('reqaction') ) { $payload.Add('reqaction', $reqaction) } if ( $PSCmdlet.ShouldProcess("authenticationradiuspolicy", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationradiuspolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationradiuspolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationradiuspolicy: Finished" } } function Invoke-ADCDeleteAuthenticationradiuspolicy { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for RADIUS policy resource. .PARAMETER Name Name for the RADIUS authentication policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after RADIUS policy is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationradiuspolicy -Name <string> An example how to delete authenticationradiuspolicy configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationradiuspolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationradiuspolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationradiuspolicy: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationradiuspolicy -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationradiuspolicy: Finished" } } function Invoke-ADCGetAuthenticationradiuspolicy { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for RADIUS policy resource. .PARAMETER Name Name for the RADIUS authentication policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after RADIUS policy is created. .PARAMETER GetAll Retrieve all authenticationradiuspolicy object(s). .PARAMETER Count If specified, the count of the authenticationradiuspolicy object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicy Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicy -GetAll Get all authenticationradiuspolicy data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicy -Count Get the number of authenticationradiuspolicy objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicy -name <string> Get authenticationradiuspolicy object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicy -Filter @{ 'name'='<value>' } Get authenticationradiuspolicy data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationradiuspolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationradiuspolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationradiuspolicy: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationradiuspolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationradiuspolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationradiuspolicy objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationradiuspolicy configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationradiuspolicy configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationradiuspolicy: Ended" } } function Invoke-ADCGetAuthenticationradiuspolicyauthenticationvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationvserver that can be bound to authenticationradiuspolicy. .PARAMETER Name Name of the RADIUS authentication policy. .PARAMETER GetAll Retrieve all authenticationradiuspolicy_authenticationvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationradiuspolicy_authenticationvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicyauthenticationvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicyauthenticationvserverbinding -GetAll Get all authenticationradiuspolicy_authenticationvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicyauthenticationvserverbinding -Count Get the number of authenticationradiuspolicy_authenticationvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicyauthenticationvserverbinding -name <string> Get authenticationradiuspolicy_authenticationvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicyauthenticationvserverbinding -Filter @{ 'name'='<value>' } Get authenticationradiuspolicy_authenticationvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationradiuspolicyauthenticationvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationradiuspolicy_authenticationvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationradiuspolicyauthenticationvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationradiuspolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationradiuspolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationradiuspolicy_authenticationvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationradiuspolicy_authenticationvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationradiuspolicy_authenticationvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationradiuspolicyauthenticationvserverbinding: Ended" } } function Invoke-ADCGetAuthenticationradiuspolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object which returns the resources bound to authenticationradiuspolicy. .PARAMETER Name Name of the RADIUS authentication policy. .PARAMETER GetAll Retrieve all authenticationradiuspolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationradiuspolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicybinding -GetAll Get all authenticationradiuspolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicybinding -name <string> Get authenticationradiuspolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicybinding -Filter @{ 'name'='<value>' } Get authenticationradiuspolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationradiuspolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationradiuspolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationradiuspolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationradiuspolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationradiuspolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationradiuspolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationradiuspolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationradiuspolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationradiuspolicybinding: Ended" } } function Invoke-ADCGetAuthenticationradiuspolicysystemglobalbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the systemglobal that can be bound to authenticationradiuspolicy. .PARAMETER Name Name of the RADIUS authentication policy. .PARAMETER GetAll Retrieve all authenticationradiuspolicy_systemglobal_binding object(s). .PARAMETER Count If specified, the count of the authenticationradiuspolicy_systemglobal_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicysystemglobalbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicysystemglobalbinding -GetAll Get all authenticationradiuspolicy_systemglobal_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicysystemglobalbinding -Count Get the number of authenticationradiuspolicy_systemglobal_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicysystemglobalbinding -name <string> Get authenticationradiuspolicy_systemglobal_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicysystemglobalbinding -Filter @{ 'name'='<value>' } Get authenticationradiuspolicy_systemglobal_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationradiuspolicysystemglobalbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationradiuspolicy_systemglobal_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationradiuspolicysystemglobalbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationradiuspolicy_systemglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_systemglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationradiuspolicy_systemglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_systemglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationradiuspolicy_systemglobal_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_systemglobal_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationradiuspolicy_systemglobal_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_systemglobal_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationradiuspolicy_systemglobal_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_systemglobal_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationradiuspolicysystemglobalbinding: Ended" } } function Invoke-ADCGetAuthenticationradiuspolicyvpnglobalbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the vpnglobal that can be bound to authenticationradiuspolicy. .PARAMETER Name Name of the RADIUS authentication policy. .PARAMETER GetAll Retrieve all authenticationradiuspolicy_vpnglobal_binding object(s). .PARAMETER Count If specified, the count of the authenticationradiuspolicy_vpnglobal_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicyvpnglobalbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicyvpnglobalbinding -GetAll Get all authenticationradiuspolicy_vpnglobal_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicyvpnglobalbinding -Count Get the number of authenticationradiuspolicy_vpnglobal_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicyvpnglobalbinding -name <string> Get authenticationradiuspolicy_vpnglobal_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicyvpnglobalbinding -Filter @{ 'name'='<value>' } Get authenticationradiuspolicy_vpnglobal_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationradiuspolicyvpnglobalbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationradiuspolicy_vpnglobal_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationradiuspolicyvpnglobalbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationradiuspolicy_vpnglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_vpnglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationradiuspolicy_vpnglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_vpnglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationradiuspolicy_vpnglobal_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_vpnglobal_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationradiuspolicy_vpnglobal_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_vpnglobal_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationradiuspolicy_vpnglobal_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_vpnglobal_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationradiuspolicyvpnglobalbinding: Ended" } } function Invoke-ADCGetAuthenticationradiuspolicyvpnvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the vpnvserver that can be bound to authenticationradiuspolicy. .PARAMETER Name Name of the RADIUS authentication policy. .PARAMETER GetAll Retrieve all authenticationradiuspolicy_vpnvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationradiuspolicy_vpnvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicyvpnvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicyvpnvserverbinding -GetAll Get all authenticationradiuspolicy_vpnvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicyvpnvserverbinding -Count Get the number of authenticationradiuspolicy_vpnvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicyvpnvserverbinding -name <string> Get authenticationradiuspolicy_vpnvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationradiuspolicyvpnvserverbinding -Filter @{ 'name'='<value>' } Get authenticationradiuspolicy_vpnvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationradiuspolicyvpnvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationradiuspolicy_vpnvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationradiuspolicyvpnvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationradiuspolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationradiuspolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationradiuspolicy_vpnvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_vpnvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationradiuspolicy_vpnvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_vpnvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationradiuspolicy_vpnvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationradiuspolicy_vpnvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationradiuspolicyvpnvserverbinding: Ended" } } function Invoke-ADCUnsetAuthenticationsamlaction { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for AAA Saml action resource. .PARAMETER Name Name for the SAML server profile (action). Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after SAML profile is created. .PARAMETER Metadataurl This URL is used for obtaining saml metadata. Note that it fills samlIdPCertName and samlredirectUrl fields so those fields should not be updated when metadataUrl present. .PARAMETER Samlsigningcertname Name of the SSL certificate to sign requests from ServiceProvider (SP) to Identity Provider (IdP). .PARAMETER Samlredirecturl URL to which users are redirected for authentication. Note that if metadateURL is present then this filed should be empty. .PARAMETER Samlacsindex Index/ID of the metadata entry corresponding to this configuration. .PARAMETER Samluserfield SAML user ID, as given in the SAML assertion. .PARAMETER Samlrejectunsignedassertion Reject unsigned SAML assertions. ON option results in rejection of Assertion that is received without signature. STRICT option ensures that both Response and Assertion are signed. OFF allows unsigned Assertions. Possible values = ON, OFF, STRICT .PARAMETER Samlissuername The name to be used in requests sent from Citrix ADC to IdP to uniquely identify Citrix ADC. .PARAMETER Samltwofactor Option to enable second factor after SAML. Possible values = ON, OFF .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER Attribute1 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute1. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute2 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute2. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute3 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute3. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute4 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute4. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute5 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute5. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute6 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute6. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute7 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute7. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute8 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute8. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute9 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute9. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute10 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute10. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute11 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute11. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute12 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute12. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute13 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute13. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute14 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute14. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute15 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute15. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute16 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute16. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attributes List of attribute names separated by ',' which needs to be extracted. Note that preceeding and trailing spaces will be removed. Attribute name can be 127 bytes and total length of this string should not cross 2047 bytes. These attributes have multi-value support separated by ',' and stored as key-value pair in AAA session. .PARAMETER Relaystaterule Boolean expression that will be evaluated to validate the SAML Response. .PARAMETER Signaturealg Algorithm to be used to sign/verify SAML transactions. Possible values = RSA-SHA1, RSA-SHA256 .PARAMETER Digestmethod Algorithm to be used to compute/verify digest for SAML transactions. Possible values = SHA1, SHA256 .PARAMETER Requestedauthncontext This element specifies the authentication context requirements of authentication statements returned in the response. Possible values = exact, minimum, maximum, better .PARAMETER Authnctxclassref This element specifies the authentication class types that are requested from IdP (IdentityProvider). InternetProtocol: This is applicable when a principal is authenticated through the use of a provided IP address. InternetProtocolPassword: This is applicable when a principal is authenticated through the use of a provided IP address, in addition to a username/password. Kerberos: This is applicable when the principal has authenticated using a password to a local authentication authority, in order to acquire a Kerberos ticket. MobileOneFactorUnregistered: This indicates authentication of the mobile device without requiring explicit end-user interaction. MobileTwoFactorUnregistered: This indicates two-factor based authentication during mobile customer registration process, such as secure device and user PIN. MobileOneFactorContract: Reflects mobile contract customer registration procedures and a single factor authentication. MobileTwoFactorContract: Reflects mobile contract customer registration procedures and a two-factor based authentication. Password: This class is applicable when a principal authenticates using password over unprotected http session. PasswordProtectedTransport: This class is applicable when a principal authenticates to an authentication authority through the presentation of a password over a protected session. PreviousSession: This class is applicable when a principal had authenticated to an authentication authority at some point in the past using any authentication context. X509: This indicates that the principal authenticated by means of a digital signature where the key was validated as part of an X.509 Public Key Infrastructure. PGP: This indicates that the principal authenticated by means of a digital signature where the key was validated as part of a PGP Public Key Infrastructure. SPKI: This indicates that the principal authenticated by means of a digital signature where the key was validated via an SPKI Infrastructure. XMLDSig: This indicates that the principal authenticated by means of a digital signature according to the processing rules specified in the XML Digital Signature specification. Smartcard: This indicates that the principal has authenticated using smartcard. SmartcardPKI: This class is applicable when a principal authenticates to an authentication authority through a two-factor authentication mechanism using a smartcard with enclosed private key and a PIN. SoftwarePKI: This class is applicable when a principal uses an X.509 certificate stored in software to authenticate to the authentication authority. Telephony: This class is used to indicate that the principal authenticated via the provision of a fixed-line telephone number, transported via a telephony protocol such as ADSL. NomadTelephony: Indicates that the principal is "roaming" and authenticates via the means of the line number, a user suffix, and a password element. PersonalTelephony: This class is used to indicate that the principal authenticated via the provision of a fixed-line telephone. AuthenticatedTelephony: Indicates that the principal authenticated via the means of the line number, a user suffix, and a password element. SecureRemotePassword: This class is applicable when the authentication was performed by means of Secure Remote Password. TLSClient: This class indicates that the principal authenticated by means of a client certificate, secured with the SSL/TLS transport. TimeSyncToken: This is applicable when a principal authenticates through a time synchronization token. Unspecified: This indicates that the authentication was performed by unspecified means. Windows: This indicates that Windows integrated authentication is utilized for authentication. Possible values = InternetProtocol, InternetProtocolPassword, Kerberos, MobileOneFactorUnregistered, MobileTwoFactorUnregistered, MobileOneFactorContract, MobileTwoFactorContract, Password, PasswordProtectedTransport, PreviousSession, X509, PGP, SPKI, XMLDSig, Smartcard, SmartcardPKI, SoftwarePKI, Telephony, NomadTelephony, PersonalTelephony, AuthenticatedTelephony, SecureRemotePassword, TLSClient, TimeSyncToken, Unspecified, Windows .PARAMETER Customauthnctxclassref This element specifies the custom authentication class reference to be sent as a part of the Authentication Request that is sent by the SP to SAML IDP. The input string must be the body of the authentication class being requested. Input format: Alphanumeric string or URL specifying the body of the Request.If more than one string has to be provided, then the same can be done by specifying the classes as a string of comma separated values. Example input: set authentication samlaction samlact1 -customAuthnCtxClassRef http://www.class1.com/LoA1,http://www.class2.com/LoA2 . .PARAMETER Samlbinding This element specifies the transport mechanism of saml messages. Possible values = REDIRECT, POST, ARTIFACT .PARAMETER Attributeconsumingserviceindex Index/ID of the attribute specification at Identity Provider (IdP). IdP will locate attributes requested by SP using this index and send those attributes in Assertion. .PARAMETER Sendthumbprint Option to send thumbprint instead of x509 certificate in SAML request. Possible values = ON, OFF .PARAMETER Enforceusername Option to choose whether the username that is extracted from SAML assertion can be edited in login page while doing second factor. Possible values = ON, OFF .PARAMETER Logouturl SingleLogout URL on IdP to which logoutRequest will be sent on Citrix ADC session cleanup. .PARAMETER Artifactresolutionserviceurl URL of the Artifact Resolution Service on IdP to which Citrix ADC will post artifact to get actual SAML token. .PARAMETER Skewtime This option specifies the allowed clock skew in number of minutes that Citrix ADC ServiceProvider allows on an incoming assertion. For example, if skewTime is 10, then assertion would be valid from (current time - 10) min to (current time + 10) min, ie 20min in all. .PARAMETER Logoutbinding This element specifies the transport mechanism of saml logout messages. Possible values = REDIRECT, POST .PARAMETER Forceauthn Option that forces authentication at the Identity Provider (IdP) that receives Citrix ADC's request. Possible values = ON, OFF .PARAMETER Groupnamefield Name of the tag in assertion that contains user groups. .PARAMETER Audience Audience for which assertion sent by IdP is applicable. This is typically entity name or url that represents ServiceProvider. .PARAMETER Metadatarefreshinterval Interval in minutes for fetching metadata from specified metadata URL. .PARAMETER Storesamlresponse Option to store entire SAML Response through the life of user session. Possible values = ON, OFF .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationsamlaction -name <string> An example how to unset authenticationsamlaction configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationsamlaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlaction Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Boolean]$metadataurl, [Boolean]$samlsigningcertname, [Boolean]$samlredirecturl, [Boolean]$samlacsindex, [Boolean]$samluserfield, [Boolean]$samlrejectunsignedassertion, [Boolean]$samlissuername, [Boolean]$samltwofactor, [Boolean]$defaultauthenticationgroup, [Boolean]$attribute1, [Boolean]$attribute2, [Boolean]$attribute3, [Boolean]$attribute4, [Boolean]$attribute5, [Boolean]$attribute6, [Boolean]$attribute7, [Boolean]$attribute8, [Boolean]$attribute9, [Boolean]$attribute10, [Boolean]$attribute11, [Boolean]$attribute12, [Boolean]$attribute13, [Boolean]$attribute14, [Boolean]$attribute15, [Boolean]$attribute16, [Boolean]$attributes, [Boolean]$relaystaterule, [Boolean]$signaturealg, [Boolean]$digestmethod, [Boolean]$requestedauthncontext, [Boolean]$authnctxclassref, [Boolean]$customauthnctxclassref, [Boolean]$samlbinding, [Boolean]$attributeconsumingserviceindex, [Boolean]$sendthumbprint, [Boolean]$enforceusername, [Boolean]$logouturl, [Boolean]$artifactresolutionserviceurl, [Boolean]$skewtime, [Boolean]$logoutbinding, [Boolean]$forceauthn, [Boolean]$groupnamefield, [Boolean]$audience, [Boolean]$metadatarefreshinterval, [Boolean]$storesamlresponse ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationsamlaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('metadataurl') ) { $payload.Add('metadataurl', $metadataurl) } if ( $PSBoundParameters.ContainsKey('samlsigningcertname') ) { $payload.Add('samlsigningcertname', $samlsigningcertname) } if ( $PSBoundParameters.ContainsKey('samlredirecturl') ) { $payload.Add('samlredirecturl', $samlredirecturl) } if ( $PSBoundParameters.ContainsKey('samlacsindex') ) { $payload.Add('samlacsindex', $samlacsindex) } if ( $PSBoundParameters.ContainsKey('samluserfield') ) { $payload.Add('samluserfield', $samluserfield) } if ( $PSBoundParameters.ContainsKey('samlrejectunsignedassertion') ) { $payload.Add('samlrejectunsignedassertion', $samlrejectunsignedassertion) } if ( $PSBoundParameters.ContainsKey('samlissuername') ) { $payload.Add('samlissuername', $samlissuername) } if ( $PSBoundParameters.ContainsKey('samltwofactor') ) { $payload.Add('samltwofactor', $samltwofactor) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('attribute1') ) { $payload.Add('attribute1', $attribute1) } if ( $PSBoundParameters.ContainsKey('attribute2') ) { $payload.Add('attribute2', $attribute2) } if ( $PSBoundParameters.ContainsKey('attribute3') ) { $payload.Add('attribute3', $attribute3) } if ( $PSBoundParameters.ContainsKey('attribute4') ) { $payload.Add('attribute4', $attribute4) } if ( $PSBoundParameters.ContainsKey('attribute5') ) { $payload.Add('attribute5', $attribute5) } if ( $PSBoundParameters.ContainsKey('attribute6') ) { $payload.Add('attribute6', $attribute6) } if ( $PSBoundParameters.ContainsKey('attribute7') ) { $payload.Add('attribute7', $attribute7) } if ( $PSBoundParameters.ContainsKey('attribute8') ) { $payload.Add('attribute8', $attribute8) } if ( $PSBoundParameters.ContainsKey('attribute9') ) { $payload.Add('attribute9', $attribute9) } if ( $PSBoundParameters.ContainsKey('attribute10') ) { $payload.Add('attribute10', $attribute10) } if ( $PSBoundParameters.ContainsKey('attribute11') ) { $payload.Add('attribute11', $attribute11) } if ( $PSBoundParameters.ContainsKey('attribute12') ) { $payload.Add('attribute12', $attribute12) } if ( $PSBoundParameters.ContainsKey('attribute13') ) { $payload.Add('attribute13', $attribute13) } if ( $PSBoundParameters.ContainsKey('attribute14') ) { $payload.Add('attribute14', $attribute14) } if ( $PSBoundParameters.ContainsKey('attribute15') ) { $payload.Add('attribute15', $attribute15) } if ( $PSBoundParameters.ContainsKey('attribute16') ) { $payload.Add('attribute16', $attribute16) } if ( $PSBoundParameters.ContainsKey('attributes') ) { $payload.Add('attributes', $attributes) } if ( $PSBoundParameters.ContainsKey('relaystaterule') ) { $payload.Add('relaystaterule', $relaystaterule) } if ( $PSBoundParameters.ContainsKey('signaturealg') ) { $payload.Add('signaturealg', $signaturealg) } if ( $PSBoundParameters.ContainsKey('digestmethod') ) { $payload.Add('digestmethod', $digestmethod) } if ( $PSBoundParameters.ContainsKey('requestedauthncontext') ) { $payload.Add('requestedauthncontext', $requestedauthncontext) } if ( $PSBoundParameters.ContainsKey('authnctxclassref') ) { $payload.Add('authnctxclassref', $authnctxclassref) } if ( $PSBoundParameters.ContainsKey('customauthnctxclassref') ) { $payload.Add('customauthnctxclassref', $customauthnctxclassref) } if ( $PSBoundParameters.ContainsKey('samlbinding') ) { $payload.Add('samlbinding', $samlbinding) } if ( $PSBoundParameters.ContainsKey('attributeconsumingserviceindex') ) { $payload.Add('attributeconsumingserviceindex', $attributeconsumingserviceindex) } if ( $PSBoundParameters.ContainsKey('sendthumbprint') ) { $payload.Add('sendthumbprint', $sendthumbprint) } if ( $PSBoundParameters.ContainsKey('enforceusername') ) { $payload.Add('enforceusername', $enforceusername) } if ( $PSBoundParameters.ContainsKey('logouturl') ) { $payload.Add('logouturl', $logouturl) } if ( $PSBoundParameters.ContainsKey('artifactresolutionserviceurl') ) { $payload.Add('artifactresolutionserviceurl', $artifactresolutionserviceurl) } if ( $PSBoundParameters.ContainsKey('skewtime') ) { $payload.Add('skewtime', $skewtime) } if ( $PSBoundParameters.ContainsKey('logoutbinding') ) { $payload.Add('logoutbinding', $logoutbinding) } if ( $PSBoundParameters.ContainsKey('forceauthn') ) { $payload.Add('forceauthn', $forceauthn) } if ( $PSBoundParameters.ContainsKey('groupnamefield') ) { $payload.Add('groupnamefield', $groupnamefield) } if ( $PSBoundParameters.ContainsKey('audience') ) { $payload.Add('audience', $audience) } if ( $PSBoundParameters.ContainsKey('metadatarefreshinterval') ) { $payload.Add('metadatarefreshinterval', $metadatarefreshinterval) } if ( $PSBoundParameters.ContainsKey('storesamlresponse') ) { $payload.Add('storesamlresponse', $storesamlresponse) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationsamlaction -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationsamlaction: Finished" } } function Invoke-ADCUpdateAuthenticationsamlaction { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for AAA Saml action resource. .PARAMETER Name Name for the SAML server profile (action). Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after SAML profile is created. .PARAMETER Metadataurl This URL is used for obtaining saml metadata. Note that it fills samlIdPCertName and samlredirectUrl fields so those fields should not be updated when metadataUrl present. .PARAMETER Samlidpcertname Name of the SSL certificate used to verify responses from SAML Identity Provider (IdP). Note that if metadateURL is present then this filed should be empty. .PARAMETER Samlsigningcertname Name of the SSL certificate to sign requests from ServiceProvider (SP) to Identity Provider (IdP). .PARAMETER Samlredirecturl URL to which users are redirected for authentication. Note that if metadateURL is present then this filed should be empty. .PARAMETER Samlacsindex Index/ID of the metadata entry corresponding to this configuration. .PARAMETER Samluserfield SAML user ID, as given in the SAML assertion. .PARAMETER Samlrejectunsignedassertion Reject unsigned SAML assertions. ON option results in rejection of Assertion that is received without signature. STRICT option ensures that both Response and Assertion are signed. OFF allows unsigned Assertions. Possible values = ON, OFF, STRICT .PARAMETER Samlissuername The name to be used in requests sent from Citrix ADC to IdP to uniquely identify Citrix ADC. .PARAMETER Samltwofactor Option to enable second factor after SAML. Possible values = ON, OFF .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER Attribute1 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute1. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute2 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute2. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute3 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute3. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute4 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute4. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute5 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute5. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute6 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute6. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute7 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute7. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute8 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute8. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute9 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute9. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute10 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute10. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute11 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute11. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute12 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute12. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute13 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute13. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute14 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute14. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute15 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute15. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute16 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute16. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attributes List of attribute names separated by ',' which needs to be extracted. Note that preceeding and trailing spaces will be removed. Attribute name can be 127 bytes and total length of this string should not cross 2047 bytes. These attributes have multi-value support separated by ',' and stored as key-value pair in AAA session. .PARAMETER Relaystaterule Boolean expression that will be evaluated to validate the SAML Response. .PARAMETER Signaturealg Algorithm to be used to sign/verify SAML transactions. Possible values = RSA-SHA1, RSA-SHA256 .PARAMETER Digestmethod Algorithm to be used to compute/verify digest for SAML transactions. Possible values = SHA1, SHA256 .PARAMETER Requestedauthncontext This element specifies the authentication context requirements of authentication statements returned in the response. Possible values = exact, minimum, maximum, better .PARAMETER Authnctxclassref This element specifies the authentication class types that are requested from IdP (IdentityProvider). InternetProtocol: This is applicable when a principal is authenticated through the use of a provided IP address. InternetProtocolPassword: This is applicable when a principal is authenticated through the use of a provided IP address, in addition to a username/password. Kerberos: This is applicable when the principal has authenticated using a password to a local authentication authority, in order to acquire a Kerberos ticket. MobileOneFactorUnregistered: This indicates authentication of the mobile device without requiring explicit end-user interaction. MobileTwoFactorUnregistered: This indicates two-factor based authentication during mobile customer registration process, such as secure device and user PIN. MobileOneFactorContract: Reflects mobile contract customer registration procedures and a single factor authentication. MobileTwoFactorContract: Reflects mobile contract customer registration procedures and a two-factor based authentication. Password: This class is applicable when a principal authenticates using password over unprotected http session. PasswordProtectedTransport: This class is applicable when a principal authenticates to an authentication authority through the presentation of a password over a protected session. PreviousSession: This class is applicable when a principal had authenticated to an authentication authority at some point in the past using any authentication context. X509: This indicates that the principal authenticated by means of a digital signature where the key was validated as part of an X.509 Public Key Infrastructure. PGP: This indicates that the principal authenticated by means of a digital signature where the key was validated as part of a PGP Public Key Infrastructure. SPKI: This indicates that the principal authenticated by means of a digital signature where the key was validated via an SPKI Infrastructure. XMLDSig: This indicates that the principal authenticated by means of a digital signature according to the processing rules specified in the XML Digital Signature specification. Smartcard: This indicates that the principal has authenticated using smartcard. SmartcardPKI: This class is applicable when a principal authenticates to an authentication authority through a two-factor authentication mechanism using a smartcard with enclosed private key and a PIN. SoftwarePKI: This class is applicable when a principal uses an X.509 certificate stored in software to authenticate to the authentication authority. Telephony: This class is used to indicate that the principal authenticated via the provision of a fixed-line telephone number, transported via a telephony protocol such as ADSL. NomadTelephony: Indicates that the principal is "roaming" and authenticates via the means of the line number, a user suffix, and a password element. PersonalTelephony: This class is used to indicate that the principal authenticated via the provision of a fixed-line telephone. AuthenticatedTelephony: Indicates that the principal authenticated via the means of the line number, a user suffix, and a password element. SecureRemotePassword: This class is applicable when the authentication was performed by means of Secure Remote Password. TLSClient: This class indicates that the principal authenticated by means of a client certificate, secured with the SSL/TLS transport. TimeSyncToken: This is applicable when a principal authenticates through a time synchronization token. Unspecified: This indicates that the authentication was performed by unspecified means. Windows: This indicates that Windows integrated authentication is utilized for authentication. Possible values = InternetProtocol, InternetProtocolPassword, Kerberos, MobileOneFactorUnregistered, MobileTwoFactorUnregistered, MobileOneFactorContract, MobileTwoFactorContract, Password, PasswordProtectedTransport, PreviousSession, X509, PGP, SPKI, XMLDSig, Smartcard, SmartcardPKI, SoftwarePKI, Telephony, NomadTelephony, PersonalTelephony, AuthenticatedTelephony, SecureRemotePassword, TLSClient, TimeSyncToken, Unspecified, Windows .PARAMETER Customauthnctxclassref This element specifies the custom authentication class reference to be sent as a part of the Authentication Request that is sent by the SP to SAML IDP. The input string must be the body of the authentication class being requested. Input format: Alphanumeric string or URL specifying the body of the Request.If more than one string has to be provided, then the same can be done by specifying the classes as a string of comma separated values. Example input: set authentication samlaction samlact1 -customAuthnCtxClassRef http://www.class1.com/LoA1,http://www.class2.com/LoA2 . .PARAMETER Samlbinding This element specifies the transport mechanism of saml messages. Possible values = REDIRECT, POST, ARTIFACT .PARAMETER Attributeconsumingserviceindex Index/ID of the attribute specification at Identity Provider (IdP). IdP will locate attributes requested by SP using this index and send those attributes in Assertion. .PARAMETER Sendthumbprint Option to send thumbprint instead of x509 certificate in SAML request. Possible values = ON, OFF .PARAMETER Enforceusername Option to choose whether the username that is extracted from SAML assertion can be edited in login page while doing second factor. Possible values = ON, OFF .PARAMETER Logouturl SingleLogout URL on IdP to which logoutRequest will be sent on Citrix ADC session cleanup. .PARAMETER Artifactresolutionserviceurl URL of the Artifact Resolution Service on IdP to which Citrix ADC will post artifact to get actual SAML token. .PARAMETER Skewtime This option specifies the allowed clock skew in number of minutes that Citrix ADC ServiceProvider allows on an incoming assertion. For example, if skewTime is 10, then assertion would be valid from (current time - 10) min to (current time + 10) min, ie 20min in all. .PARAMETER Logoutbinding This element specifies the transport mechanism of saml logout messages. Possible values = REDIRECT, POST .PARAMETER Forceauthn Option that forces authentication at the Identity Provider (IdP) that receives Citrix ADC's request. Possible values = ON, OFF .PARAMETER Groupnamefield Name of the tag in assertion that contains user groups. .PARAMETER Audience Audience for which assertion sent by IdP is applicable. This is typically entity name or url that represents ServiceProvider. .PARAMETER Metadatarefreshinterval Interval in minutes for fetching metadata from specified metadata URL. .PARAMETER Storesamlresponse Option to store entire SAML Response through the life of user session. Possible values = ON, OFF .PARAMETER PassThru Return details about the created authenticationsamlaction item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationsamlaction -name <string> An example how to update authenticationsamlaction configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationsamlaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Metadataurl, [ValidateScript({ $_.Length -gt 1 })] [string]$Samlidpcertname, [ValidateScript({ $_.Length -gt 1 })] [string]$Samlsigningcertname, [ValidateScript({ $_.Length -gt 1 })] [string]$Samlredirecturl, [ValidateRange(0, 255)] [double]$Samlacsindex, [ValidateScript({ $_.Length -gt 1 })] [string]$Samluserfield, [ValidateSet('ON', 'OFF', 'STRICT')] [string]$Samlrejectunsignedassertion, [ValidateScript({ $_.Length -gt 1 })] [string]$Samlissuername, [ValidateSet('ON', 'OFF')] [string]$Samltwofactor, [string]$Defaultauthenticationgroup, [string]$Attribute1, [string]$Attribute2, [string]$Attribute3, [string]$Attribute4, [string]$Attribute5, [string]$Attribute6, [string]$Attribute7, [string]$Attribute8, [string]$Attribute9, [string]$Attribute10, [string]$Attribute11, [string]$Attribute12, [string]$Attribute13, [string]$Attribute14, [string]$Attribute15, [string]$Attribute16, [string]$Attributes, [string]$Relaystaterule, [ValidateSet('RSA-SHA1', 'RSA-SHA256')] [string]$Signaturealg, [ValidateSet('SHA1', 'SHA256')] [string]$Digestmethod, [ValidateSet('exact', 'minimum', 'maximum', 'better')] [string]$Requestedauthncontext, [ValidateSet('InternetProtocol', 'InternetProtocolPassword', 'Kerberos', 'MobileOneFactorUnregistered', 'MobileTwoFactorUnregistered', 'MobileOneFactorContract', 'MobileTwoFactorContract', 'Password', 'PasswordProtectedTransport', 'PreviousSession', 'X509', 'PGP', 'SPKI', 'XMLDSig', 'Smartcard', 'SmartcardPKI', 'SoftwarePKI', 'Telephony', 'NomadTelephony', 'PersonalTelephony', 'AuthenticatedTelephony', 'SecureRemotePassword', 'TLSClient', 'TimeSyncToken', 'Unspecified', 'Windows')] [string[]]$Authnctxclassref, [string]$Customauthnctxclassref, [ValidateSet('REDIRECT', 'POST', 'ARTIFACT')] [string]$Samlbinding, [ValidateRange(0, 255)] [double]$Attributeconsumingserviceindex, [ValidateSet('ON', 'OFF')] [string]$Sendthumbprint, [ValidateSet('ON', 'OFF')] [string]$Enforceusername, [string]$Logouturl, [string]$Artifactresolutionserviceurl, [double]$Skewtime, [ValidateSet('REDIRECT', 'POST')] [string]$Logoutbinding, [ValidateSet('ON', 'OFF')] [string]$Forceauthn, [string]$Groupnamefield, [string]$Audience, [double]$Metadatarefreshinterval, [ValidateSet('ON', 'OFF')] [string]$Storesamlresponse, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationsamlaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('metadataurl') ) { $payload.Add('metadataurl', $metadataurl) } if ( $PSBoundParameters.ContainsKey('samlidpcertname') ) { $payload.Add('samlidpcertname', $samlidpcertname) } if ( $PSBoundParameters.ContainsKey('samlsigningcertname') ) { $payload.Add('samlsigningcertname', $samlsigningcertname) } if ( $PSBoundParameters.ContainsKey('samlredirecturl') ) { $payload.Add('samlredirecturl', $samlredirecturl) } if ( $PSBoundParameters.ContainsKey('samlacsindex') ) { $payload.Add('samlacsindex', $samlacsindex) } if ( $PSBoundParameters.ContainsKey('samluserfield') ) { $payload.Add('samluserfield', $samluserfield) } if ( $PSBoundParameters.ContainsKey('samlrejectunsignedassertion') ) { $payload.Add('samlrejectunsignedassertion', $samlrejectunsignedassertion) } if ( $PSBoundParameters.ContainsKey('samlissuername') ) { $payload.Add('samlissuername', $samlissuername) } if ( $PSBoundParameters.ContainsKey('samltwofactor') ) { $payload.Add('samltwofactor', $samltwofactor) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('attribute1') ) { $payload.Add('attribute1', $attribute1) } if ( $PSBoundParameters.ContainsKey('attribute2') ) { $payload.Add('attribute2', $attribute2) } if ( $PSBoundParameters.ContainsKey('attribute3') ) { $payload.Add('attribute3', $attribute3) } if ( $PSBoundParameters.ContainsKey('attribute4') ) { $payload.Add('attribute4', $attribute4) } if ( $PSBoundParameters.ContainsKey('attribute5') ) { $payload.Add('attribute5', $attribute5) } if ( $PSBoundParameters.ContainsKey('attribute6') ) { $payload.Add('attribute6', $attribute6) } if ( $PSBoundParameters.ContainsKey('attribute7') ) { $payload.Add('attribute7', $attribute7) } if ( $PSBoundParameters.ContainsKey('attribute8') ) { $payload.Add('attribute8', $attribute8) } if ( $PSBoundParameters.ContainsKey('attribute9') ) { $payload.Add('attribute9', $attribute9) } if ( $PSBoundParameters.ContainsKey('attribute10') ) { $payload.Add('attribute10', $attribute10) } if ( $PSBoundParameters.ContainsKey('attribute11') ) { $payload.Add('attribute11', $attribute11) } if ( $PSBoundParameters.ContainsKey('attribute12') ) { $payload.Add('attribute12', $attribute12) } if ( $PSBoundParameters.ContainsKey('attribute13') ) { $payload.Add('attribute13', $attribute13) } if ( $PSBoundParameters.ContainsKey('attribute14') ) { $payload.Add('attribute14', $attribute14) } if ( $PSBoundParameters.ContainsKey('attribute15') ) { $payload.Add('attribute15', $attribute15) } if ( $PSBoundParameters.ContainsKey('attribute16') ) { $payload.Add('attribute16', $attribute16) } if ( $PSBoundParameters.ContainsKey('attributes') ) { $payload.Add('attributes', $attributes) } if ( $PSBoundParameters.ContainsKey('relaystaterule') ) { $payload.Add('relaystaterule', $relaystaterule) } if ( $PSBoundParameters.ContainsKey('signaturealg') ) { $payload.Add('signaturealg', $signaturealg) } if ( $PSBoundParameters.ContainsKey('digestmethod') ) { $payload.Add('digestmethod', $digestmethod) } if ( $PSBoundParameters.ContainsKey('requestedauthncontext') ) { $payload.Add('requestedauthncontext', $requestedauthncontext) } if ( $PSBoundParameters.ContainsKey('authnctxclassref') ) { $payload.Add('authnctxclassref', $authnctxclassref) } if ( $PSBoundParameters.ContainsKey('customauthnctxclassref') ) { $payload.Add('customauthnctxclassref', $customauthnctxclassref) } if ( $PSBoundParameters.ContainsKey('samlbinding') ) { $payload.Add('samlbinding', $samlbinding) } if ( $PSBoundParameters.ContainsKey('attributeconsumingserviceindex') ) { $payload.Add('attributeconsumingserviceindex', $attributeconsumingserviceindex) } if ( $PSBoundParameters.ContainsKey('sendthumbprint') ) { $payload.Add('sendthumbprint', $sendthumbprint) } if ( $PSBoundParameters.ContainsKey('enforceusername') ) { $payload.Add('enforceusername', $enforceusername) } if ( $PSBoundParameters.ContainsKey('logouturl') ) { $payload.Add('logouturl', $logouturl) } if ( $PSBoundParameters.ContainsKey('artifactresolutionserviceurl') ) { $payload.Add('artifactresolutionserviceurl', $artifactresolutionserviceurl) } if ( $PSBoundParameters.ContainsKey('skewtime') ) { $payload.Add('skewtime', $skewtime) } if ( $PSBoundParameters.ContainsKey('logoutbinding') ) { $payload.Add('logoutbinding', $logoutbinding) } if ( $PSBoundParameters.ContainsKey('forceauthn') ) { $payload.Add('forceauthn', $forceauthn) } if ( $PSBoundParameters.ContainsKey('groupnamefield') ) { $payload.Add('groupnamefield', $groupnamefield) } if ( $PSBoundParameters.ContainsKey('audience') ) { $payload.Add('audience', $audience) } if ( $PSBoundParameters.ContainsKey('metadatarefreshinterval') ) { $payload.Add('metadatarefreshinterval', $metadatarefreshinterval) } if ( $PSBoundParameters.ContainsKey('storesamlresponse') ) { $payload.Add('storesamlresponse', $storesamlresponse) } if ( $PSCmdlet.ShouldProcess("authenticationsamlaction", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationsamlaction -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationsamlaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationsamlaction: Finished" } } function Invoke-ADCDeleteAuthenticationsamlaction { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for AAA Saml action resource. .PARAMETER Name Name for the SAML server profile (action). Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after SAML profile is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationsamlaction -Name <string> An example how to delete authenticationsamlaction configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationsamlaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationsamlaction: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationsamlaction -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationsamlaction: Finished" } } function Invoke-ADCAddAuthenticationsamlaction { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for AAA Saml action resource. .PARAMETER Name Name for the SAML server profile (action). Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after SAML profile is created. .PARAMETER Metadataurl This URL is used for obtaining saml metadata. Note that it fills samlIdPCertName and samlredirectUrl fields so those fields should not be updated when metadataUrl present. .PARAMETER Samlidpcertname Name of the SSL certificate used to verify responses from SAML Identity Provider (IdP). Note that if metadateURL is present then this filed should be empty. .PARAMETER Samlsigningcertname Name of the SSL certificate to sign requests from ServiceProvider (SP) to Identity Provider (IdP). .PARAMETER Samlredirecturl URL to which users are redirected for authentication. Note that if metadateURL is present then this filed should be empty. .PARAMETER Samlacsindex Index/ID of the metadata entry corresponding to this configuration. .PARAMETER Samluserfield SAML user ID, as given in the SAML assertion. .PARAMETER Samlrejectunsignedassertion Reject unsigned SAML assertions. ON option results in rejection of Assertion that is received without signature. STRICT option ensures that both Response and Assertion are signed. OFF allows unsigned Assertions. Possible values = ON, OFF, STRICT .PARAMETER Samlissuername The name to be used in requests sent from Citrix ADC to IdP to uniquely identify Citrix ADC. .PARAMETER Samltwofactor Option to enable second factor after SAML. Possible values = ON, OFF .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER Attribute1 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute1. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute2 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute2. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute3 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute3. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute4 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute4. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute5 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute5. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute6 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute6. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute7 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute7. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute8 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute8. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute9 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute9. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute10 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute10. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute11 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute11. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute12 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute12. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute13 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute13. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute14 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute14. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute15 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute15. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attribute16 Name of the attribute in SAML Assertion whose value needs to be extracted and stored as attribute16. Maximum length of the extracted attribute is 239 bytes. .PARAMETER Attributes List of attribute names separated by ',' which needs to be extracted. Note that preceeding and trailing spaces will be removed. Attribute name can be 127 bytes and total length of this string should not cross 2047 bytes. These attributes have multi-value support separated by ',' and stored as key-value pair in AAA session. .PARAMETER Relaystaterule Boolean expression that will be evaluated to validate the SAML Response. .PARAMETER Signaturealg Algorithm to be used to sign/verify SAML transactions. Possible values = RSA-SHA1, RSA-SHA256 .PARAMETER Digestmethod Algorithm to be used to compute/verify digest for SAML transactions. Possible values = SHA1, SHA256 .PARAMETER Requestedauthncontext This element specifies the authentication context requirements of authentication statements returned in the response. Possible values = exact, minimum, maximum, better .PARAMETER Authnctxclassref This element specifies the authentication class types that are requested from IdP (IdentityProvider). InternetProtocol: This is applicable when a principal is authenticated through the use of a provided IP address. InternetProtocolPassword: This is applicable when a principal is authenticated through the use of a provided IP address, in addition to a username/password. Kerberos: This is applicable when the principal has authenticated using a password to a local authentication authority, in order to acquire a Kerberos ticket. MobileOneFactorUnregistered: This indicates authentication of the mobile device without requiring explicit end-user interaction. MobileTwoFactorUnregistered: This indicates two-factor based authentication during mobile customer registration process, such as secure device and user PIN. MobileOneFactorContract: Reflects mobile contract customer registration procedures and a single factor authentication. MobileTwoFactorContract: Reflects mobile contract customer registration procedures and a two-factor based authentication. Password: This class is applicable when a principal authenticates using password over unprotected http session. PasswordProtectedTransport: This class is applicable when a principal authenticates to an authentication authority through the presentation of a password over a protected session. PreviousSession: This class is applicable when a principal had authenticated to an authentication authority at some point in the past using any authentication context. X509: This indicates that the principal authenticated by means of a digital signature where the key was validated as part of an X.509 Public Key Infrastructure. PGP: This indicates that the principal authenticated by means of a digital signature where the key was validated as part of a PGP Public Key Infrastructure. SPKI: This indicates that the principal authenticated by means of a digital signature where the key was validated via an SPKI Infrastructure. XMLDSig: This indicates that the principal authenticated by means of a digital signature according to the processing rules specified in the XML Digital Signature specification. Smartcard: This indicates that the principal has authenticated using smartcard. SmartcardPKI: This class is applicable when a principal authenticates to an authentication authority through a two-factor authentication mechanism using a smartcard with enclosed private key and a PIN. SoftwarePKI: This class is applicable when a principal uses an X.509 certificate stored in software to authenticate to the authentication authority. Telephony: This class is used to indicate that the principal authenticated via the provision of a fixed-line telephone number, transported via a telephony protocol such as ADSL. NomadTelephony: Indicates that the principal is "roaming" and authenticates via the means of the line number, a user suffix, and a password element. PersonalTelephony: This class is used to indicate that the principal authenticated via the provision of a fixed-line telephone. AuthenticatedTelephony: Indicates that the principal authenticated via the means of the line number, a user suffix, and a password element. SecureRemotePassword: This class is applicable when the authentication was performed by means of Secure Remote Password. TLSClient: This class indicates that the principal authenticated by means of a client certificate, secured with the SSL/TLS transport. TimeSyncToken: This is applicable when a principal authenticates through a time synchronization token. Unspecified: This indicates that the authentication was performed by unspecified means. Windows: This indicates that Windows integrated authentication is utilized for authentication. Possible values = InternetProtocol, InternetProtocolPassword, Kerberos, MobileOneFactorUnregistered, MobileTwoFactorUnregistered, MobileOneFactorContract, MobileTwoFactorContract, Password, PasswordProtectedTransport, PreviousSession, X509, PGP, SPKI, XMLDSig, Smartcard, SmartcardPKI, SoftwarePKI, Telephony, NomadTelephony, PersonalTelephony, AuthenticatedTelephony, SecureRemotePassword, TLSClient, TimeSyncToken, Unspecified, Windows .PARAMETER Customauthnctxclassref This element specifies the custom authentication class reference to be sent as a part of the Authentication Request that is sent by the SP to SAML IDP. The input string must be the body of the authentication class being requested. Input format: Alphanumeric string or URL specifying the body of the Request.If more than one string has to be provided, then the same can be done by specifying the classes as a string of comma separated values. Example input: set authentication samlaction samlact1 -customAuthnCtxClassRef http://www.class1.com/LoA1,http://www.class2.com/LoA2 . .PARAMETER Samlbinding This element specifies the transport mechanism of saml messages. Possible values = REDIRECT, POST, ARTIFACT .PARAMETER Attributeconsumingserviceindex Index/ID of the attribute specification at Identity Provider (IdP). IdP will locate attributes requested by SP using this index and send those attributes in Assertion. .PARAMETER Sendthumbprint Option to send thumbprint instead of x509 certificate in SAML request. Possible values = ON, OFF .PARAMETER Enforceusername Option to choose whether the username that is extracted from SAML assertion can be edited in login page while doing second factor. Possible values = ON, OFF .PARAMETER Logouturl SingleLogout URL on IdP to which logoutRequest will be sent on Citrix ADC session cleanup. .PARAMETER Artifactresolutionserviceurl URL of the Artifact Resolution Service on IdP to which Citrix ADC will post artifact to get actual SAML token. .PARAMETER Skewtime This option specifies the allowed clock skew in number of minutes that Citrix ADC ServiceProvider allows on an incoming assertion. For example, if skewTime is 10, then assertion would be valid from (current time - 10) min to (current time + 10) min, ie 20min in all. .PARAMETER Logoutbinding This element specifies the transport mechanism of saml logout messages. Possible values = REDIRECT, POST .PARAMETER Forceauthn Option that forces authentication at the Identity Provider (IdP) that receives Citrix ADC's request. Possible values = ON, OFF .PARAMETER Groupnamefield Name of the tag in assertion that contains user groups. .PARAMETER Audience Audience for which assertion sent by IdP is applicable. This is typically entity name or url that represents ServiceProvider. .PARAMETER Metadatarefreshinterval Interval in minutes for fetching metadata from specified metadata URL. .PARAMETER Storesamlresponse Option to store entire SAML Response through the life of user session. Possible values = ON, OFF .PARAMETER PassThru Return details about the created authenticationsamlaction item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationsamlaction -name <string> An example how to add authenticationsamlaction configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationsamlaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Metadataurl, [ValidateScript({ $_.Length -gt 1 })] [string]$Samlidpcertname, [ValidateScript({ $_.Length -gt 1 })] [string]$Samlsigningcertname, [ValidateScript({ $_.Length -gt 1 })] [string]$Samlredirecturl, [ValidateRange(0, 255)] [double]$Samlacsindex = '255', [ValidateScript({ $_.Length -gt 1 })] [string]$Samluserfield, [ValidateSet('ON', 'OFF', 'STRICT')] [string]$Samlrejectunsignedassertion = 'ON', [ValidateScript({ $_.Length -gt 1 })] [string]$Samlissuername, [ValidateSet('ON', 'OFF')] [string]$Samltwofactor = 'OFF', [string]$Defaultauthenticationgroup, [string]$Attribute1, [string]$Attribute2, [string]$Attribute3, [string]$Attribute4, [string]$Attribute5, [string]$Attribute6, [string]$Attribute7, [string]$Attribute8, [string]$Attribute9, [string]$Attribute10, [string]$Attribute11, [string]$Attribute12, [string]$Attribute13, [string]$Attribute14, [string]$Attribute15, [string]$Attribute16, [string]$Attributes, [string]$Relaystaterule, [ValidateSet('RSA-SHA1', 'RSA-SHA256')] [string]$Signaturealg = 'RSA-SHA256', [ValidateSet('SHA1', 'SHA256')] [string]$Digestmethod = 'SHA256', [ValidateSet('exact', 'minimum', 'maximum', 'better')] [string]$Requestedauthncontext = 'exact', [ValidateSet('InternetProtocol', 'InternetProtocolPassword', 'Kerberos', 'MobileOneFactorUnregistered', 'MobileTwoFactorUnregistered', 'MobileOneFactorContract', 'MobileTwoFactorContract', 'Password', 'PasswordProtectedTransport', 'PreviousSession', 'X509', 'PGP', 'SPKI', 'XMLDSig', 'Smartcard', 'SmartcardPKI', 'SoftwarePKI', 'Telephony', 'NomadTelephony', 'PersonalTelephony', 'AuthenticatedTelephony', 'SecureRemotePassword', 'TLSClient', 'TimeSyncToken', 'Unspecified', 'Windows')] [string[]]$Authnctxclassref, [string]$Customauthnctxclassref, [ValidateSet('REDIRECT', 'POST', 'ARTIFACT')] [string]$Samlbinding = 'POST', [ValidateRange(0, 255)] [double]$Attributeconsumingserviceindex = '255', [ValidateSet('ON', 'OFF')] [string]$Sendthumbprint = 'OFF', [ValidateSet('ON', 'OFF')] [string]$Enforceusername = 'ON', [string]$Logouturl, [string]$Artifactresolutionserviceurl, [double]$Skewtime = '5', [ValidateSet('REDIRECT', 'POST')] [string]$Logoutbinding = 'POST', [ValidateSet('ON', 'OFF')] [string]$Forceauthn = 'OFF', [string]$Groupnamefield, [string]$Audience, [double]$Metadatarefreshinterval = '36000', [ValidateSet('ON', 'OFF')] [string]$Storesamlresponse = 'OFF', [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationsamlaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('metadataurl') ) { $payload.Add('metadataurl', $metadataurl) } if ( $PSBoundParameters.ContainsKey('samlidpcertname') ) { $payload.Add('samlidpcertname', $samlidpcertname) } if ( $PSBoundParameters.ContainsKey('samlsigningcertname') ) { $payload.Add('samlsigningcertname', $samlsigningcertname) } if ( $PSBoundParameters.ContainsKey('samlredirecturl') ) { $payload.Add('samlredirecturl', $samlredirecturl) } if ( $PSBoundParameters.ContainsKey('samlacsindex') ) { $payload.Add('samlacsindex', $samlacsindex) } if ( $PSBoundParameters.ContainsKey('samluserfield') ) { $payload.Add('samluserfield', $samluserfield) } if ( $PSBoundParameters.ContainsKey('samlrejectunsignedassertion') ) { $payload.Add('samlrejectunsignedassertion', $samlrejectunsignedassertion) } if ( $PSBoundParameters.ContainsKey('samlissuername') ) { $payload.Add('samlissuername', $samlissuername) } if ( $PSBoundParameters.ContainsKey('samltwofactor') ) { $payload.Add('samltwofactor', $samltwofactor) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('attribute1') ) { $payload.Add('attribute1', $attribute1) } if ( $PSBoundParameters.ContainsKey('attribute2') ) { $payload.Add('attribute2', $attribute2) } if ( $PSBoundParameters.ContainsKey('attribute3') ) { $payload.Add('attribute3', $attribute3) } if ( $PSBoundParameters.ContainsKey('attribute4') ) { $payload.Add('attribute4', $attribute4) } if ( $PSBoundParameters.ContainsKey('attribute5') ) { $payload.Add('attribute5', $attribute5) } if ( $PSBoundParameters.ContainsKey('attribute6') ) { $payload.Add('attribute6', $attribute6) } if ( $PSBoundParameters.ContainsKey('attribute7') ) { $payload.Add('attribute7', $attribute7) } if ( $PSBoundParameters.ContainsKey('attribute8') ) { $payload.Add('attribute8', $attribute8) } if ( $PSBoundParameters.ContainsKey('attribute9') ) { $payload.Add('attribute9', $attribute9) } if ( $PSBoundParameters.ContainsKey('attribute10') ) { $payload.Add('attribute10', $attribute10) } if ( $PSBoundParameters.ContainsKey('attribute11') ) { $payload.Add('attribute11', $attribute11) } if ( $PSBoundParameters.ContainsKey('attribute12') ) { $payload.Add('attribute12', $attribute12) } if ( $PSBoundParameters.ContainsKey('attribute13') ) { $payload.Add('attribute13', $attribute13) } if ( $PSBoundParameters.ContainsKey('attribute14') ) { $payload.Add('attribute14', $attribute14) } if ( $PSBoundParameters.ContainsKey('attribute15') ) { $payload.Add('attribute15', $attribute15) } if ( $PSBoundParameters.ContainsKey('attribute16') ) { $payload.Add('attribute16', $attribute16) } if ( $PSBoundParameters.ContainsKey('attributes') ) { $payload.Add('attributes', $attributes) } if ( $PSBoundParameters.ContainsKey('relaystaterule') ) { $payload.Add('relaystaterule', $relaystaterule) } if ( $PSBoundParameters.ContainsKey('signaturealg') ) { $payload.Add('signaturealg', $signaturealg) } if ( $PSBoundParameters.ContainsKey('digestmethod') ) { $payload.Add('digestmethod', $digestmethod) } if ( $PSBoundParameters.ContainsKey('requestedauthncontext') ) { $payload.Add('requestedauthncontext', $requestedauthncontext) } if ( $PSBoundParameters.ContainsKey('authnctxclassref') ) { $payload.Add('authnctxclassref', $authnctxclassref) } if ( $PSBoundParameters.ContainsKey('customauthnctxclassref') ) { $payload.Add('customauthnctxclassref', $customauthnctxclassref) } if ( $PSBoundParameters.ContainsKey('samlbinding') ) { $payload.Add('samlbinding', $samlbinding) } if ( $PSBoundParameters.ContainsKey('attributeconsumingserviceindex') ) { $payload.Add('attributeconsumingserviceindex', $attributeconsumingserviceindex) } if ( $PSBoundParameters.ContainsKey('sendthumbprint') ) { $payload.Add('sendthumbprint', $sendthumbprint) } if ( $PSBoundParameters.ContainsKey('enforceusername') ) { $payload.Add('enforceusername', $enforceusername) } if ( $PSBoundParameters.ContainsKey('logouturl') ) { $payload.Add('logouturl', $logouturl) } if ( $PSBoundParameters.ContainsKey('artifactresolutionserviceurl') ) { $payload.Add('artifactresolutionserviceurl', $artifactresolutionserviceurl) } if ( $PSBoundParameters.ContainsKey('skewtime') ) { $payload.Add('skewtime', $skewtime) } if ( $PSBoundParameters.ContainsKey('logoutbinding') ) { $payload.Add('logoutbinding', $logoutbinding) } if ( $PSBoundParameters.ContainsKey('forceauthn') ) { $payload.Add('forceauthn', $forceauthn) } if ( $PSBoundParameters.ContainsKey('groupnamefield') ) { $payload.Add('groupnamefield', $groupnamefield) } if ( $PSBoundParameters.ContainsKey('audience') ) { $payload.Add('audience', $audience) } if ( $PSBoundParameters.ContainsKey('metadatarefreshinterval') ) { $payload.Add('metadatarefreshinterval', $metadatarefreshinterval) } if ( $PSBoundParameters.ContainsKey('storesamlresponse') ) { $payload.Add('storesamlresponse', $storesamlresponse) } if ( $PSCmdlet.ShouldProcess("authenticationsamlaction", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationsamlaction -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationsamlaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationsamlaction: Finished" } } function Invoke-ADCGetAuthenticationsamlaction { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for AAA Saml action resource. .PARAMETER Name Name for the SAML server profile (action). Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after SAML profile is created. .PARAMETER GetAll Retrieve all authenticationsamlaction object(s). .PARAMETER Count If specified, the count of the authenticationsamlaction object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlaction Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlaction -GetAll Get all authenticationsamlaction data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlaction -Count Get the number of authenticationsamlaction objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlaction -name <string> Get authenticationsamlaction object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlaction -Filter @{ 'name'='<value>' } Get authenticationsamlaction data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationsamlaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationsamlaction: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationsamlaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationsamlaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationsamlaction objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlaction -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationsamlaction configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlaction -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationsamlaction configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlaction -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationsamlaction: Ended" } } function Invoke-ADCUnsetAuthenticationsamlidppolicy { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for AAA Saml IdentityProvider (IdP) policy resource. .PARAMETER Name Name for the SAML Identity Provider (IdP) authentication policy. This is used for configuring Citrix ADC as SAML Identity Provider. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the policy is created. .PARAMETER Undefaction Action to perform if the result of policy evaluation is undefined (UNDEF). An UNDEF event indicates an internal error condition. Only the above built-in actions can be used. .PARAMETER Comment Any comments to preserve information about this policy. .PARAMETER Logaction Name of messagelog action to use when a request matches this policy. .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationsamlidppolicy -name <string> An example how to unset authenticationsamlidppolicy configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationsamlidppolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlidppolicy Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Boolean]$undefaction, [Boolean]$comment, [Boolean]$logaction ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationsamlidppolicy: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('undefaction') ) { $payload.Add('undefaction', $undefaction) } if ( $PSBoundParameters.ContainsKey('comment') ) { $payload.Add('comment', $comment) } if ( $PSBoundParameters.ContainsKey('logaction') ) { $payload.Add('logaction', $logaction) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationsamlidppolicy -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationsamlidppolicy: Finished" } } function Invoke-ADCDeleteAuthenticationsamlidppolicy { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for AAA Saml IdentityProvider (IdP) policy resource. .PARAMETER Name Name for the SAML Identity Provider (IdP) authentication policy. This is used for configuring Citrix ADC as SAML Identity Provider. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the policy is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationsamlidppolicy -Name <string> An example how to delete authenticationsamlidppolicy configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationsamlidppolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlidppolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationsamlidppolicy: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationsamlidppolicy -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationsamlidppolicy: Finished" } } function Invoke-ADCUpdateAuthenticationsamlidppolicy { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for AAA Saml IdentityProvider (IdP) policy resource. .PARAMETER Name Name for the SAML Identity Provider (IdP) authentication policy. This is used for configuring Citrix ADC as SAML Identity Provider. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the policy is created. .PARAMETER Rule Expression which is evaluated to choose a profile for authentication. The following requirements apply only to the Citrix ADC CLI: * If the expression includes one or more spaces, enclose the entire expression in double quotation marks. * If the expression itself includes double quotation marks, escape the quotations by using the \ character. * Alternatively, you can use single quotation marks to enclose the rule, in which case you do not have to escape the double quotation marks. .PARAMETER Action Name of the profile to apply to requests or connections that match this policy. .PARAMETER Undefaction Action to perform if the result of policy evaluation is undefined (UNDEF). An UNDEF event indicates an internal error condition. Only the above built-in actions can be used. .PARAMETER Comment Any comments to preserve information about this policy. .PARAMETER Logaction Name of messagelog action to use when a request matches this policy. .PARAMETER PassThru Return details about the created authenticationsamlidppolicy item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationsamlidppolicy -name <string> An example how to update authenticationsamlidppolicy configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationsamlidppolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlidppolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Rule, [ValidateScript({ $_.Length -gt 1 })] [string]$Action, [string]$Undefaction, [string]$Comment, [string]$Logaction, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationsamlidppolicy: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('rule') ) { $payload.Add('rule', $rule) } if ( $PSBoundParameters.ContainsKey('action') ) { $payload.Add('action', $action) } if ( $PSBoundParameters.ContainsKey('undefaction') ) { $payload.Add('undefaction', $undefaction) } if ( $PSBoundParameters.ContainsKey('comment') ) { $payload.Add('comment', $comment) } if ( $PSBoundParameters.ContainsKey('logaction') ) { $payload.Add('logaction', $logaction) } if ( $PSCmdlet.ShouldProcess("authenticationsamlidppolicy", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationsamlidppolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationsamlidppolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationsamlidppolicy: Finished" } } function Invoke-ADCAddAuthenticationsamlidppolicy { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for AAA Saml IdentityProvider (IdP) policy resource. .PARAMETER Name Name for the SAML Identity Provider (IdP) authentication policy. This is used for configuring Citrix ADC as SAML Identity Provider. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the policy is created. .PARAMETER Rule Expression which is evaluated to choose a profile for authentication. The following requirements apply only to the Citrix ADC CLI: * If the expression includes one or more spaces, enclose the entire expression in double quotation marks. * If the expression itself includes double quotation marks, escape the quotations by using the \ character. * Alternatively, you can use single quotation marks to enclose the rule, in which case you do not have to escape the double quotation marks. .PARAMETER Action Name of the profile to apply to requests or connections that match this policy. .PARAMETER Undefaction Action to perform if the result of policy evaluation is undefined (UNDEF). An UNDEF event indicates an internal error condition. Only the above built-in actions can be used. .PARAMETER Comment Any comments to preserve information about this policy. .PARAMETER Logaction Name of messagelog action to use when a request matches this policy. .PARAMETER PassThru Return details about the created authenticationsamlidppolicy item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationsamlidppolicy -name <string> -rule <string> -action <string> An example how to add authenticationsamlidppolicy configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationsamlidppolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlidppolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Rule, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Action, [string]$Undefaction, [string]$Comment, [string]$Logaction, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationsamlidppolicy: Starting" } process { try { $payload = @{ name = $name rule = $rule action = $action } if ( $PSBoundParameters.ContainsKey('undefaction') ) { $payload.Add('undefaction', $undefaction) } if ( $PSBoundParameters.ContainsKey('comment') ) { $payload.Add('comment', $comment) } if ( $PSBoundParameters.ContainsKey('logaction') ) { $payload.Add('logaction', $logaction) } if ( $PSCmdlet.ShouldProcess("authenticationsamlidppolicy", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationsamlidppolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationsamlidppolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationsamlidppolicy: Finished" } } function Invoke-ADCRenameAuthenticationsamlidppolicy { <# .SYNOPSIS Rename Authentication configuration Object. .DESCRIPTION Configuration for AAA Saml IdentityProvider (IdP) policy resource. .PARAMETER Name Name for the SAML Identity Provider (IdP) authentication policy. This is used for configuring Citrix ADC as SAML Identity Provider. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the policy is created. .PARAMETER Newname New name for the SAML IdentityProvider policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) hash (#), space ( ), at (@), equals (=), colon (:), and underscore characters. .PARAMETER PassThru Return details about the created authenticationsamlidppolicy item. .EXAMPLE PS C:\>Invoke-ADCRenameAuthenticationsamlidppolicy -name <string> -newname <string> An example how to rename authenticationsamlidppolicy configuration Object(s). .NOTES File Name : Invoke-ADCRenameAuthenticationsamlidppolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlidppolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Newname, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCRenameAuthenticationsamlidppolicy: Starting" } process { try { $payload = @{ name = $name newname = $newname } if ( $PSCmdlet.ShouldProcess("authenticationsamlidppolicy", "Rename Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationsamlidppolicy -Action rename -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationsamlidppolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCRenameAuthenticationsamlidppolicy: Finished" } } function Invoke-ADCGetAuthenticationsamlidppolicy { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for AAA Saml IdentityProvider (IdP) policy resource. .PARAMETER Name Name for the SAML Identity Provider (IdP) authentication policy. This is used for configuring Citrix ADC as SAML Identity Provider. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the policy is created. .PARAMETER GetAll Retrieve all authenticationsamlidppolicy object(s). .PARAMETER Count If specified, the count of the authenticationsamlidppolicy object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidppolicy Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidppolicy -GetAll Get all authenticationsamlidppolicy data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidppolicy -Count Get the number of authenticationsamlidppolicy objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidppolicy -name <string> Get authenticationsamlidppolicy object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidppolicy -Filter @{ 'name'='<value>' } Get authenticationsamlidppolicy data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationsamlidppolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlidppolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationsamlidppolicy: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationsamlidppolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidppolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationsamlidppolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidppolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationsamlidppolicy objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidppolicy -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationsamlidppolicy configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidppolicy -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationsamlidppolicy configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidppolicy -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationsamlidppolicy: Ended" } } function Invoke-ADCGetAuthenticationsamlidppolicyauthenticationvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationvserver that can be bound to authenticationsamlidppolicy. .PARAMETER Name Name of the SAML IdentityProvider (IdP) policy for which to display detailed information. .PARAMETER GetAll Retrieve all authenticationsamlidppolicy_authenticationvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationsamlidppolicy_authenticationvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidppolicyauthenticationvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidppolicyauthenticationvserverbinding -GetAll Get all authenticationsamlidppolicy_authenticationvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidppolicyauthenticationvserverbinding -Count Get the number of authenticationsamlidppolicy_authenticationvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidppolicyauthenticationvserverbinding -name <string> Get authenticationsamlidppolicy_authenticationvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidppolicyauthenticationvserverbinding -Filter @{ 'name'='<value>' } Get authenticationsamlidppolicy_authenticationvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationsamlidppolicyauthenticationvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlidppolicy_authenticationvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationsamlidppolicyauthenticationvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationsamlidppolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidppolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationsamlidppolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidppolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationsamlidppolicy_authenticationvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidppolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationsamlidppolicy_authenticationvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidppolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationsamlidppolicy_authenticationvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidppolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationsamlidppolicyauthenticationvserverbinding: Ended" } } function Invoke-ADCGetAuthenticationsamlidppolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object which returns the resources bound to authenticationsamlidppolicy. .PARAMETER Name Name of the SAML IdentityProvider (IdP) policy for which to display detailed information. .PARAMETER GetAll Retrieve all authenticationsamlidppolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationsamlidppolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidppolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidppolicybinding -GetAll Get all authenticationsamlidppolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidppolicybinding -name <string> Get authenticationsamlidppolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidppolicybinding -Filter @{ 'name'='<value>' } Get authenticationsamlidppolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationsamlidppolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlidppolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationsamlidppolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationsamlidppolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidppolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationsamlidppolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidppolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationsamlidppolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidppolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationsamlidppolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidppolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationsamlidppolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidppolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationsamlidppolicybinding: Ended" } } function Invoke-ADCGetAuthenticationsamlidppolicyvpnvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the vpnvserver that can be bound to authenticationsamlidppolicy. .PARAMETER Name Name of the SAML IdentityProvider (IdP) policy for which to display detailed information. .PARAMETER GetAll Retrieve all authenticationsamlidppolicy_vpnvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationsamlidppolicy_vpnvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidppolicyvpnvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidppolicyvpnvserverbinding -GetAll Get all authenticationsamlidppolicy_vpnvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidppolicyvpnvserverbinding -Count Get the number of authenticationsamlidppolicy_vpnvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidppolicyvpnvserverbinding -name <string> Get authenticationsamlidppolicy_vpnvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidppolicyvpnvserverbinding -Filter @{ 'name'='<value>' } Get authenticationsamlidppolicy_vpnvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationsamlidppolicyvpnvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlidppolicy_vpnvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationsamlidppolicyvpnvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationsamlidppolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidppolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationsamlidppolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidppolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationsamlidppolicy_vpnvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidppolicy_vpnvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationsamlidppolicy_vpnvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidppolicy_vpnvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationsamlidppolicy_vpnvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidppolicy_vpnvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationsamlidppolicyvpnvserverbinding: Ended" } } function Invoke-ADCUnsetAuthenticationsamlidpprofile { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for AAA Saml IdentityProvider (IdP) profile resource. .PARAMETER Name Name for the new saml single sign-on profile. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER Samlspcertname Name of the SSL certificate of SAML Relying Party. This certificate is used to verify signature of the incoming AuthnRequest from a Relying Party or Service Provider. .PARAMETER Samlidpcertname Name of the certificate used to sign the SAMLResposne that is sent to Relying Party or Service Provider after successful authentication. .PARAMETER Assertionconsumerserviceurl URL to which the assertion is to be sent. .PARAMETER Sendpassword Option to send password in assertion. Possible values = ON, OFF .PARAMETER Samlissuername The name to be used in requests sent from Citrix ADC to IdP to uniquely identify Citrix ADC. .PARAMETER Rejectunsignedrequests Option to Reject unsigned SAML Requests. ON option denies any authentication requests that arrive without signature. Possible values = ON, OFF .PARAMETER Signaturealg Algorithm to be used to sign/verify SAML transactions. Possible values = RSA-SHA1, RSA-SHA256 .PARAMETER Digestmethod Algorithm to be used to compute/verify digest for SAML transactions. Possible values = SHA1, SHA256 .PARAMETER Audience Audience for which assertion sent by IdP is applicable. This is typically entity name or url that represents ServiceProvider. .PARAMETER Nameidformat Format of Name Identifier sent in Assertion. Possible values = Unspecified, emailAddress, X509SubjectName, WindowsDomainQualifiedName, kerberos, entity, persistent, transient .PARAMETER Nameidexpr Expression that will be evaluated to obtain NameIdentifier to be sent in assertion. .PARAMETER Attribute1 Name of attribute1 that needs to be sent in SAML Assertion. .PARAMETER Attribute1friendlyname User-Friendly Name of attribute1 that needs to be sent in SAML Assertion. .PARAMETER Attribute1format Format of Attribute1 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute2 Name of attribute2 that needs to be sent in SAML Assertion. .PARAMETER Attribute2friendlyname User-Friendly Name of attribute2 that needs to be sent in SAML Assertion. .PARAMETER Attribute2format Format of Attribute2 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute3 Name of attribute3 that needs to be sent in SAML Assertion. .PARAMETER Attribute3friendlyname User-Friendly Name of attribute3 that needs to be sent in SAML Assertion. .PARAMETER Attribute3format Format of Attribute3 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute4 Name of attribute4 that needs to be sent in SAML Assertion. .PARAMETER Attribute4friendlyname User-Friendly Name of attribute4 that needs to be sent in SAML Assertion. .PARAMETER Attribute4format Format of Attribute4 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute5 Name of attribute5 that needs to be sent in SAML Assertion. .PARAMETER Attribute5friendlyname User-Friendly Name of attribute5 that needs to be sent in SAML Assertion. .PARAMETER Attribute5format Format of Attribute5 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute6 Name of attribute6 that needs to be sent in SAML Assertion. .PARAMETER Attribute6friendlyname User-Friendly Name of attribute6 that needs to be sent in SAML Assertion. .PARAMETER Attribute6format Format of Attribute6 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute7 Name of attribute7 that needs to be sent in SAML Assertion. .PARAMETER Attribute7friendlyname User-Friendly Name of attribute7 that needs to be sent in SAML Assertion. .PARAMETER Attribute7format Format of Attribute7 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute8 Name of attribute8 that needs to be sent in SAML Assertion. .PARAMETER Attribute8friendlyname User-Friendly Name of attribute8 that needs to be sent in SAML Assertion. .PARAMETER Attribute8format Format of Attribute8 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute9 Name of attribute9 that needs to be sent in SAML Assertion. .PARAMETER Attribute9friendlyname User-Friendly Name of attribute9 that needs to be sent in SAML Assertion. .PARAMETER Attribute9format Format of Attribute9 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute10 Name of attribute10 that needs to be sent in SAML Assertion. .PARAMETER Attribute10friendlyname User-Friendly Name of attribute10 that needs to be sent in SAML Assertion. .PARAMETER Attribute10format Format of Attribute10 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute11 Name of attribute11 that needs to be sent in SAML Assertion. .PARAMETER Attribute11friendlyname User-Friendly Name of attribute11 that needs to be sent in SAML Assertion. .PARAMETER Attribute11format Format of Attribute11 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute12 Name of attribute12 that needs to be sent in SAML Assertion. .PARAMETER Attribute12friendlyname User-Friendly Name of attribute12 that needs to be sent in SAML Assertion. .PARAMETER Attribute12format Format of Attribute12 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute13 Name of attribute13 that needs to be sent in SAML Assertion. .PARAMETER Attribute13friendlyname User-Friendly Name of attribute13 that needs to be sent in SAML Assertion. .PARAMETER Attribute13format Format of Attribute13 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute14 Name of attribute14 that needs to be sent in SAML Assertion. .PARAMETER Attribute14friendlyname User-Friendly Name of attribute14 that needs to be sent in SAML Assertion. .PARAMETER Attribute14format Format of Attribute14 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute15 Name of attribute15 that needs to be sent in SAML Assertion. .PARAMETER Attribute15friendlyname User-Friendly Name of attribute15 that needs to be sent in SAML Assertion. .PARAMETER Attribute15format Format of Attribute15 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute16 Name of attribute16 that needs to be sent in SAML Assertion. .PARAMETER Attribute16friendlyname User-Friendly Name of attribute16 that needs to be sent in SAML Assertion. .PARAMETER Attribute16format Format of Attribute16 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Encryptassertion Option to encrypt assertion when Citrix ADC IDP sends one. Possible values = ON, OFF .PARAMETER Encryptionalgorithm Algorithm to be used to encrypt SAML assertion. Possible values = DES3, AES128, AES192, AES256 .PARAMETER Samlbinding This element specifies the transport mechanism of saml messages. Possible values = REDIRECT, POST, ARTIFACT .PARAMETER Skewtime This option specifies the number of minutes on either side of current time that the assertion would be valid. For example, if skewTime is 10, then assertion would be valid from (current time - 10) min to (current time + 10) min, ie 20min in all. .PARAMETER Serviceproviderid Unique identifier of the Service Provider that sends SAML Request. Citrix ADC will ensure that the Issuer of the SAML Request matches this URI. In case of SP initiated sign-in scenarios, this value must be same as samlIssuerName configured in samlAction. .PARAMETER Signassertion Option to sign portions of assertion when Citrix ADC IDP sends one. Based on the user selection, either Assertion or Response or Both or none can be signed. Possible values = NONE, ASSERTION, RESPONSE, BOTH .PARAMETER Keytransportalg Key transport algorithm to be used in encryption of SAML assertion. Possible values = RSA-V1_5, RSA_OAEP .PARAMETER Splogouturl Endpoint on the ServiceProvider (SP) to which logout messages are to be sent. .PARAMETER Logoutbinding This element specifies the transport mechanism of saml logout messages. Possible values = REDIRECT, POST .PARAMETER Defaultauthenticationgroup This group will be part of AAA session's internal group list. This will be helpful to admin in Nfactor flow to decide right AAA configuration for Relaying Party. In authentication policy AAA.USER.IS_MEMBER_OF("<default_auth_group>") is way to use this feature. .PARAMETER Metadataurl This URL is used for obtaining samlidp metadata. .PARAMETER Metadatarefreshinterval Interval in minute for fetching metadata from specified metadata URL. .PARAMETER Signatureservice Name of the service in cloud used to sign the data. .PARAMETER Samlsigningcertversion version of the certificate in signature service used to sign the SAMLResposne that is sent to Relying Party or Service Provider after successful authentication. .PARAMETER Samlspcertversion version of the certificate in signature service used to verify the signature of the incoming AuthnRequest from a Relying Party or Service Provider. .PARAMETER Acsurlrule Expression that will be evaluated to allow Assertion Consumer Service URI coming in the SAML Request. .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationsamlidpprofile -name <string> An example how to unset authenticationsamlidpprofile configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationsamlidpprofile Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlidpprofile Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Boolean]$samlspcertname, [Boolean]$samlidpcertname, [Boolean]$assertionconsumerserviceurl, [Boolean]$sendpassword, [Boolean]$samlissuername, [Boolean]$rejectunsignedrequests, [Boolean]$signaturealg, [Boolean]$digestmethod, [Boolean]$audience, [Boolean]$nameidformat, [Boolean]$nameidexpr, [Boolean]$attribute1, [Boolean]$attribute1friendlyname, [Boolean]$attribute1format, [Boolean]$attribute2, [Boolean]$attribute2friendlyname, [Boolean]$attribute2format, [Boolean]$attribute3, [Boolean]$attribute3friendlyname, [Boolean]$attribute3format, [Boolean]$attribute4, [Boolean]$attribute4friendlyname, [Boolean]$attribute4format, [Boolean]$attribute5, [Boolean]$attribute5friendlyname, [Boolean]$attribute5format, [Boolean]$attribute6, [Boolean]$attribute6friendlyname, [Boolean]$attribute6format, [Boolean]$attribute7, [Boolean]$attribute7friendlyname, [Boolean]$attribute7format, [Boolean]$attribute8, [Boolean]$attribute8friendlyname, [Boolean]$attribute8format, [Boolean]$attribute9, [Boolean]$attribute9friendlyname, [Boolean]$attribute9format, [Boolean]$attribute10, [Boolean]$attribute10friendlyname, [Boolean]$attribute10format, [Boolean]$attribute11, [Boolean]$attribute11friendlyname, [Boolean]$attribute11format, [Boolean]$attribute12, [Boolean]$attribute12friendlyname, [Boolean]$attribute12format, [Boolean]$attribute13, [Boolean]$attribute13friendlyname, [Boolean]$attribute13format, [Boolean]$attribute14, [Boolean]$attribute14friendlyname, [Boolean]$attribute14format, [Boolean]$attribute15, [Boolean]$attribute15friendlyname, [Boolean]$attribute15format, [Boolean]$attribute16, [Boolean]$attribute16friendlyname, [Boolean]$attribute16format, [Boolean]$encryptassertion, [Boolean]$encryptionalgorithm, [Boolean]$samlbinding, [Boolean]$skewtime, [Boolean]$serviceproviderid, [Boolean]$signassertion, [Boolean]$keytransportalg, [Boolean]$splogouturl, [Boolean]$logoutbinding, [Boolean]$defaultauthenticationgroup, [Boolean]$metadataurl, [Boolean]$metadatarefreshinterval, [Boolean]$signatureservice, [Boolean]$samlsigningcertversion, [Boolean]$samlspcertversion, [Boolean]$acsurlrule ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationsamlidpprofile: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('samlspcertname') ) { $payload.Add('samlspcertname', $samlspcertname) } if ( $PSBoundParameters.ContainsKey('samlidpcertname') ) { $payload.Add('samlidpcertname', $samlidpcertname) } if ( $PSBoundParameters.ContainsKey('assertionconsumerserviceurl') ) { $payload.Add('assertionconsumerserviceurl', $assertionconsumerserviceurl) } if ( $PSBoundParameters.ContainsKey('sendpassword') ) { $payload.Add('sendpassword', $sendpassword) } if ( $PSBoundParameters.ContainsKey('samlissuername') ) { $payload.Add('samlissuername', $samlissuername) } if ( $PSBoundParameters.ContainsKey('rejectunsignedrequests') ) { $payload.Add('rejectunsignedrequests', $rejectunsignedrequests) } if ( $PSBoundParameters.ContainsKey('signaturealg') ) { $payload.Add('signaturealg', $signaturealg) } if ( $PSBoundParameters.ContainsKey('digestmethod') ) { $payload.Add('digestmethod', $digestmethod) } if ( $PSBoundParameters.ContainsKey('audience') ) { $payload.Add('audience', $audience) } if ( $PSBoundParameters.ContainsKey('nameidformat') ) { $payload.Add('nameidformat', $nameidformat) } if ( $PSBoundParameters.ContainsKey('nameidexpr') ) { $payload.Add('nameidexpr', $nameidexpr) } if ( $PSBoundParameters.ContainsKey('attribute1') ) { $payload.Add('attribute1', $attribute1) } if ( $PSBoundParameters.ContainsKey('attribute1friendlyname') ) { $payload.Add('attribute1friendlyname', $attribute1friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute1format') ) { $payload.Add('attribute1format', $attribute1format) } if ( $PSBoundParameters.ContainsKey('attribute2') ) { $payload.Add('attribute2', $attribute2) } if ( $PSBoundParameters.ContainsKey('attribute2friendlyname') ) { $payload.Add('attribute2friendlyname', $attribute2friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute2format') ) { $payload.Add('attribute2format', $attribute2format) } if ( $PSBoundParameters.ContainsKey('attribute3') ) { $payload.Add('attribute3', $attribute3) } if ( $PSBoundParameters.ContainsKey('attribute3friendlyname') ) { $payload.Add('attribute3friendlyname', $attribute3friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute3format') ) { $payload.Add('attribute3format', $attribute3format) } if ( $PSBoundParameters.ContainsKey('attribute4') ) { $payload.Add('attribute4', $attribute4) } if ( $PSBoundParameters.ContainsKey('attribute4friendlyname') ) { $payload.Add('attribute4friendlyname', $attribute4friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute4format') ) { $payload.Add('attribute4format', $attribute4format) } if ( $PSBoundParameters.ContainsKey('attribute5') ) { $payload.Add('attribute5', $attribute5) } if ( $PSBoundParameters.ContainsKey('attribute5friendlyname') ) { $payload.Add('attribute5friendlyname', $attribute5friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute5format') ) { $payload.Add('attribute5format', $attribute5format) } if ( $PSBoundParameters.ContainsKey('attribute6') ) { $payload.Add('attribute6', $attribute6) } if ( $PSBoundParameters.ContainsKey('attribute6friendlyname') ) { $payload.Add('attribute6friendlyname', $attribute6friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute6format') ) { $payload.Add('attribute6format', $attribute6format) } if ( $PSBoundParameters.ContainsKey('attribute7') ) { $payload.Add('attribute7', $attribute7) } if ( $PSBoundParameters.ContainsKey('attribute7friendlyname') ) { $payload.Add('attribute7friendlyname', $attribute7friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute7format') ) { $payload.Add('attribute7format', $attribute7format) } if ( $PSBoundParameters.ContainsKey('attribute8') ) { $payload.Add('attribute8', $attribute8) } if ( $PSBoundParameters.ContainsKey('attribute8friendlyname') ) { $payload.Add('attribute8friendlyname', $attribute8friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute8format') ) { $payload.Add('attribute8format', $attribute8format) } if ( $PSBoundParameters.ContainsKey('attribute9') ) { $payload.Add('attribute9', $attribute9) } if ( $PSBoundParameters.ContainsKey('attribute9friendlyname') ) { $payload.Add('attribute9friendlyname', $attribute9friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute9format') ) { $payload.Add('attribute9format', $attribute9format) } if ( $PSBoundParameters.ContainsKey('attribute10') ) { $payload.Add('attribute10', $attribute10) } if ( $PSBoundParameters.ContainsKey('attribute10friendlyname') ) { $payload.Add('attribute10friendlyname', $attribute10friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute10format') ) { $payload.Add('attribute10format', $attribute10format) } if ( $PSBoundParameters.ContainsKey('attribute11') ) { $payload.Add('attribute11', $attribute11) } if ( $PSBoundParameters.ContainsKey('attribute11friendlyname') ) { $payload.Add('attribute11friendlyname', $attribute11friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute11format') ) { $payload.Add('attribute11format', $attribute11format) } if ( $PSBoundParameters.ContainsKey('attribute12') ) { $payload.Add('attribute12', $attribute12) } if ( $PSBoundParameters.ContainsKey('attribute12friendlyname') ) { $payload.Add('attribute12friendlyname', $attribute12friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute12format') ) { $payload.Add('attribute12format', $attribute12format) } if ( $PSBoundParameters.ContainsKey('attribute13') ) { $payload.Add('attribute13', $attribute13) } if ( $PSBoundParameters.ContainsKey('attribute13friendlyname') ) { $payload.Add('attribute13friendlyname', $attribute13friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute13format') ) { $payload.Add('attribute13format', $attribute13format) } if ( $PSBoundParameters.ContainsKey('attribute14') ) { $payload.Add('attribute14', $attribute14) } if ( $PSBoundParameters.ContainsKey('attribute14friendlyname') ) { $payload.Add('attribute14friendlyname', $attribute14friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute14format') ) { $payload.Add('attribute14format', $attribute14format) } if ( $PSBoundParameters.ContainsKey('attribute15') ) { $payload.Add('attribute15', $attribute15) } if ( $PSBoundParameters.ContainsKey('attribute15friendlyname') ) { $payload.Add('attribute15friendlyname', $attribute15friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute15format') ) { $payload.Add('attribute15format', $attribute15format) } if ( $PSBoundParameters.ContainsKey('attribute16') ) { $payload.Add('attribute16', $attribute16) } if ( $PSBoundParameters.ContainsKey('attribute16friendlyname') ) { $payload.Add('attribute16friendlyname', $attribute16friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute16format') ) { $payload.Add('attribute16format', $attribute16format) } if ( $PSBoundParameters.ContainsKey('encryptassertion') ) { $payload.Add('encryptassertion', $encryptassertion) } if ( $PSBoundParameters.ContainsKey('encryptionalgorithm') ) { $payload.Add('encryptionalgorithm', $encryptionalgorithm) } if ( $PSBoundParameters.ContainsKey('samlbinding') ) { $payload.Add('samlbinding', $samlbinding) } if ( $PSBoundParameters.ContainsKey('skewtime') ) { $payload.Add('skewtime', $skewtime) } if ( $PSBoundParameters.ContainsKey('serviceproviderid') ) { $payload.Add('serviceproviderid', $serviceproviderid) } if ( $PSBoundParameters.ContainsKey('signassertion') ) { $payload.Add('signassertion', $signassertion) } if ( $PSBoundParameters.ContainsKey('keytransportalg') ) { $payload.Add('keytransportalg', $keytransportalg) } if ( $PSBoundParameters.ContainsKey('splogouturl') ) { $payload.Add('splogouturl', $splogouturl) } if ( $PSBoundParameters.ContainsKey('logoutbinding') ) { $payload.Add('logoutbinding', $logoutbinding) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('metadataurl') ) { $payload.Add('metadataurl', $metadataurl) } if ( $PSBoundParameters.ContainsKey('metadatarefreshinterval') ) { $payload.Add('metadatarefreshinterval', $metadatarefreshinterval) } if ( $PSBoundParameters.ContainsKey('signatureservice') ) { $payload.Add('signatureservice', $signatureservice) } if ( $PSBoundParameters.ContainsKey('samlsigningcertversion') ) { $payload.Add('samlsigningcertversion', $samlsigningcertversion) } if ( $PSBoundParameters.ContainsKey('samlspcertversion') ) { $payload.Add('samlspcertversion', $samlspcertversion) } if ( $PSBoundParameters.ContainsKey('acsurlrule') ) { $payload.Add('acsurlrule', $acsurlrule) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationsamlidpprofile -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationsamlidpprofile: Finished" } } function Invoke-ADCDeleteAuthenticationsamlidpprofile { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for AAA Saml IdentityProvider (IdP) profile resource. .PARAMETER Name Name for the new saml single sign-on profile. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationsamlidpprofile -Name <string> An example how to delete authenticationsamlidpprofile configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationsamlidpprofile Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlidpprofile/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationsamlidpprofile: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationsamlidpprofile -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationsamlidpprofile: Finished" } } function Invoke-ADCUpdateAuthenticationsamlidpprofile { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for AAA Saml IdentityProvider (IdP) profile resource. .PARAMETER Name Name for the new saml single sign-on profile. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER Samlspcertname Name of the SSL certificate of SAML Relying Party. This certificate is used to verify signature of the incoming AuthnRequest from a Relying Party or Service Provider. .PARAMETER Samlidpcertname Name of the certificate used to sign the SAMLResposne that is sent to Relying Party or Service Provider after successful authentication. .PARAMETER Assertionconsumerserviceurl URL to which the assertion is to be sent. .PARAMETER Sendpassword Option to send password in assertion. Possible values = ON, OFF .PARAMETER Samlissuername The name to be used in requests sent from Citrix ADC to IdP to uniquely identify Citrix ADC. .PARAMETER Rejectunsignedrequests Option to Reject unsigned SAML Requests. ON option denies any authentication requests that arrive without signature. Possible values = ON, OFF .PARAMETER Signaturealg Algorithm to be used to sign/verify SAML transactions. Possible values = RSA-SHA1, RSA-SHA256 .PARAMETER Digestmethod Algorithm to be used to compute/verify digest for SAML transactions. Possible values = SHA1, SHA256 .PARAMETER Audience Audience for which assertion sent by IdP is applicable. This is typically entity name or url that represents ServiceProvider. .PARAMETER Nameidformat Format of Name Identifier sent in Assertion. Possible values = Unspecified, emailAddress, X509SubjectName, WindowsDomainQualifiedName, kerberos, entity, persistent, transient .PARAMETER Nameidexpr Expression that will be evaluated to obtain NameIdentifier to be sent in assertion. .PARAMETER Attribute1 Name of attribute1 that needs to be sent in SAML Assertion. .PARAMETER Attribute1expr Expression that will be evaluated to obtain attribute1's value to be sent in Assertion. .PARAMETER Attribute1friendlyname User-Friendly Name of attribute1 that needs to be sent in SAML Assertion. .PARAMETER Attribute1format Format of Attribute1 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute2 Name of attribute2 that needs to be sent in SAML Assertion. .PARAMETER Attribute2expr Expression that will be evaluated to obtain attribute2's value to be sent in Assertion. .PARAMETER Attribute2friendlyname User-Friendly Name of attribute2 that needs to be sent in SAML Assertion. .PARAMETER Attribute2format Format of Attribute2 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute3 Name of attribute3 that needs to be sent in SAML Assertion. .PARAMETER Attribute3expr Expression that will be evaluated to obtain attribute3's value to be sent in Assertion. .PARAMETER Attribute3friendlyname User-Friendly Name of attribute3 that needs to be sent in SAML Assertion. .PARAMETER Attribute3format Format of Attribute3 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute4 Name of attribute4 that needs to be sent in SAML Assertion. .PARAMETER Attribute4expr Expression that will be evaluated to obtain attribute4's value to be sent in Assertion. .PARAMETER Attribute4friendlyname User-Friendly Name of attribute4 that needs to be sent in SAML Assertion. .PARAMETER Attribute4format Format of Attribute4 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute5 Name of attribute5 that needs to be sent in SAML Assertion. .PARAMETER Attribute5expr Expression that will be evaluated to obtain attribute5's value to be sent in Assertion. .PARAMETER Attribute5friendlyname User-Friendly Name of attribute5 that needs to be sent in SAML Assertion. .PARAMETER Attribute5format Format of Attribute5 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute6 Name of attribute6 that needs to be sent in SAML Assertion. .PARAMETER Attribute6expr Expression that will be evaluated to obtain attribute6's value to be sent in Assertion. .PARAMETER Attribute6friendlyname User-Friendly Name of attribute6 that needs to be sent in SAML Assertion. .PARAMETER Attribute6format Format of Attribute6 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute7 Name of attribute7 that needs to be sent in SAML Assertion. .PARAMETER Attribute7expr Expression that will be evaluated to obtain attribute7's value to be sent in Assertion. .PARAMETER Attribute7friendlyname User-Friendly Name of attribute7 that needs to be sent in SAML Assertion. .PARAMETER Attribute7format Format of Attribute7 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute8 Name of attribute8 that needs to be sent in SAML Assertion. .PARAMETER Attribute8expr Expression that will be evaluated to obtain attribute8's value to be sent in Assertion. .PARAMETER Attribute8friendlyname User-Friendly Name of attribute8 that needs to be sent in SAML Assertion. .PARAMETER Attribute8format Format of Attribute8 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute9 Name of attribute9 that needs to be sent in SAML Assertion. .PARAMETER Attribute9expr Expression that will be evaluated to obtain attribute9's value to be sent in Assertion. .PARAMETER Attribute9friendlyname User-Friendly Name of attribute9 that needs to be sent in SAML Assertion. .PARAMETER Attribute9format Format of Attribute9 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute10 Name of attribute10 that needs to be sent in SAML Assertion. .PARAMETER Attribute10expr Expression that will be evaluated to obtain attribute10's value to be sent in Assertion. .PARAMETER Attribute10friendlyname User-Friendly Name of attribute10 that needs to be sent in SAML Assertion. .PARAMETER Attribute10format Format of Attribute10 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute11 Name of attribute11 that needs to be sent in SAML Assertion. .PARAMETER Attribute11expr Expression that will be evaluated to obtain attribute11's value to be sent in Assertion. .PARAMETER Attribute11friendlyname User-Friendly Name of attribute11 that needs to be sent in SAML Assertion. .PARAMETER Attribute11format Format of Attribute11 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute12 Name of attribute12 that needs to be sent in SAML Assertion. .PARAMETER Attribute12expr Expression that will be evaluated to obtain attribute12's value to be sent in Assertion. .PARAMETER Attribute12friendlyname User-Friendly Name of attribute12 that needs to be sent in SAML Assertion. .PARAMETER Attribute12format Format of Attribute12 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute13 Name of attribute13 that needs to be sent in SAML Assertion. .PARAMETER Attribute13expr Expression that will be evaluated to obtain attribute13's value to be sent in Assertion. .PARAMETER Attribute13friendlyname User-Friendly Name of attribute13 that needs to be sent in SAML Assertion. .PARAMETER Attribute13format Format of Attribute13 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute14 Name of attribute14 that needs to be sent in SAML Assertion. .PARAMETER Attribute14expr Expression that will be evaluated to obtain attribute14's value to be sent in Assertion. .PARAMETER Attribute14friendlyname User-Friendly Name of attribute14 that needs to be sent in SAML Assertion. .PARAMETER Attribute14format Format of Attribute14 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute15 Name of attribute15 that needs to be sent in SAML Assertion. .PARAMETER Attribute15expr Expression that will be evaluated to obtain attribute15's value to be sent in Assertion. .PARAMETER Attribute15friendlyname User-Friendly Name of attribute15 that needs to be sent in SAML Assertion. .PARAMETER Attribute15format Format of Attribute15 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute16 Name of attribute16 that needs to be sent in SAML Assertion. .PARAMETER Attribute16expr Expression that will be evaluated to obtain attribute16's value to be sent in Assertion. .PARAMETER Attribute16friendlyname User-Friendly Name of attribute16 that needs to be sent in SAML Assertion. .PARAMETER Attribute16format Format of Attribute16 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Encryptassertion Option to encrypt assertion when Citrix ADC IDP sends one. Possible values = ON, OFF .PARAMETER Encryptionalgorithm Algorithm to be used to encrypt SAML assertion. Possible values = DES3, AES128, AES192, AES256 .PARAMETER Samlbinding This element specifies the transport mechanism of saml messages. Possible values = REDIRECT, POST, ARTIFACT .PARAMETER Skewtime This option specifies the number of minutes on either side of current time that the assertion would be valid. For example, if skewTime is 10, then assertion would be valid from (current time - 10) min to (current time + 10) min, ie 20min in all. .PARAMETER Serviceproviderid Unique identifier of the Service Provider that sends SAML Request. Citrix ADC will ensure that the Issuer of the SAML Request matches this URI. In case of SP initiated sign-in scenarios, this value must be same as samlIssuerName configured in samlAction. .PARAMETER Signassertion Option to sign portions of assertion when Citrix ADC IDP sends one. Based on the user selection, either Assertion or Response or Both or none can be signed. Possible values = NONE, ASSERTION, RESPONSE, BOTH .PARAMETER Keytransportalg Key transport algorithm to be used in encryption of SAML assertion. Possible values = RSA-V1_5, RSA_OAEP .PARAMETER Splogouturl Endpoint on the ServiceProvider (SP) to which logout messages are to be sent. .PARAMETER Logoutbinding This element specifies the transport mechanism of saml logout messages. Possible values = REDIRECT, POST .PARAMETER Defaultauthenticationgroup This group will be part of AAA session's internal group list. This will be helpful to admin in Nfactor flow to decide right AAA configuration for Relaying Party. In authentication policy AAA.USER.IS_MEMBER_OF("<default_auth_group>") is way to use this feature. .PARAMETER Metadataurl This URL is used for obtaining samlidp metadata. .PARAMETER Metadatarefreshinterval Interval in minute for fetching metadata from specified metadata URL. .PARAMETER Signatureservice Name of the service in cloud used to sign the data. .PARAMETER Samlsigningcertversion version of the certificate in signature service used to sign the SAMLResposne that is sent to Relying Party or Service Provider after successful authentication. .PARAMETER Samlspcertversion version of the certificate in signature service used to verify the signature of the incoming AuthnRequest from a Relying Party or Service Provider. .PARAMETER Acsurlrule Expression that will be evaluated to allow Assertion Consumer Service URI coming in the SAML Request. .PARAMETER PassThru Return details about the created authenticationsamlidpprofile item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationsamlidpprofile -name <string> An example how to update authenticationsamlidpprofile configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationsamlidpprofile Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlidpprofile/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Samlspcertname, [ValidateScript({ $_.Length -gt 1 })] [string]$Samlidpcertname, [ValidateScript({ $_.Length -gt 1 })] [string]$Assertionconsumerserviceurl, [ValidateSet('ON', 'OFF')] [string]$Sendpassword, [ValidateScript({ $_.Length -gt 1 })] [string]$Samlissuername, [ValidateSet('ON', 'OFF')] [string]$Rejectunsignedrequests, [ValidateSet('RSA-SHA1', 'RSA-SHA256')] [string]$Signaturealg, [ValidateSet('SHA1', 'SHA256')] [string]$Digestmethod, [string]$Audience, [ValidateSet('Unspecified', 'emailAddress', 'X509SubjectName', 'WindowsDomainQualifiedName', 'kerberos', 'entity', 'persistent', 'transient')] [string]$Nameidformat, [string]$Nameidexpr, [string]$Attribute1, [string]$Attribute1expr, [string]$Attribute1friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute1format, [string]$Attribute2, [string]$Attribute2expr, [string]$Attribute2friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute2format, [string]$Attribute3, [string]$Attribute3expr, [string]$Attribute3friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute3format, [string]$Attribute4, [string]$Attribute4expr, [string]$Attribute4friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute4format, [string]$Attribute5, [string]$Attribute5expr, [string]$Attribute5friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute5format, [string]$Attribute6, [string]$Attribute6expr, [string]$Attribute6friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute6format, [string]$Attribute7, [string]$Attribute7expr, [string]$Attribute7friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute7format, [string]$Attribute8, [string]$Attribute8expr, [string]$Attribute8friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute8format, [string]$Attribute9, [string]$Attribute9expr, [string]$Attribute9friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute9format, [string]$Attribute10, [string]$Attribute10expr, [string]$Attribute10friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute10format, [string]$Attribute11, [string]$Attribute11expr, [string]$Attribute11friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute11format, [string]$Attribute12, [string]$Attribute12expr, [string]$Attribute12friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute12format, [string]$Attribute13, [string]$Attribute13expr, [string]$Attribute13friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute13format, [string]$Attribute14, [string]$Attribute14expr, [string]$Attribute14friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute14format, [string]$Attribute15, [string]$Attribute15expr, [string]$Attribute15friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute15format, [string]$Attribute16, [string]$Attribute16expr, [string]$Attribute16friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute16format, [ValidateSet('ON', 'OFF')] [string]$Encryptassertion, [ValidateSet('DES3', 'AES128', 'AES192', 'AES256')] [string]$Encryptionalgorithm, [ValidateSet('REDIRECT', 'POST', 'ARTIFACT')] [string]$Samlbinding, [double]$Skewtime, [ValidateScript({ $_.Length -gt 1 })] [string]$Serviceproviderid, [ValidateSet('NONE', 'ASSERTION', 'RESPONSE', 'BOTH')] [string]$Signassertion, [ValidateSet('RSA-V1_5', 'RSA_OAEP')] [string]$Keytransportalg, [ValidateScript({ $_.Length -gt 1 })] [string]$Splogouturl, [ValidateSet('REDIRECT', 'POST')] [string]$Logoutbinding, [string]$Defaultauthenticationgroup, [string]$Metadataurl, [double]$Metadatarefreshinterval, [ValidateScript({ $_.Length -gt 1 })] [string]$Signatureservice, [ValidateScript({ $_.Length -gt 1 })] [string]$Samlsigningcertversion, [ValidateScript({ $_.Length -gt 1 })] [string]$Samlspcertversion, [string]$Acsurlrule, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationsamlidpprofile: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('samlspcertname') ) { $payload.Add('samlspcertname', $samlspcertname) } if ( $PSBoundParameters.ContainsKey('samlidpcertname') ) { $payload.Add('samlidpcertname', $samlidpcertname) } if ( $PSBoundParameters.ContainsKey('assertionconsumerserviceurl') ) { $payload.Add('assertionconsumerserviceurl', $assertionconsumerserviceurl) } if ( $PSBoundParameters.ContainsKey('sendpassword') ) { $payload.Add('sendpassword', $sendpassword) } if ( $PSBoundParameters.ContainsKey('samlissuername') ) { $payload.Add('samlissuername', $samlissuername) } if ( $PSBoundParameters.ContainsKey('rejectunsignedrequests') ) { $payload.Add('rejectunsignedrequests', $rejectunsignedrequests) } if ( $PSBoundParameters.ContainsKey('signaturealg') ) { $payload.Add('signaturealg', $signaturealg) } if ( $PSBoundParameters.ContainsKey('digestmethod') ) { $payload.Add('digestmethod', $digestmethod) } if ( $PSBoundParameters.ContainsKey('audience') ) { $payload.Add('audience', $audience) } if ( $PSBoundParameters.ContainsKey('nameidformat') ) { $payload.Add('nameidformat', $nameidformat) } if ( $PSBoundParameters.ContainsKey('nameidexpr') ) { $payload.Add('nameidexpr', $nameidexpr) } if ( $PSBoundParameters.ContainsKey('attribute1') ) { $payload.Add('attribute1', $attribute1) } if ( $PSBoundParameters.ContainsKey('attribute1expr') ) { $payload.Add('attribute1expr', $attribute1expr) } if ( $PSBoundParameters.ContainsKey('attribute1friendlyname') ) { $payload.Add('attribute1friendlyname', $attribute1friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute1format') ) { $payload.Add('attribute1format', $attribute1format) } if ( $PSBoundParameters.ContainsKey('attribute2') ) { $payload.Add('attribute2', $attribute2) } if ( $PSBoundParameters.ContainsKey('attribute2expr') ) { $payload.Add('attribute2expr', $attribute2expr) } if ( $PSBoundParameters.ContainsKey('attribute2friendlyname') ) { $payload.Add('attribute2friendlyname', $attribute2friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute2format') ) { $payload.Add('attribute2format', $attribute2format) } if ( $PSBoundParameters.ContainsKey('attribute3') ) { $payload.Add('attribute3', $attribute3) } if ( $PSBoundParameters.ContainsKey('attribute3expr') ) { $payload.Add('attribute3expr', $attribute3expr) } if ( $PSBoundParameters.ContainsKey('attribute3friendlyname') ) { $payload.Add('attribute3friendlyname', $attribute3friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute3format') ) { $payload.Add('attribute3format', $attribute3format) } if ( $PSBoundParameters.ContainsKey('attribute4') ) { $payload.Add('attribute4', $attribute4) } if ( $PSBoundParameters.ContainsKey('attribute4expr') ) { $payload.Add('attribute4expr', $attribute4expr) } if ( $PSBoundParameters.ContainsKey('attribute4friendlyname') ) { $payload.Add('attribute4friendlyname', $attribute4friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute4format') ) { $payload.Add('attribute4format', $attribute4format) } if ( $PSBoundParameters.ContainsKey('attribute5') ) { $payload.Add('attribute5', $attribute5) } if ( $PSBoundParameters.ContainsKey('attribute5expr') ) { $payload.Add('attribute5expr', $attribute5expr) } if ( $PSBoundParameters.ContainsKey('attribute5friendlyname') ) { $payload.Add('attribute5friendlyname', $attribute5friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute5format') ) { $payload.Add('attribute5format', $attribute5format) } if ( $PSBoundParameters.ContainsKey('attribute6') ) { $payload.Add('attribute6', $attribute6) } if ( $PSBoundParameters.ContainsKey('attribute6expr') ) { $payload.Add('attribute6expr', $attribute6expr) } if ( $PSBoundParameters.ContainsKey('attribute6friendlyname') ) { $payload.Add('attribute6friendlyname', $attribute6friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute6format') ) { $payload.Add('attribute6format', $attribute6format) } if ( $PSBoundParameters.ContainsKey('attribute7') ) { $payload.Add('attribute7', $attribute7) } if ( $PSBoundParameters.ContainsKey('attribute7expr') ) { $payload.Add('attribute7expr', $attribute7expr) } if ( $PSBoundParameters.ContainsKey('attribute7friendlyname') ) { $payload.Add('attribute7friendlyname', $attribute7friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute7format') ) { $payload.Add('attribute7format', $attribute7format) } if ( $PSBoundParameters.ContainsKey('attribute8') ) { $payload.Add('attribute8', $attribute8) } if ( $PSBoundParameters.ContainsKey('attribute8expr') ) { $payload.Add('attribute8expr', $attribute8expr) } if ( $PSBoundParameters.ContainsKey('attribute8friendlyname') ) { $payload.Add('attribute8friendlyname', $attribute8friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute8format') ) { $payload.Add('attribute8format', $attribute8format) } if ( $PSBoundParameters.ContainsKey('attribute9') ) { $payload.Add('attribute9', $attribute9) } if ( $PSBoundParameters.ContainsKey('attribute9expr') ) { $payload.Add('attribute9expr', $attribute9expr) } if ( $PSBoundParameters.ContainsKey('attribute9friendlyname') ) { $payload.Add('attribute9friendlyname', $attribute9friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute9format') ) { $payload.Add('attribute9format', $attribute9format) } if ( $PSBoundParameters.ContainsKey('attribute10') ) { $payload.Add('attribute10', $attribute10) } if ( $PSBoundParameters.ContainsKey('attribute10expr') ) { $payload.Add('attribute10expr', $attribute10expr) } if ( $PSBoundParameters.ContainsKey('attribute10friendlyname') ) { $payload.Add('attribute10friendlyname', $attribute10friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute10format') ) { $payload.Add('attribute10format', $attribute10format) } if ( $PSBoundParameters.ContainsKey('attribute11') ) { $payload.Add('attribute11', $attribute11) } if ( $PSBoundParameters.ContainsKey('attribute11expr') ) { $payload.Add('attribute11expr', $attribute11expr) } if ( $PSBoundParameters.ContainsKey('attribute11friendlyname') ) { $payload.Add('attribute11friendlyname', $attribute11friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute11format') ) { $payload.Add('attribute11format', $attribute11format) } if ( $PSBoundParameters.ContainsKey('attribute12') ) { $payload.Add('attribute12', $attribute12) } if ( $PSBoundParameters.ContainsKey('attribute12expr') ) { $payload.Add('attribute12expr', $attribute12expr) } if ( $PSBoundParameters.ContainsKey('attribute12friendlyname') ) { $payload.Add('attribute12friendlyname', $attribute12friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute12format') ) { $payload.Add('attribute12format', $attribute12format) } if ( $PSBoundParameters.ContainsKey('attribute13') ) { $payload.Add('attribute13', $attribute13) } if ( $PSBoundParameters.ContainsKey('attribute13expr') ) { $payload.Add('attribute13expr', $attribute13expr) } if ( $PSBoundParameters.ContainsKey('attribute13friendlyname') ) { $payload.Add('attribute13friendlyname', $attribute13friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute13format') ) { $payload.Add('attribute13format', $attribute13format) } if ( $PSBoundParameters.ContainsKey('attribute14') ) { $payload.Add('attribute14', $attribute14) } if ( $PSBoundParameters.ContainsKey('attribute14expr') ) { $payload.Add('attribute14expr', $attribute14expr) } if ( $PSBoundParameters.ContainsKey('attribute14friendlyname') ) { $payload.Add('attribute14friendlyname', $attribute14friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute14format') ) { $payload.Add('attribute14format', $attribute14format) } if ( $PSBoundParameters.ContainsKey('attribute15') ) { $payload.Add('attribute15', $attribute15) } if ( $PSBoundParameters.ContainsKey('attribute15expr') ) { $payload.Add('attribute15expr', $attribute15expr) } if ( $PSBoundParameters.ContainsKey('attribute15friendlyname') ) { $payload.Add('attribute15friendlyname', $attribute15friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute15format') ) { $payload.Add('attribute15format', $attribute15format) } if ( $PSBoundParameters.ContainsKey('attribute16') ) { $payload.Add('attribute16', $attribute16) } if ( $PSBoundParameters.ContainsKey('attribute16expr') ) { $payload.Add('attribute16expr', $attribute16expr) } if ( $PSBoundParameters.ContainsKey('attribute16friendlyname') ) { $payload.Add('attribute16friendlyname', $attribute16friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute16format') ) { $payload.Add('attribute16format', $attribute16format) } if ( $PSBoundParameters.ContainsKey('encryptassertion') ) { $payload.Add('encryptassertion', $encryptassertion) } if ( $PSBoundParameters.ContainsKey('encryptionalgorithm') ) { $payload.Add('encryptionalgorithm', $encryptionalgorithm) } if ( $PSBoundParameters.ContainsKey('samlbinding') ) { $payload.Add('samlbinding', $samlbinding) } if ( $PSBoundParameters.ContainsKey('skewtime') ) { $payload.Add('skewtime', $skewtime) } if ( $PSBoundParameters.ContainsKey('serviceproviderid') ) { $payload.Add('serviceproviderid', $serviceproviderid) } if ( $PSBoundParameters.ContainsKey('signassertion') ) { $payload.Add('signassertion', $signassertion) } if ( $PSBoundParameters.ContainsKey('keytransportalg') ) { $payload.Add('keytransportalg', $keytransportalg) } if ( $PSBoundParameters.ContainsKey('splogouturl') ) { $payload.Add('splogouturl', $splogouturl) } if ( $PSBoundParameters.ContainsKey('logoutbinding') ) { $payload.Add('logoutbinding', $logoutbinding) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('metadataurl') ) { $payload.Add('metadataurl', $metadataurl) } if ( $PSBoundParameters.ContainsKey('metadatarefreshinterval') ) { $payload.Add('metadatarefreshinterval', $metadatarefreshinterval) } if ( $PSBoundParameters.ContainsKey('signatureservice') ) { $payload.Add('signatureservice', $signatureservice) } if ( $PSBoundParameters.ContainsKey('samlsigningcertversion') ) { $payload.Add('samlsigningcertversion', $samlsigningcertversion) } if ( $PSBoundParameters.ContainsKey('samlspcertversion') ) { $payload.Add('samlspcertversion', $samlspcertversion) } if ( $PSBoundParameters.ContainsKey('acsurlrule') ) { $payload.Add('acsurlrule', $acsurlrule) } if ( $PSCmdlet.ShouldProcess("authenticationsamlidpprofile", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationsamlidpprofile -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationsamlidpprofile -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationsamlidpprofile: Finished" } } function Invoke-ADCAddAuthenticationsamlidpprofile { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for AAA Saml IdentityProvider (IdP) profile resource. .PARAMETER Name Name for the new saml single sign-on profile. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER Samlspcertname Name of the SSL certificate of SAML Relying Party. This certificate is used to verify signature of the incoming AuthnRequest from a Relying Party or Service Provider. .PARAMETER Samlidpcertname Name of the certificate used to sign the SAMLResposne that is sent to Relying Party or Service Provider after successful authentication. .PARAMETER Assertionconsumerserviceurl URL to which the assertion is to be sent. .PARAMETER Sendpassword Option to send password in assertion. Possible values = ON, OFF .PARAMETER Samlissuername The name to be used in requests sent from Citrix ADC to IdP to uniquely identify Citrix ADC. .PARAMETER Rejectunsignedrequests Option to Reject unsigned SAML Requests. ON option denies any authentication requests that arrive without signature. Possible values = ON, OFF .PARAMETER Signaturealg Algorithm to be used to sign/verify SAML transactions. Possible values = RSA-SHA1, RSA-SHA256 .PARAMETER Digestmethod Algorithm to be used to compute/verify digest for SAML transactions. Possible values = SHA1, SHA256 .PARAMETER Audience Audience for which assertion sent by IdP is applicable. This is typically entity name or url that represents ServiceProvider. .PARAMETER Nameidformat Format of Name Identifier sent in Assertion. Possible values = Unspecified, emailAddress, X509SubjectName, WindowsDomainQualifiedName, kerberos, entity, persistent, transient .PARAMETER Nameidexpr Expression that will be evaluated to obtain NameIdentifier to be sent in assertion. .PARAMETER Attribute1 Name of attribute1 that needs to be sent in SAML Assertion. .PARAMETER Attribute1expr Expression that will be evaluated to obtain attribute1's value to be sent in Assertion. .PARAMETER Attribute1friendlyname User-Friendly Name of attribute1 that needs to be sent in SAML Assertion. .PARAMETER Attribute1format Format of Attribute1 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute2 Name of attribute2 that needs to be sent in SAML Assertion. .PARAMETER Attribute2expr Expression that will be evaluated to obtain attribute2's value to be sent in Assertion. .PARAMETER Attribute2friendlyname User-Friendly Name of attribute2 that needs to be sent in SAML Assertion. .PARAMETER Attribute2format Format of Attribute2 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute3 Name of attribute3 that needs to be sent in SAML Assertion. .PARAMETER Attribute3expr Expression that will be evaluated to obtain attribute3's value to be sent in Assertion. .PARAMETER Attribute3friendlyname User-Friendly Name of attribute3 that needs to be sent in SAML Assertion. .PARAMETER Attribute3format Format of Attribute3 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute4 Name of attribute4 that needs to be sent in SAML Assertion. .PARAMETER Attribute4expr Expression that will be evaluated to obtain attribute4's value to be sent in Assertion. .PARAMETER Attribute4friendlyname User-Friendly Name of attribute4 that needs to be sent in SAML Assertion. .PARAMETER Attribute4format Format of Attribute4 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute5 Name of attribute5 that needs to be sent in SAML Assertion. .PARAMETER Attribute5expr Expression that will be evaluated to obtain attribute5's value to be sent in Assertion. .PARAMETER Attribute5friendlyname User-Friendly Name of attribute5 that needs to be sent in SAML Assertion. .PARAMETER Attribute5format Format of Attribute5 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute6 Name of attribute6 that needs to be sent in SAML Assertion. .PARAMETER Attribute6expr Expression that will be evaluated to obtain attribute6's value to be sent in Assertion. .PARAMETER Attribute6friendlyname User-Friendly Name of attribute6 that needs to be sent in SAML Assertion. .PARAMETER Attribute6format Format of Attribute6 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute7 Name of attribute7 that needs to be sent in SAML Assertion. .PARAMETER Attribute7expr Expression that will be evaluated to obtain attribute7's value to be sent in Assertion. .PARAMETER Attribute7friendlyname User-Friendly Name of attribute7 that needs to be sent in SAML Assertion. .PARAMETER Attribute7format Format of Attribute7 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute8 Name of attribute8 that needs to be sent in SAML Assertion. .PARAMETER Attribute8expr Expression that will be evaluated to obtain attribute8's value to be sent in Assertion. .PARAMETER Attribute8friendlyname User-Friendly Name of attribute8 that needs to be sent in SAML Assertion. .PARAMETER Attribute8format Format of Attribute8 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute9 Name of attribute9 that needs to be sent in SAML Assertion. .PARAMETER Attribute9expr Expression that will be evaluated to obtain attribute9's value to be sent in Assertion. .PARAMETER Attribute9friendlyname User-Friendly Name of attribute9 that needs to be sent in SAML Assertion. .PARAMETER Attribute9format Format of Attribute9 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute10 Name of attribute10 that needs to be sent in SAML Assertion. .PARAMETER Attribute10expr Expression that will be evaluated to obtain attribute10's value to be sent in Assertion. .PARAMETER Attribute10friendlyname User-Friendly Name of attribute10 that needs to be sent in SAML Assertion. .PARAMETER Attribute10format Format of Attribute10 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute11 Name of attribute11 that needs to be sent in SAML Assertion. .PARAMETER Attribute11expr Expression that will be evaluated to obtain attribute11's value to be sent in Assertion. .PARAMETER Attribute11friendlyname User-Friendly Name of attribute11 that needs to be sent in SAML Assertion. .PARAMETER Attribute11format Format of Attribute11 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute12 Name of attribute12 that needs to be sent in SAML Assertion. .PARAMETER Attribute12expr Expression that will be evaluated to obtain attribute12's value to be sent in Assertion. .PARAMETER Attribute12friendlyname User-Friendly Name of attribute12 that needs to be sent in SAML Assertion. .PARAMETER Attribute12format Format of Attribute12 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute13 Name of attribute13 that needs to be sent in SAML Assertion. .PARAMETER Attribute13expr Expression that will be evaluated to obtain attribute13's value to be sent in Assertion. .PARAMETER Attribute13friendlyname User-Friendly Name of attribute13 that needs to be sent in SAML Assertion. .PARAMETER Attribute13format Format of Attribute13 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute14 Name of attribute14 that needs to be sent in SAML Assertion. .PARAMETER Attribute14expr Expression that will be evaluated to obtain attribute14's value to be sent in Assertion. .PARAMETER Attribute14friendlyname User-Friendly Name of attribute14 that needs to be sent in SAML Assertion. .PARAMETER Attribute14format Format of Attribute14 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute15 Name of attribute15 that needs to be sent in SAML Assertion. .PARAMETER Attribute15expr Expression that will be evaluated to obtain attribute15's value to be sent in Assertion. .PARAMETER Attribute15friendlyname User-Friendly Name of attribute15 that needs to be sent in SAML Assertion. .PARAMETER Attribute15format Format of Attribute15 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Attribute16 Name of attribute16 that needs to be sent in SAML Assertion. .PARAMETER Attribute16expr Expression that will be evaluated to obtain attribute16's value to be sent in Assertion. .PARAMETER Attribute16friendlyname User-Friendly Name of attribute16 that needs to be sent in SAML Assertion. .PARAMETER Attribute16format Format of Attribute16 to be sent in Assertion. Possible values = URI, Basic .PARAMETER Encryptassertion Option to encrypt assertion when Citrix ADC IDP sends one. Possible values = ON, OFF .PARAMETER Encryptionalgorithm Algorithm to be used to encrypt SAML assertion. Possible values = DES3, AES128, AES192, AES256 .PARAMETER Samlbinding This element specifies the transport mechanism of saml messages. Possible values = REDIRECT, POST, ARTIFACT .PARAMETER Skewtime This option specifies the number of minutes on either side of current time that the assertion would be valid. For example, if skewTime is 10, then assertion would be valid from (current time - 10) min to (current time + 10) min, ie 20min in all. .PARAMETER Serviceproviderid Unique identifier of the Service Provider that sends SAML Request. Citrix ADC will ensure that the Issuer of the SAML Request matches this URI. In case of SP initiated sign-in scenarios, this value must be same as samlIssuerName configured in samlAction. .PARAMETER Signassertion Option to sign portions of assertion when Citrix ADC IDP sends one. Based on the user selection, either Assertion or Response or Both or none can be signed. Possible values = NONE, ASSERTION, RESPONSE, BOTH .PARAMETER Keytransportalg Key transport algorithm to be used in encryption of SAML assertion. Possible values = RSA-V1_5, RSA_OAEP .PARAMETER Splogouturl Endpoint on the ServiceProvider (SP) to which logout messages are to be sent. .PARAMETER Logoutbinding This element specifies the transport mechanism of saml logout messages. Possible values = REDIRECT, POST .PARAMETER Defaultauthenticationgroup This group will be part of AAA session's internal group list. This will be helpful to admin in Nfactor flow to decide right AAA configuration for Relaying Party. In authentication policy AAA.USER.IS_MEMBER_OF("<default_auth_group>") is way to use this feature. .PARAMETER Metadataurl This URL is used for obtaining samlidp metadata. .PARAMETER Metadatarefreshinterval Interval in minute for fetching metadata from specified metadata URL. .PARAMETER Signatureservice Name of the service in cloud used to sign the data. .PARAMETER Samlsigningcertversion version of the certificate in signature service used to sign the SAMLResposne that is sent to Relying Party or Service Provider after successful authentication. .PARAMETER Samlspcertversion version of the certificate in signature service used to verify the signature of the incoming AuthnRequest from a Relying Party or Service Provider. .PARAMETER Acsurlrule Expression that will be evaluated to allow Assertion Consumer Service URI coming in the SAML Request. .PARAMETER PassThru Return details about the created authenticationsamlidpprofile item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationsamlidpprofile -name <string> An example how to add authenticationsamlidpprofile configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationsamlidpprofile Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlidpprofile/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Samlspcertname, [ValidateScript({ $_.Length -gt 1 })] [string]$Samlidpcertname, [ValidateScript({ $_.Length -gt 1 })] [string]$Assertionconsumerserviceurl, [ValidateSet('ON', 'OFF')] [string]$Sendpassword = 'OFF', [ValidateScript({ $_.Length -gt 1 })] [string]$Samlissuername, [ValidateSet('ON', 'OFF')] [string]$Rejectunsignedrequests = 'ON', [ValidateSet('RSA-SHA1', 'RSA-SHA256')] [string]$Signaturealg = 'RSA-SHA256', [ValidateSet('SHA1', 'SHA256')] [string]$Digestmethod = 'SHA256', [string]$Audience, [ValidateSet('Unspecified', 'emailAddress', 'X509SubjectName', 'WindowsDomainQualifiedName', 'kerberos', 'entity', 'persistent', 'transient')] [string]$Nameidformat = 'transient', [string]$Nameidexpr, [string]$Attribute1, [string]$Attribute1expr, [string]$Attribute1friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute1format, [string]$Attribute2, [string]$Attribute2expr, [string]$Attribute2friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute2format, [string]$Attribute3, [string]$Attribute3expr, [string]$Attribute3friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute3format, [string]$Attribute4, [string]$Attribute4expr, [string]$Attribute4friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute4format, [string]$Attribute5, [string]$Attribute5expr, [string]$Attribute5friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute5format, [string]$Attribute6, [string]$Attribute6expr, [string]$Attribute6friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute6format, [string]$Attribute7, [string]$Attribute7expr, [string]$Attribute7friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute7format, [string]$Attribute8, [string]$Attribute8expr, [string]$Attribute8friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute8format, [string]$Attribute9, [string]$Attribute9expr, [string]$Attribute9friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute9format, [string]$Attribute10, [string]$Attribute10expr, [string]$Attribute10friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute10format, [string]$Attribute11, [string]$Attribute11expr, [string]$Attribute11friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute11format, [string]$Attribute12, [string]$Attribute12expr, [string]$Attribute12friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute12format, [string]$Attribute13, [string]$Attribute13expr, [string]$Attribute13friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute13format, [string]$Attribute14, [string]$Attribute14expr, [string]$Attribute14friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute14format, [string]$Attribute15, [string]$Attribute15expr, [string]$Attribute15friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute15format, [string]$Attribute16, [string]$Attribute16expr, [string]$Attribute16friendlyname, [ValidateSet('URI', 'Basic')] [string]$Attribute16format, [ValidateSet('ON', 'OFF')] [string]$Encryptassertion = 'OFF', [ValidateSet('DES3', 'AES128', 'AES192', 'AES256')] [string]$Encryptionalgorithm = 'AES256', [ValidateSet('REDIRECT', 'POST', 'ARTIFACT')] [string]$Samlbinding = 'POST', [double]$Skewtime = '5', [ValidateScript({ $_.Length -gt 1 })] [string]$Serviceproviderid, [ValidateSet('NONE', 'ASSERTION', 'RESPONSE', 'BOTH')] [string]$Signassertion = 'ASSERTION', [ValidateSet('RSA-V1_5', 'RSA_OAEP')] [string]$Keytransportalg = 'RSA_OAEP', [ValidateScript({ $_.Length -gt 1 })] [string]$Splogouturl, [ValidateSet('REDIRECT', 'POST')] [string]$Logoutbinding = 'POST', [string]$Defaultauthenticationgroup, [string]$Metadataurl, [double]$Metadatarefreshinterval = '3600', [ValidateScript({ $_.Length -gt 1 })] [string]$Signatureservice, [ValidateScript({ $_.Length -gt 1 })] [string]$Samlsigningcertversion, [ValidateScript({ $_.Length -gt 1 })] [string]$Samlspcertversion, [string]$Acsurlrule, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationsamlidpprofile: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('samlspcertname') ) { $payload.Add('samlspcertname', $samlspcertname) } if ( $PSBoundParameters.ContainsKey('samlidpcertname') ) { $payload.Add('samlidpcertname', $samlidpcertname) } if ( $PSBoundParameters.ContainsKey('assertionconsumerserviceurl') ) { $payload.Add('assertionconsumerserviceurl', $assertionconsumerserviceurl) } if ( $PSBoundParameters.ContainsKey('sendpassword') ) { $payload.Add('sendpassword', $sendpassword) } if ( $PSBoundParameters.ContainsKey('samlissuername') ) { $payload.Add('samlissuername', $samlissuername) } if ( $PSBoundParameters.ContainsKey('rejectunsignedrequests') ) { $payload.Add('rejectunsignedrequests', $rejectunsignedrequests) } if ( $PSBoundParameters.ContainsKey('signaturealg') ) { $payload.Add('signaturealg', $signaturealg) } if ( $PSBoundParameters.ContainsKey('digestmethod') ) { $payload.Add('digestmethod', $digestmethod) } if ( $PSBoundParameters.ContainsKey('audience') ) { $payload.Add('audience', $audience) } if ( $PSBoundParameters.ContainsKey('nameidformat') ) { $payload.Add('nameidformat', $nameidformat) } if ( $PSBoundParameters.ContainsKey('nameidexpr') ) { $payload.Add('nameidexpr', $nameidexpr) } if ( $PSBoundParameters.ContainsKey('attribute1') ) { $payload.Add('attribute1', $attribute1) } if ( $PSBoundParameters.ContainsKey('attribute1expr') ) { $payload.Add('attribute1expr', $attribute1expr) } if ( $PSBoundParameters.ContainsKey('attribute1friendlyname') ) { $payload.Add('attribute1friendlyname', $attribute1friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute1format') ) { $payload.Add('attribute1format', $attribute1format) } if ( $PSBoundParameters.ContainsKey('attribute2') ) { $payload.Add('attribute2', $attribute2) } if ( $PSBoundParameters.ContainsKey('attribute2expr') ) { $payload.Add('attribute2expr', $attribute2expr) } if ( $PSBoundParameters.ContainsKey('attribute2friendlyname') ) { $payload.Add('attribute2friendlyname', $attribute2friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute2format') ) { $payload.Add('attribute2format', $attribute2format) } if ( $PSBoundParameters.ContainsKey('attribute3') ) { $payload.Add('attribute3', $attribute3) } if ( $PSBoundParameters.ContainsKey('attribute3expr') ) { $payload.Add('attribute3expr', $attribute3expr) } if ( $PSBoundParameters.ContainsKey('attribute3friendlyname') ) { $payload.Add('attribute3friendlyname', $attribute3friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute3format') ) { $payload.Add('attribute3format', $attribute3format) } if ( $PSBoundParameters.ContainsKey('attribute4') ) { $payload.Add('attribute4', $attribute4) } if ( $PSBoundParameters.ContainsKey('attribute4expr') ) { $payload.Add('attribute4expr', $attribute4expr) } if ( $PSBoundParameters.ContainsKey('attribute4friendlyname') ) { $payload.Add('attribute4friendlyname', $attribute4friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute4format') ) { $payload.Add('attribute4format', $attribute4format) } if ( $PSBoundParameters.ContainsKey('attribute5') ) { $payload.Add('attribute5', $attribute5) } if ( $PSBoundParameters.ContainsKey('attribute5expr') ) { $payload.Add('attribute5expr', $attribute5expr) } if ( $PSBoundParameters.ContainsKey('attribute5friendlyname') ) { $payload.Add('attribute5friendlyname', $attribute5friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute5format') ) { $payload.Add('attribute5format', $attribute5format) } if ( $PSBoundParameters.ContainsKey('attribute6') ) { $payload.Add('attribute6', $attribute6) } if ( $PSBoundParameters.ContainsKey('attribute6expr') ) { $payload.Add('attribute6expr', $attribute6expr) } if ( $PSBoundParameters.ContainsKey('attribute6friendlyname') ) { $payload.Add('attribute6friendlyname', $attribute6friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute6format') ) { $payload.Add('attribute6format', $attribute6format) } if ( $PSBoundParameters.ContainsKey('attribute7') ) { $payload.Add('attribute7', $attribute7) } if ( $PSBoundParameters.ContainsKey('attribute7expr') ) { $payload.Add('attribute7expr', $attribute7expr) } if ( $PSBoundParameters.ContainsKey('attribute7friendlyname') ) { $payload.Add('attribute7friendlyname', $attribute7friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute7format') ) { $payload.Add('attribute7format', $attribute7format) } if ( $PSBoundParameters.ContainsKey('attribute8') ) { $payload.Add('attribute8', $attribute8) } if ( $PSBoundParameters.ContainsKey('attribute8expr') ) { $payload.Add('attribute8expr', $attribute8expr) } if ( $PSBoundParameters.ContainsKey('attribute8friendlyname') ) { $payload.Add('attribute8friendlyname', $attribute8friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute8format') ) { $payload.Add('attribute8format', $attribute8format) } if ( $PSBoundParameters.ContainsKey('attribute9') ) { $payload.Add('attribute9', $attribute9) } if ( $PSBoundParameters.ContainsKey('attribute9expr') ) { $payload.Add('attribute9expr', $attribute9expr) } if ( $PSBoundParameters.ContainsKey('attribute9friendlyname') ) { $payload.Add('attribute9friendlyname', $attribute9friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute9format') ) { $payload.Add('attribute9format', $attribute9format) } if ( $PSBoundParameters.ContainsKey('attribute10') ) { $payload.Add('attribute10', $attribute10) } if ( $PSBoundParameters.ContainsKey('attribute10expr') ) { $payload.Add('attribute10expr', $attribute10expr) } if ( $PSBoundParameters.ContainsKey('attribute10friendlyname') ) { $payload.Add('attribute10friendlyname', $attribute10friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute10format') ) { $payload.Add('attribute10format', $attribute10format) } if ( $PSBoundParameters.ContainsKey('attribute11') ) { $payload.Add('attribute11', $attribute11) } if ( $PSBoundParameters.ContainsKey('attribute11expr') ) { $payload.Add('attribute11expr', $attribute11expr) } if ( $PSBoundParameters.ContainsKey('attribute11friendlyname') ) { $payload.Add('attribute11friendlyname', $attribute11friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute11format') ) { $payload.Add('attribute11format', $attribute11format) } if ( $PSBoundParameters.ContainsKey('attribute12') ) { $payload.Add('attribute12', $attribute12) } if ( $PSBoundParameters.ContainsKey('attribute12expr') ) { $payload.Add('attribute12expr', $attribute12expr) } if ( $PSBoundParameters.ContainsKey('attribute12friendlyname') ) { $payload.Add('attribute12friendlyname', $attribute12friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute12format') ) { $payload.Add('attribute12format', $attribute12format) } if ( $PSBoundParameters.ContainsKey('attribute13') ) { $payload.Add('attribute13', $attribute13) } if ( $PSBoundParameters.ContainsKey('attribute13expr') ) { $payload.Add('attribute13expr', $attribute13expr) } if ( $PSBoundParameters.ContainsKey('attribute13friendlyname') ) { $payload.Add('attribute13friendlyname', $attribute13friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute13format') ) { $payload.Add('attribute13format', $attribute13format) } if ( $PSBoundParameters.ContainsKey('attribute14') ) { $payload.Add('attribute14', $attribute14) } if ( $PSBoundParameters.ContainsKey('attribute14expr') ) { $payload.Add('attribute14expr', $attribute14expr) } if ( $PSBoundParameters.ContainsKey('attribute14friendlyname') ) { $payload.Add('attribute14friendlyname', $attribute14friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute14format') ) { $payload.Add('attribute14format', $attribute14format) } if ( $PSBoundParameters.ContainsKey('attribute15') ) { $payload.Add('attribute15', $attribute15) } if ( $PSBoundParameters.ContainsKey('attribute15expr') ) { $payload.Add('attribute15expr', $attribute15expr) } if ( $PSBoundParameters.ContainsKey('attribute15friendlyname') ) { $payload.Add('attribute15friendlyname', $attribute15friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute15format') ) { $payload.Add('attribute15format', $attribute15format) } if ( $PSBoundParameters.ContainsKey('attribute16') ) { $payload.Add('attribute16', $attribute16) } if ( $PSBoundParameters.ContainsKey('attribute16expr') ) { $payload.Add('attribute16expr', $attribute16expr) } if ( $PSBoundParameters.ContainsKey('attribute16friendlyname') ) { $payload.Add('attribute16friendlyname', $attribute16friendlyname) } if ( $PSBoundParameters.ContainsKey('attribute16format') ) { $payload.Add('attribute16format', $attribute16format) } if ( $PSBoundParameters.ContainsKey('encryptassertion') ) { $payload.Add('encryptassertion', $encryptassertion) } if ( $PSBoundParameters.ContainsKey('encryptionalgorithm') ) { $payload.Add('encryptionalgorithm', $encryptionalgorithm) } if ( $PSBoundParameters.ContainsKey('samlbinding') ) { $payload.Add('samlbinding', $samlbinding) } if ( $PSBoundParameters.ContainsKey('skewtime') ) { $payload.Add('skewtime', $skewtime) } if ( $PSBoundParameters.ContainsKey('serviceproviderid') ) { $payload.Add('serviceproviderid', $serviceproviderid) } if ( $PSBoundParameters.ContainsKey('signassertion') ) { $payload.Add('signassertion', $signassertion) } if ( $PSBoundParameters.ContainsKey('keytransportalg') ) { $payload.Add('keytransportalg', $keytransportalg) } if ( $PSBoundParameters.ContainsKey('splogouturl') ) { $payload.Add('splogouturl', $splogouturl) } if ( $PSBoundParameters.ContainsKey('logoutbinding') ) { $payload.Add('logoutbinding', $logoutbinding) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('metadataurl') ) { $payload.Add('metadataurl', $metadataurl) } if ( $PSBoundParameters.ContainsKey('metadatarefreshinterval') ) { $payload.Add('metadatarefreshinterval', $metadatarefreshinterval) } if ( $PSBoundParameters.ContainsKey('signatureservice') ) { $payload.Add('signatureservice', $signatureservice) } if ( $PSBoundParameters.ContainsKey('samlsigningcertversion') ) { $payload.Add('samlsigningcertversion', $samlsigningcertversion) } if ( $PSBoundParameters.ContainsKey('samlspcertversion') ) { $payload.Add('samlspcertversion', $samlspcertversion) } if ( $PSBoundParameters.ContainsKey('acsurlrule') ) { $payload.Add('acsurlrule', $acsurlrule) } if ( $PSCmdlet.ShouldProcess("authenticationsamlidpprofile", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationsamlidpprofile -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationsamlidpprofile -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationsamlidpprofile: Finished" } } function Invoke-ADCGetAuthenticationsamlidpprofile { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for AAA Saml IdentityProvider (IdP) profile resource. .PARAMETER Name Name for the new saml single sign-on profile. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after an action is created. .PARAMETER GetAll Retrieve all authenticationsamlidpprofile object(s). .PARAMETER Count If specified, the count of the authenticationsamlidpprofile object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidpprofile Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidpprofile -GetAll Get all authenticationsamlidpprofile data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidpprofile -Count Get the number of authenticationsamlidpprofile objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidpprofile -name <string> Get authenticationsamlidpprofile object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlidpprofile -Filter @{ 'name'='<value>' } Get authenticationsamlidpprofile data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationsamlidpprofile Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlidpprofile/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationsamlidpprofile: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationsamlidpprofile objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidpprofile -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationsamlidpprofile objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidpprofile -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationsamlidpprofile objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidpprofile -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationsamlidpprofile configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidpprofile -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationsamlidpprofile configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlidpprofile -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationsamlidpprofile: Ended" } } function Invoke-ADCDeleteAuthenticationsamlpolicy { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for AAA Saml policy resource. .PARAMETER Name Name for the SAML policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after SAML policy is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationsamlpolicy -Name <string> An example how to delete authenticationsamlpolicy configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationsamlpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlpolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationsamlpolicy: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationsamlpolicy -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationsamlpolicy: Finished" } } function Invoke-ADCUpdateAuthenticationsamlpolicy { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for AAA Saml policy resource. .PARAMETER Name Name for the SAML policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after SAML policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to determine whether to attempt to authenticate the user with the SAML server. .PARAMETER Reqaction Name of the SAML authentication action to be performed if the policy matches. .PARAMETER PassThru Return details about the created authenticationsamlpolicy item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationsamlpolicy -name <string> An example how to update authenticationsamlpolicy configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationsamlpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlpolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Rule, [ValidateScript({ $_.Length -gt 1 })] [string]$Reqaction, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationsamlpolicy: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('rule') ) { $payload.Add('rule', $rule) } if ( $PSBoundParameters.ContainsKey('reqaction') ) { $payload.Add('reqaction', $reqaction) } if ( $PSCmdlet.ShouldProcess("authenticationsamlpolicy", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationsamlpolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationsamlpolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationsamlpolicy: Finished" } } function Invoke-ADCUnsetAuthenticationsamlpolicy { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for AAA Saml policy resource. .PARAMETER Name Name for the SAML policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after SAML policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to determine whether to attempt to authenticate the user with the SAML server. .PARAMETER Reqaction Name of the SAML authentication action to be performed if the policy matches. .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationsamlpolicy -name <string> An example how to unset authenticationsamlpolicy configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationsamlpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlpolicy Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Boolean]$rule, [Boolean]$reqaction ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationsamlpolicy: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('rule') ) { $payload.Add('rule', $rule) } if ( $PSBoundParameters.ContainsKey('reqaction') ) { $payload.Add('reqaction', $reqaction) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationsamlpolicy -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationsamlpolicy: Finished" } } function Invoke-ADCAddAuthenticationsamlpolicy { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for AAA Saml policy resource. .PARAMETER Name Name for the SAML policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after SAML policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to determine whether to attempt to authenticate the user with the SAML server. .PARAMETER Reqaction Name of the SAML authentication action to be performed if the policy matches. .PARAMETER PassThru Return details about the created authenticationsamlpolicy item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationsamlpolicy -name <string> -rule <string> -reqaction <string> An example how to add authenticationsamlpolicy configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationsamlpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlpolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Rule, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Reqaction, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationsamlpolicy: Starting" } process { try { $payload = @{ name = $name rule = $rule reqaction = $reqaction } if ( $PSCmdlet.ShouldProcess("authenticationsamlpolicy", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationsamlpolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationsamlpolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationsamlpolicy: Finished" } } function Invoke-ADCGetAuthenticationsamlpolicy { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for AAA Saml policy resource. .PARAMETER Name Name for the SAML policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after SAML policy is created. .PARAMETER GetAll Retrieve all authenticationsamlpolicy object(s). .PARAMETER Count If specified, the count of the authenticationsamlpolicy object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicy Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicy -GetAll Get all authenticationsamlpolicy data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicy -Count Get the number of authenticationsamlpolicy objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicy -name <string> Get authenticationsamlpolicy object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicy -Filter @{ 'name'='<value>' } Get authenticationsamlpolicy data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationsamlpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlpolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationsamlpolicy: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationsamlpolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationsamlpolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationsamlpolicy objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationsamlpolicy configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationsamlpolicy configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationsamlpolicy: Ended" } } function Invoke-ADCGetAuthenticationsamlpolicyauthenticationvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationvserver that can be bound to authenticationsamlpolicy. .PARAMETER Name Name of the SAML policy. .PARAMETER GetAll Retrieve all authenticationsamlpolicy_authenticationvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationsamlpolicy_authenticationvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicyauthenticationvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicyauthenticationvserverbinding -GetAll Get all authenticationsamlpolicy_authenticationvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicyauthenticationvserverbinding -Count Get the number of authenticationsamlpolicy_authenticationvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicyauthenticationvserverbinding -name <string> Get authenticationsamlpolicy_authenticationvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicyauthenticationvserverbinding -Filter @{ 'name'='<value>' } Get authenticationsamlpolicy_authenticationvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationsamlpolicyauthenticationvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlpolicy_authenticationvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationsamlpolicyauthenticationvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationsamlpolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationsamlpolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationsamlpolicy_authenticationvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationsamlpolicy_authenticationvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationsamlpolicy_authenticationvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationsamlpolicyauthenticationvserverbinding: Ended" } } function Invoke-ADCGetAuthenticationsamlpolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object which returns the resources bound to authenticationsamlpolicy. .PARAMETER Name Name of the SAML policy. .PARAMETER GetAll Retrieve all authenticationsamlpolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationsamlpolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicybinding -GetAll Get all authenticationsamlpolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicybinding -name <string> Get authenticationsamlpolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicybinding -Filter @{ 'name'='<value>' } Get authenticationsamlpolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationsamlpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationsamlpolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationsamlpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationsamlpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationsamlpolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationsamlpolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationsamlpolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationsamlpolicybinding: Ended" } } function Invoke-ADCGetAuthenticationsamlpolicyvpnglobalbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the vpnglobal that can be bound to authenticationsamlpolicy. .PARAMETER Name Name of the SAML policy. .PARAMETER GetAll Retrieve all authenticationsamlpolicy_vpnglobal_binding object(s). .PARAMETER Count If specified, the count of the authenticationsamlpolicy_vpnglobal_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicyvpnglobalbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicyvpnglobalbinding -GetAll Get all authenticationsamlpolicy_vpnglobal_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicyvpnglobalbinding -Count Get the number of authenticationsamlpolicy_vpnglobal_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicyvpnglobalbinding -name <string> Get authenticationsamlpolicy_vpnglobal_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicyvpnglobalbinding -Filter @{ 'name'='<value>' } Get authenticationsamlpolicy_vpnglobal_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationsamlpolicyvpnglobalbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlpolicy_vpnglobal_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationsamlpolicyvpnglobalbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationsamlpolicy_vpnglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy_vpnglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationsamlpolicy_vpnglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy_vpnglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationsamlpolicy_vpnglobal_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy_vpnglobal_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationsamlpolicy_vpnglobal_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy_vpnglobal_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationsamlpolicy_vpnglobal_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy_vpnglobal_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationsamlpolicyvpnglobalbinding: Ended" } } function Invoke-ADCGetAuthenticationsamlpolicyvpnvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the vpnvserver that can be bound to authenticationsamlpolicy. .PARAMETER Name Name of the SAML policy. .PARAMETER GetAll Retrieve all authenticationsamlpolicy_vpnvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationsamlpolicy_vpnvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicyvpnvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicyvpnvserverbinding -GetAll Get all authenticationsamlpolicy_vpnvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicyvpnvserverbinding -Count Get the number of authenticationsamlpolicy_vpnvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicyvpnvserverbinding -name <string> Get authenticationsamlpolicy_vpnvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationsamlpolicyvpnvserverbinding -Filter @{ 'name'='<value>' } Get authenticationsamlpolicy_vpnvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationsamlpolicyvpnvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationsamlpolicy_vpnvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationsamlpolicyvpnvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationsamlpolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationsamlpolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationsamlpolicy_vpnvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy_vpnvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationsamlpolicy_vpnvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy_vpnvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationsamlpolicy_vpnvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationsamlpolicy_vpnvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationsamlpolicyvpnvserverbinding: Ended" } } function Invoke-ADCAddAuthenticationstorefrontauthaction { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for Storefront authentication action resource. .PARAMETER Name Name for the Storefront Authentication action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the profile is created. .PARAMETER Serverurl URL of the Storefront server. This is the FQDN of the Storefront server. example: https://storefront.com/. Authentication endpoints are learned dynamically by Gateway. .PARAMETER Domain Domain of the server that is used for authentication. If users enter name without domain, this parameter is added to username in the authentication request to server. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER PassThru Return details about the created authenticationstorefrontauthaction item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationstorefrontauthaction -name <string> -serverurl <string> An example how to add authenticationstorefrontauthaction configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationstorefrontauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationstorefrontauthaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(Mandatory)] [string]$Serverurl, [string]$Domain, [string]$Defaultauthenticationgroup, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationstorefrontauthaction: Starting" } process { try { $payload = @{ name = $name serverurl = $serverurl } if ( $PSBoundParameters.ContainsKey('domain') ) { $payload.Add('domain', $domain) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSCmdlet.ShouldProcess("authenticationstorefrontauthaction", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationstorefrontauthaction -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationstorefrontauthaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationstorefrontauthaction: Finished" } } function Invoke-ADCDeleteAuthenticationstorefrontauthaction { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for Storefront authentication action resource. .PARAMETER Name Name for the Storefront Authentication action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the profile is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationstorefrontauthaction -Name <string> An example how to delete authenticationstorefrontauthaction configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationstorefrontauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationstorefrontauthaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationstorefrontauthaction: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationstorefrontauthaction -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationstorefrontauthaction: Finished" } } function Invoke-ADCUpdateAuthenticationstorefrontauthaction { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for Storefront authentication action resource. .PARAMETER Name Name for the Storefront Authentication action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the profile is created. .PARAMETER Serverurl URL of the Storefront server. This is the FQDN of the Storefront server. example: https://storefront.com/. Authentication endpoints are learned dynamically by Gateway. .PARAMETER Domain Domain of the server that is used for authentication. If users enter name without domain, this parameter is added to username in the authentication request to server. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER PassThru Return details about the created authenticationstorefrontauthaction item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationstorefrontauthaction -name <string> An example how to update authenticationstorefrontauthaction configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationstorefrontauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationstorefrontauthaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Serverurl, [string]$Domain, [string]$Defaultauthenticationgroup, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationstorefrontauthaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('serverurl') ) { $payload.Add('serverurl', $serverurl) } if ( $PSBoundParameters.ContainsKey('domain') ) { $payload.Add('domain', $domain) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSCmdlet.ShouldProcess("authenticationstorefrontauthaction", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationstorefrontauthaction -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationstorefrontauthaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationstorefrontauthaction: Finished" } } function Invoke-ADCUnsetAuthenticationstorefrontauthaction { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for Storefront authentication action resource. .PARAMETER Name Name for the Storefront Authentication action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the profile is created. .PARAMETER Domain Domain of the server that is used for authentication. If users enter name without domain, this parameter is added to username in the authentication request to server. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationstorefrontauthaction -name <string> An example how to unset authenticationstorefrontauthaction configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationstorefrontauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationstorefrontauthaction Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Boolean]$domain, [Boolean]$defaultauthenticationgroup ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationstorefrontauthaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('domain') ) { $payload.Add('domain', $domain) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationstorefrontauthaction -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationstorefrontauthaction: Finished" } } function Invoke-ADCGetAuthenticationstorefrontauthaction { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for Storefront authentication action resource. .PARAMETER Name Name for the Storefront Authentication action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the profile is created. .PARAMETER GetAll Retrieve all authenticationstorefrontauthaction object(s). .PARAMETER Count If specified, the count of the authenticationstorefrontauthaction object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationstorefrontauthaction Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationstorefrontauthaction -GetAll Get all authenticationstorefrontauthaction data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationstorefrontauthaction -Count Get the number of authenticationstorefrontauthaction objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationstorefrontauthaction -name <string> Get authenticationstorefrontauthaction object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationstorefrontauthaction -Filter @{ 'name'='<value>' } Get authenticationstorefrontauthaction data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationstorefrontauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationstorefrontauthaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationstorefrontauthaction: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationstorefrontauthaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationstorefrontauthaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationstorefrontauthaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationstorefrontauthaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationstorefrontauthaction objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationstorefrontauthaction -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationstorefrontauthaction configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationstorefrontauthaction -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationstorefrontauthaction configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationstorefrontauthaction -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationstorefrontauthaction: Ended" } } function Invoke-ADCUnsetAuthenticationtacacsaction { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for TACACS action resource. .PARAMETER Name Name for the TACACS+ profile (action). Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after TACACS profile is created. .PARAMETER Serverip IP address assigned to the TACACS+ server. .PARAMETER Serverport Port number on which the TACACS+ server listens for connections. .PARAMETER Authtimeout Number of seconds the Citrix ADC waits for a response from the TACACS+ server. .PARAMETER Tacacssecret Key shared between the TACACS+ server and the Citrix ADC. Required for allowing the Citrix ADC to communicate with the TACACS+ server. .PARAMETER Authorization Use streaming authorization on the TACACS+ server. Possible values = ON, OFF .PARAMETER Accounting Whether the TACACS+ server is currently accepting accounting messages. Possible values = ON, OFF .PARAMETER Auditfailedcmds The state of the TACACS+ server that will receive accounting messages. Possible values = ON, OFF .PARAMETER Groupattrname TACACS+ group attribute name. Used for group extraction on the TACACS+ server. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER Attribute1 Name of the custom attribute to be extracted from server and stored at index '1' (where '1' changes for each attribute). .PARAMETER Attribute2 Name of the custom attribute to be extracted from server and stored at index '2' (where '2' changes for each attribute). .PARAMETER Attribute3 Name of the custom attribute to be extracted from server and stored at index '3' (where '3' changes for each attribute). .PARAMETER Attribute4 Name of the custom attribute to be extracted from server and stored at index '4' (where '4' changes for each attribute). .PARAMETER Attribute5 Name of the custom attribute to be extracted from server and stored at index '5' (where '5' changes for each attribute). .PARAMETER Attribute6 Name of the custom attribute to be extracted from server and stored at index '6' (where '6' changes for each attribute). .PARAMETER Attribute7 Name of the custom attribute to be extracted from server and stored at index '7' (where '7' changes for each attribute). .PARAMETER Attribute8 Name of the custom attribute to be extracted from server and stored at index '8' (where '8' changes for each attribute). .PARAMETER Attribute9 Name of the custom attribute to be extracted from server and stored at index '9' (where '9' changes for each attribute). .PARAMETER Attribute10 Name of the custom attribute to be extracted from server and stored at index '10' (where '10' changes for each attribute). .PARAMETER Attribute11 Name of the custom attribute to be extracted from server and stored at index '11' (where '11' changes for each attribute). .PARAMETER Attribute12 Name of the custom attribute to be extracted from server and stored at index '12' (where '12' changes for each attribute). .PARAMETER Attribute13 Name of the custom attribute to be extracted from server and stored at index '13' (where '13' changes for each attribute). .PARAMETER Attribute14 Name of the custom attribute to be extracted from server and stored at index '14' (where '14' changes for each attribute). .PARAMETER Attribute15 Name of the custom attribute to be extracted from server and stored at index '15' (where '15' changes for each attribute). .PARAMETER Attribute16 Name of the custom attribute to be extracted from server and stored at index '16' (where '16' changes for each attribute). .PARAMETER Attributes List of attribute names separated by ',' which needs to be fetched from tacacs server. Note that preceeding and trailing spaces will be removed. Attribute name can be 127 bytes and total length of this string should not cross 2047 bytes. These attributes have multi-value support separated by ',' and stored as key-value pair in AAA session. .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationtacacsaction -name <string> An example how to unset authenticationtacacsaction configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationtacacsaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationtacacsaction Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Boolean]$serverip, [Boolean]$serverport, [Boolean]$authtimeout, [Boolean]$tacacssecret, [Boolean]$authorization, [Boolean]$accounting, [Boolean]$auditfailedcmds, [Boolean]$groupattrname, [Boolean]$defaultauthenticationgroup, [Boolean]$attribute1, [Boolean]$attribute2, [Boolean]$attribute3, [Boolean]$attribute4, [Boolean]$attribute5, [Boolean]$attribute6, [Boolean]$attribute7, [Boolean]$attribute8, [Boolean]$attribute9, [Boolean]$attribute10, [Boolean]$attribute11, [Boolean]$attribute12, [Boolean]$attribute13, [Boolean]$attribute14, [Boolean]$attribute15, [Boolean]$attribute16, [Boolean]$attributes ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationtacacsaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('serverip') ) { $payload.Add('serverip', $serverip) } if ( $PSBoundParameters.ContainsKey('serverport') ) { $payload.Add('serverport', $serverport) } if ( $PSBoundParameters.ContainsKey('authtimeout') ) { $payload.Add('authtimeout', $authtimeout) } if ( $PSBoundParameters.ContainsKey('tacacssecret') ) { $payload.Add('tacacssecret', $tacacssecret) } if ( $PSBoundParameters.ContainsKey('authorization') ) { $payload.Add('authorization', $authorization) } if ( $PSBoundParameters.ContainsKey('accounting') ) { $payload.Add('accounting', $accounting) } if ( $PSBoundParameters.ContainsKey('auditfailedcmds') ) { $payload.Add('auditfailedcmds', $auditfailedcmds) } if ( $PSBoundParameters.ContainsKey('groupattrname') ) { $payload.Add('groupattrname', $groupattrname) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('attribute1') ) { $payload.Add('attribute1', $attribute1) } if ( $PSBoundParameters.ContainsKey('attribute2') ) { $payload.Add('attribute2', $attribute2) } if ( $PSBoundParameters.ContainsKey('attribute3') ) { $payload.Add('attribute3', $attribute3) } if ( $PSBoundParameters.ContainsKey('attribute4') ) { $payload.Add('attribute4', $attribute4) } if ( $PSBoundParameters.ContainsKey('attribute5') ) { $payload.Add('attribute5', $attribute5) } if ( $PSBoundParameters.ContainsKey('attribute6') ) { $payload.Add('attribute6', $attribute6) } if ( $PSBoundParameters.ContainsKey('attribute7') ) { $payload.Add('attribute7', $attribute7) } if ( $PSBoundParameters.ContainsKey('attribute8') ) { $payload.Add('attribute8', $attribute8) } if ( $PSBoundParameters.ContainsKey('attribute9') ) { $payload.Add('attribute9', $attribute9) } if ( $PSBoundParameters.ContainsKey('attribute10') ) { $payload.Add('attribute10', $attribute10) } if ( $PSBoundParameters.ContainsKey('attribute11') ) { $payload.Add('attribute11', $attribute11) } if ( $PSBoundParameters.ContainsKey('attribute12') ) { $payload.Add('attribute12', $attribute12) } if ( $PSBoundParameters.ContainsKey('attribute13') ) { $payload.Add('attribute13', $attribute13) } if ( $PSBoundParameters.ContainsKey('attribute14') ) { $payload.Add('attribute14', $attribute14) } if ( $PSBoundParameters.ContainsKey('attribute15') ) { $payload.Add('attribute15', $attribute15) } if ( $PSBoundParameters.ContainsKey('attribute16') ) { $payload.Add('attribute16', $attribute16) } if ( $PSBoundParameters.ContainsKey('attributes') ) { $payload.Add('attributes', $attributes) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationtacacsaction -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationtacacsaction: Finished" } } function Invoke-ADCDeleteAuthenticationtacacsaction { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for TACACS action resource. .PARAMETER Name Name for the TACACS+ profile (action). Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after TACACS profile is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationtacacsaction -Name <string> An example how to delete authenticationtacacsaction configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationtacacsaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationtacacsaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationtacacsaction: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationtacacsaction -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationtacacsaction: Finished" } } function Invoke-ADCUpdateAuthenticationtacacsaction { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for TACACS action resource. .PARAMETER Name Name for the TACACS+ profile (action). Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after TACACS profile is created. .PARAMETER Serverip IP address assigned to the TACACS+ server. .PARAMETER Serverport Port number on which the TACACS+ server listens for connections. .PARAMETER Authtimeout Number of seconds the Citrix ADC waits for a response from the TACACS+ server. .PARAMETER Tacacssecret Key shared between the TACACS+ server and the Citrix ADC. Required for allowing the Citrix ADC to communicate with the TACACS+ server. .PARAMETER Authorization Use streaming authorization on the TACACS+ server. Possible values = ON, OFF .PARAMETER Accounting Whether the TACACS+ server is currently accepting accounting messages. Possible values = ON, OFF .PARAMETER Auditfailedcmds The state of the TACACS+ server that will receive accounting messages. Possible values = ON, OFF .PARAMETER Groupattrname TACACS+ group attribute name. Used for group extraction on the TACACS+ server. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER Attribute1 Name of the custom attribute to be extracted from server and stored at index '1' (where '1' changes for each attribute). .PARAMETER Attribute2 Name of the custom attribute to be extracted from server and stored at index '2' (where '2' changes for each attribute). .PARAMETER Attribute3 Name of the custom attribute to be extracted from server and stored at index '3' (where '3' changes for each attribute). .PARAMETER Attribute4 Name of the custom attribute to be extracted from server and stored at index '4' (where '4' changes for each attribute). .PARAMETER Attribute5 Name of the custom attribute to be extracted from server and stored at index '5' (where '5' changes for each attribute). .PARAMETER Attribute6 Name of the custom attribute to be extracted from server and stored at index '6' (where '6' changes for each attribute). .PARAMETER Attribute7 Name of the custom attribute to be extracted from server and stored at index '7' (where '7' changes for each attribute). .PARAMETER Attribute8 Name of the custom attribute to be extracted from server and stored at index '8' (where '8' changes for each attribute). .PARAMETER Attribute9 Name of the custom attribute to be extracted from server and stored at index '9' (where '9' changes for each attribute). .PARAMETER Attribute10 Name of the custom attribute to be extracted from server and stored at index '10' (where '10' changes for each attribute). .PARAMETER Attribute11 Name of the custom attribute to be extracted from server and stored at index '11' (where '11' changes for each attribute). .PARAMETER Attribute12 Name of the custom attribute to be extracted from server and stored at index '12' (where '12' changes for each attribute). .PARAMETER Attribute13 Name of the custom attribute to be extracted from server and stored at index '13' (where '13' changes for each attribute). .PARAMETER Attribute14 Name of the custom attribute to be extracted from server and stored at index '14' (where '14' changes for each attribute). .PARAMETER Attribute15 Name of the custom attribute to be extracted from server and stored at index '15' (where '15' changes for each attribute). .PARAMETER Attribute16 Name of the custom attribute to be extracted from server and stored at index '16' (where '16' changes for each attribute). .PARAMETER Attributes List of attribute names separated by ',' which needs to be fetched from tacacs server. Note that preceeding and trailing spaces will be removed. Attribute name can be 127 bytes and total length of this string should not cross 2047 bytes. These attributes have multi-value support separated by ',' and stored as key-value pair in AAA session. .PARAMETER PassThru Return details about the created authenticationtacacsaction item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationtacacsaction -name <string> An example how to update authenticationtacacsaction configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationtacacsaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationtacacsaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Serverip, [int]$Serverport, [double]$Authtimeout, [ValidateScript({ $_.Length -gt 1 })] [string]$Tacacssecret, [ValidateSet('ON', 'OFF')] [string]$Authorization, [ValidateSet('ON', 'OFF')] [string]$Accounting, [ValidateSet('ON', 'OFF')] [string]$Auditfailedcmds, [string]$Groupattrname, [string]$Defaultauthenticationgroup, [string]$Attribute1, [string]$Attribute2, [string]$Attribute3, [string]$Attribute4, [string]$Attribute5, [string]$Attribute6, [string]$Attribute7, [string]$Attribute8, [string]$Attribute9, [string]$Attribute10, [string]$Attribute11, [string]$Attribute12, [string]$Attribute13, [string]$Attribute14, [string]$Attribute15, [string]$Attribute16, [string]$Attributes, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationtacacsaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('serverip') ) { $payload.Add('serverip', $serverip) } if ( $PSBoundParameters.ContainsKey('serverport') ) { $payload.Add('serverport', $serverport) } if ( $PSBoundParameters.ContainsKey('authtimeout') ) { $payload.Add('authtimeout', $authtimeout) } if ( $PSBoundParameters.ContainsKey('tacacssecret') ) { $payload.Add('tacacssecret', $tacacssecret) } if ( $PSBoundParameters.ContainsKey('authorization') ) { $payload.Add('authorization', $authorization) } if ( $PSBoundParameters.ContainsKey('accounting') ) { $payload.Add('accounting', $accounting) } if ( $PSBoundParameters.ContainsKey('auditfailedcmds') ) { $payload.Add('auditfailedcmds', $auditfailedcmds) } if ( $PSBoundParameters.ContainsKey('groupattrname') ) { $payload.Add('groupattrname', $groupattrname) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('attribute1') ) { $payload.Add('attribute1', $attribute1) } if ( $PSBoundParameters.ContainsKey('attribute2') ) { $payload.Add('attribute2', $attribute2) } if ( $PSBoundParameters.ContainsKey('attribute3') ) { $payload.Add('attribute3', $attribute3) } if ( $PSBoundParameters.ContainsKey('attribute4') ) { $payload.Add('attribute4', $attribute4) } if ( $PSBoundParameters.ContainsKey('attribute5') ) { $payload.Add('attribute5', $attribute5) } if ( $PSBoundParameters.ContainsKey('attribute6') ) { $payload.Add('attribute6', $attribute6) } if ( $PSBoundParameters.ContainsKey('attribute7') ) { $payload.Add('attribute7', $attribute7) } if ( $PSBoundParameters.ContainsKey('attribute8') ) { $payload.Add('attribute8', $attribute8) } if ( $PSBoundParameters.ContainsKey('attribute9') ) { $payload.Add('attribute9', $attribute9) } if ( $PSBoundParameters.ContainsKey('attribute10') ) { $payload.Add('attribute10', $attribute10) } if ( $PSBoundParameters.ContainsKey('attribute11') ) { $payload.Add('attribute11', $attribute11) } if ( $PSBoundParameters.ContainsKey('attribute12') ) { $payload.Add('attribute12', $attribute12) } if ( $PSBoundParameters.ContainsKey('attribute13') ) { $payload.Add('attribute13', $attribute13) } if ( $PSBoundParameters.ContainsKey('attribute14') ) { $payload.Add('attribute14', $attribute14) } if ( $PSBoundParameters.ContainsKey('attribute15') ) { $payload.Add('attribute15', $attribute15) } if ( $PSBoundParameters.ContainsKey('attribute16') ) { $payload.Add('attribute16', $attribute16) } if ( $PSBoundParameters.ContainsKey('attributes') ) { $payload.Add('attributes', $attributes) } if ( $PSCmdlet.ShouldProcess("authenticationtacacsaction", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationtacacsaction -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationtacacsaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationtacacsaction: Finished" } } function Invoke-ADCAddAuthenticationtacacsaction { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for TACACS action resource. .PARAMETER Name Name for the TACACS+ profile (action). Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after TACACS profile is created. .PARAMETER Serverip IP address assigned to the TACACS+ server. .PARAMETER Serverport Port number on which the TACACS+ server listens for connections. .PARAMETER Authtimeout Number of seconds the Citrix ADC waits for a response from the TACACS+ server. .PARAMETER Tacacssecret Key shared between the TACACS+ server and the Citrix ADC. Required for allowing the Citrix ADC to communicate with the TACACS+ server. .PARAMETER Authorization Use streaming authorization on the TACACS+ server. Possible values = ON, OFF .PARAMETER Accounting Whether the TACACS+ server is currently accepting accounting messages. Possible values = ON, OFF .PARAMETER Auditfailedcmds The state of the TACACS+ server that will receive accounting messages. Possible values = ON, OFF .PARAMETER Groupattrname TACACS+ group attribute name. Used for group extraction on the TACACS+ server. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER Attribute1 Name of the custom attribute to be extracted from server and stored at index '1' (where '1' changes for each attribute). .PARAMETER Attribute2 Name of the custom attribute to be extracted from server and stored at index '2' (where '2' changes for each attribute). .PARAMETER Attribute3 Name of the custom attribute to be extracted from server and stored at index '3' (where '3' changes for each attribute). .PARAMETER Attribute4 Name of the custom attribute to be extracted from server and stored at index '4' (where '4' changes for each attribute). .PARAMETER Attribute5 Name of the custom attribute to be extracted from server and stored at index '5' (where '5' changes for each attribute). .PARAMETER Attribute6 Name of the custom attribute to be extracted from server and stored at index '6' (where '6' changes for each attribute). .PARAMETER Attribute7 Name of the custom attribute to be extracted from server and stored at index '7' (where '7' changes for each attribute). .PARAMETER Attribute8 Name of the custom attribute to be extracted from server and stored at index '8' (where '8' changes for each attribute). .PARAMETER Attribute9 Name of the custom attribute to be extracted from server and stored at index '9' (where '9' changes for each attribute). .PARAMETER Attribute10 Name of the custom attribute to be extracted from server and stored at index '10' (where '10' changes for each attribute). .PARAMETER Attribute11 Name of the custom attribute to be extracted from server and stored at index '11' (where '11' changes for each attribute). .PARAMETER Attribute12 Name of the custom attribute to be extracted from server and stored at index '12' (where '12' changes for each attribute). .PARAMETER Attribute13 Name of the custom attribute to be extracted from server and stored at index '13' (where '13' changes for each attribute). .PARAMETER Attribute14 Name of the custom attribute to be extracted from server and stored at index '14' (where '14' changes for each attribute). .PARAMETER Attribute15 Name of the custom attribute to be extracted from server and stored at index '15' (where '15' changes for each attribute). .PARAMETER Attribute16 Name of the custom attribute to be extracted from server and stored at index '16' (where '16' changes for each attribute). .PARAMETER Attributes List of attribute names separated by ',' which needs to be fetched from tacacs server. Note that preceeding and trailing spaces will be removed. Attribute name can be 127 bytes and total length of this string should not cross 2047 bytes. These attributes have multi-value support separated by ',' and stored as key-value pair in AAA session. .PARAMETER PassThru Return details about the created authenticationtacacsaction item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationtacacsaction -name <string> An example how to add authenticationtacacsaction configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationtacacsaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationtacacsaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Serverip, [int]$Serverport = '49', [double]$Authtimeout = '3', [ValidateScript({ $_.Length -gt 1 })] [string]$Tacacssecret, [ValidateSet('ON', 'OFF')] [string]$Authorization, [ValidateSet('ON', 'OFF')] [string]$Accounting, [ValidateSet('ON', 'OFF')] [string]$Auditfailedcmds, [string]$Groupattrname, [string]$Defaultauthenticationgroup, [string]$Attribute1, [string]$Attribute2, [string]$Attribute3, [string]$Attribute4, [string]$Attribute5, [string]$Attribute6, [string]$Attribute7, [string]$Attribute8, [string]$Attribute9, [string]$Attribute10, [string]$Attribute11, [string]$Attribute12, [string]$Attribute13, [string]$Attribute14, [string]$Attribute15, [string]$Attribute16, [string]$Attributes, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationtacacsaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('serverip') ) { $payload.Add('serverip', $serverip) } if ( $PSBoundParameters.ContainsKey('serverport') ) { $payload.Add('serverport', $serverport) } if ( $PSBoundParameters.ContainsKey('authtimeout') ) { $payload.Add('authtimeout', $authtimeout) } if ( $PSBoundParameters.ContainsKey('tacacssecret') ) { $payload.Add('tacacssecret', $tacacssecret) } if ( $PSBoundParameters.ContainsKey('authorization') ) { $payload.Add('authorization', $authorization) } if ( $PSBoundParameters.ContainsKey('accounting') ) { $payload.Add('accounting', $accounting) } if ( $PSBoundParameters.ContainsKey('auditfailedcmds') ) { $payload.Add('auditfailedcmds', $auditfailedcmds) } if ( $PSBoundParameters.ContainsKey('groupattrname') ) { $payload.Add('groupattrname', $groupattrname) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('attribute1') ) { $payload.Add('attribute1', $attribute1) } if ( $PSBoundParameters.ContainsKey('attribute2') ) { $payload.Add('attribute2', $attribute2) } if ( $PSBoundParameters.ContainsKey('attribute3') ) { $payload.Add('attribute3', $attribute3) } if ( $PSBoundParameters.ContainsKey('attribute4') ) { $payload.Add('attribute4', $attribute4) } if ( $PSBoundParameters.ContainsKey('attribute5') ) { $payload.Add('attribute5', $attribute5) } if ( $PSBoundParameters.ContainsKey('attribute6') ) { $payload.Add('attribute6', $attribute6) } if ( $PSBoundParameters.ContainsKey('attribute7') ) { $payload.Add('attribute7', $attribute7) } if ( $PSBoundParameters.ContainsKey('attribute8') ) { $payload.Add('attribute8', $attribute8) } if ( $PSBoundParameters.ContainsKey('attribute9') ) { $payload.Add('attribute9', $attribute9) } if ( $PSBoundParameters.ContainsKey('attribute10') ) { $payload.Add('attribute10', $attribute10) } if ( $PSBoundParameters.ContainsKey('attribute11') ) { $payload.Add('attribute11', $attribute11) } if ( $PSBoundParameters.ContainsKey('attribute12') ) { $payload.Add('attribute12', $attribute12) } if ( $PSBoundParameters.ContainsKey('attribute13') ) { $payload.Add('attribute13', $attribute13) } if ( $PSBoundParameters.ContainsKey('attribute14') ) { $payload.Add('attribute14', $attribute14) } if ( $PSBoundParameters.ContainsKey('attribute15') ) { $payload.Add('attribute15', $attribute15) } if ( $PSBoundParameters.ContainsKey('attribute16') ) { $payload.Add('attribute16', $attribute16) } if ( $PSBoundParameters.ContainsKey('attributes') ) { $payload.Add('attributes', $attributes) } if ( $PSCmdlet.ShouldProcess("authenticationtacacsaction", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationtacacsaction -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationtacacsaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationtacacsaction: Finished" } } function Invoke-ADCGetAuthenticationtacacsaction { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for TACACS action resource. .PARAMETER Name Name for the TACACS+ profile (action). Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after TACACS profile is created. .PARAMETER GetAll Retrieve all authenticationtacacsaction object(s). .PARAMETER Count If specified, the count of the authenticationtacacsaction object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacsaction Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacsaction -GetAll Get all authenticationtacacsaction data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacsaction -Count Get the number of authenticationtacacsaction objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacsaction -name <string> Get authenticationtacacsaction object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacsaction -Filter @{ 'name'='<value>' } Get authenticationtacacsaction data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationtacacsaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationtacacsaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationtacacsaction: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationtacacsaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacsaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationtacacsaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacsaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationtacacsaction objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacsaction -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationtacacsaction configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacsaction -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationtacacsaction configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacsaction -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationtacacsaction: Ended" } } function Invoke-ADCUpdateAuthenticationtacacspolicy { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for TACACS policy resource. .PARAMETER Name Name for the TACACS+ policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after TACACS+ policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to determine whether to attempt to authenticate the user with the TACACS+ server. .PARAMETER Reqaction Name of the TACACS+ action to perform if the policy matches. .PARAMETER PassThru Return details about the created authenticationtacacspolicy item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationtacacspolicy -name <string> An example how to update authenticationtacacspolicy configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationtacacspolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationtacacspolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Rule, [ValidateScript({ $_.Length -gt 1 })] [string]$Reqaction, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationtacacspolicy: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('rule') ) { $payload.Add('rule', $rule) } if ( $PSBoundParameters.ContainsKey('reqaction') ) { $payload.Add('reqaction', $reqaction) } if ( $PSCmdlet.ShouldProcess("authenticationtacacspolicy", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationtacacspolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationtacacspolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationtacacspolicy: Finished" } } function Invoke-ADCUnsetAuthenticationtacacspolicy { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for TACACS policy resource. .PARAMETER Name Name for the TACACS+ policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after TACACS+ policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to determine whether to attempt to authenticate the user with the TACACS+ server. .PARAMETER Reqaction Name of the TACACS+ action to perform if the policy matches. .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationtacacspolicy -name <string> An example how to unset authenticationtacacspolicy configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationtacacspolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationtacacspolicy Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Boolean]$rule, [Boolean]$reqaction ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationtacacspolicy: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('rule') ) { $payload.Add('rule', $rule) } if ( $PSBoundParameters.ContainsKey('reqaction') ) { $payload.Add('reqaction', $reqaction) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationtacacspolicy -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationtacacspolicy: Finished" } } function Invoke-ADCAddAuthenticationtacacspolicy { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for TACACS policy resource. .PARAMETER Name Name for the TACACS+ policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after TACACS+ policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to determine whether to attempt to authenticate the user with the TACACS+ server. .PARAMETER Reqaction Name of the TACACS+ action to perform if the policy matches. .PARAMETER PassThru Return details about the created authenticationtacacspolicy item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationtacacspolicy -name <string> -rule <string> An example how to add authenticationtacacspolicy configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationtacacspolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationtacacspolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Rule, [ValidateScript({ $_.Length -gt 1 })] [string]$Reqaction, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationtacacspolicy: Starting" } process { try { $payload = @{ name = $name rule = $rule } if ( $PSBoundParameters.ContainsKey('reqaction') ) { $payload.Add('reqaction', $reqaction) } if ( $PSCmdlet.ShouldProcess("authenticationtacacspolicy", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationtacacspolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationtacacspolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationtacacspolicy: Finished" } } function Invoke-ADCDeleteAuthenticationtacacspolicy { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for TACACS policy resource. .PARAMETER Name Name for the TACACS+ policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after TACACS+ policy is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationtacacspolicy -Name <string> An example how to delete authenticationtacacspolicy configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationtacacspolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationtacacspolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationtacacspolicy: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationtacacspolicy -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationtacacspolicy: Finished" } } function Invoke-ADCGetAuthenticationtacacspolicy { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for TACACS policy resource. .PARAMETER Name Name for the TACACS+ policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after TACACS+ policy is created. .PARAMETER GetAll Retrieve all authenticationtacacspolicy object(s). .PARAMETER Count If specified, the count of the authenticationtacacspolicy object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicy Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicy -GetAll Get all authenticationtacacspolicy data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicy -Count Get the number of authenticationtacacspolicy objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicy -name <string> Get authenticationtacacspolicy object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicy -Filter @{ 'name'='<value>' } Get authenticationtacacspolicy data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationtacacspolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationtacacspolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationtacacspolicy: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationtacacspolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationtacacspolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationtacacspolicy objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationtacacspolicy configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationtacacspolicy configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationtacacspolicy: Ended" } } function Invoke-ADCGetAuthenticationtacacspolicyauthenticationvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationvserver that can be bound to authenticationtacacspolicy. .PARAMETER Name Name of the TACACS+ policy. .PARAMETER GetAll Retrieve all authenticationtacacspolicy_authenticationvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationtacacspolicy_authenticationvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicyauthenticationvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicyauthenticationvserverbinding -GetAll Get all authenticationtacacspolicy_authenticationvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicyauthenticationvserverbinding -Count Get the number of authenticationtacacspolicy_authenticationvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicyauthenticationvserverbinding -name <string> Get authenticationtacacspolicy_authenticationvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicyauthenticationvserverbinding -Filter @{ 'name'='<value>' } Get authenticationtacacspolicy_authenticationvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationtacacspolicyauthenticationvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationtacacspolicy_authenticationvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationtacacspolicyauthenticationvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationtacacspolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationtacacspolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationtacacspolicy_authenticationvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationtacacspolicy_authenticationvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationtacacspolicy_authenticationvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationtacacspolicyauthenticationvserverbinding: Ended" } } function Invoke-ADCGetAuthenticationtacacspolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object which returns the resources bound to authenticationtacacspolicy. .PARAMETER Name Name of the TACACS+ policy. .PARAMETER GetAll Retrieve all authenticationtacacspolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationtacacspolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicybinding -GetAll Get all authenticationtacacspolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicybinding -name <string> Get authenticationtacacspolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicybinding -Filter @{ 'name'='<value>' } Get authenticationtacacspolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationtacacspolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationtacacspolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationtacacspolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationtacacspolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationtacacspolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationtacacspolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationtacacspolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationtacacspolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationtacacspolicybinding: Ended" } } function Invoke-ADCGetAuthenticationtacacspolicysystemglobalbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the systemglobal that can be bound to authenticationtacacspolicy. .PARAMETER Name Name of the TACACS+ policy. .PARAMETER GetAll Retrieve all authenticationtacacspolicy_systemglobal_binding object(s). .PARAMETER Count If specified, the count of the authenticationtacacspolicy_systemglobal_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicysystemglobalbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicysystemglobalbinding -GetAll Get all authenticationtacacspolicy_systemglobal_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicysystemglobalbinding -Count Get the number of authenticationtacacspolicy_systemglobal_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicysystemglobalbinding -name <string> Get authenticationtacacspolicy_systemglobal_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicysystemglobalbinding -Filter @{ 'name'='<value>' } Get authenticationtacacspolicy_systemglobal_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationtacacspolicysystemglobalbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationtacacspolicy_systemglobal_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationtacacspolicysystemglobalbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationtacacspolicy_systemglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_systemglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationtacacspolicy_systemglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_systemglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationtacacspolicy_systemglobal_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_systemglobal_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationtacacspolicy_systemglobal_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_systemglobal_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationtacacspolicy_systemglobal_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_systemglobal_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationtacacspolicysystemglobalbinding: Ended" } } function Invoke-ADCGetAuthenticationtacacspolicyvpnglobalbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the vpnglobal that can be bound to authenticationtacacspolicy. .PARAMETER Name Name of the TACACS+ policy. .PARAMETER GetAll Retrieve all authenticationtacacspolicy_vpnglobal_binding object(s). .PARAMETER Count If specified, the count of the authenticationtacacspolicy_vpnglobal_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicyvpnglobalbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicyvpnglobalbinding -GetAll Get all authenticationtacacspolicy_vpnglobal_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicyvpnglobalbinding -Count Get the number of authenticationtacacspolicy_vpnglobal_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicyvpnglobalbinding -name <string> Get authenticationtacacspolicy_vpnglobal_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicyvpnglobalbinding -Filter @{ 'name'='<value>' } Get authenticationtacacspolicy_vpnglobal_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationtacacspolicyvpnglobalbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationtacacspolicy_vpnglobal_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationtacacspolicyvpnglobalbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationtacacspolicy_vpnglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_vpnglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationtacacspolicy_vpnglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_vpnglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationtacacspolicy_vpnglobal_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_vpnglobal_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationtacacspolicy_vpnglobal_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_vpnglobal_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationtacacspolicy_vpnglobal_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_vpnglobal_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationtacacspolicyvpnglobalbinding: Ended" } } function Invoke-ADCGetAuthenticationtacacspolicyvpnvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the vpnvserver that can be bound to authenticationtacacspolicy. .PARAMETER Name Name of the TACACS+ policy. .PARAMETER GetAll Retrieve all authenticationtacacspolicy_vpnvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationtacacspolicy_vpnvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicyvpnvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicyvpnvserverbinding -GetAll Get all authenticationtacacspolicy_vpnvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicyvpnvserverbinding -Count Get the number of authenticationtacacspolicy_vpnvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicyvpnvserverbinding -name <string> Get authenticationtacacspolicy_vpnvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationtacacspolicyvpnvserverbinding -Filter @{ 'name'='<value>' } Get authenticationtacacspolicy_vpnvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationtacacspolicyvpnvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationtacacspolicy_vpnvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationtacacspolicyvpnvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationtacacspolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationtacacspolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationtacacspolicy_vpnvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_vpnvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationtacacspolicy_vpnvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_vpnvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationtacacspolicy_vpnvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationtacacspolicy_vpnvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationtacacspolicyvpnvserverbinding: Ended" } } function Invoke-ADCRenameAuthenticationvserver { <# .SYNOPSIS Rename Authentication configuration Object. .DESCRIPTION Configuration for authentication virtual server resource. .PARAMETER Name Name for the new authentication virtual server. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Can be changed after the authentication virtual server is added by using the rename authentication vserver command. .PARAMETER Newname New name of the authentication virtual server. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. .PARAMETER PassThru Return details about the created authenticationvserver item. .EXAMPLE PS C:\>Invoke-ADCRenameAuthenticationvserver -name <string> -newname <string> An example how to rename authenticationvserver configuration Object(s). .NOTES File Name : Invoke-ADCRenameAuthenticationvserver Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Newname, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCRenameAuthenticationvserver: Starting" } process { try { $payload = @{ name = $name newname = $newname } if ( $PSCmdlet.ShouldProcess("authenticationvserver", "Rename Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationvserver -Action rename -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationvserver -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCRenameAuthenticationvserver: Finished" } } function Invoke-ADCEnableAuthenticationvserver { <# .SYNOPSIS Enable Authentication configuration Object. .DESCRIPTION Configuration for authentication virtual server resource. .PARAMETER Name Name for the new authentication virtual server. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Can be changed after the authentication virtual server is added by using the rename authentication vserver command. .EXAMPLE PS C:\>Invoke-ADCEnableAuthenticationvserver -name <string> An example how to enable authenticationvserver configuration Object(s). .NOTES File Name : Invoke-ADCEnableAuthenticationvserver Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name ) begin { Write-Verbose "Invoke-ADCEnableAuthenticationvserver: Starting" } process { try { $payload = @{ name = $name } if ( $PSCmdlet.ShouldProcess($Name, "Enable Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationvserver -Action enable -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $result } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCEnableAuthenticationvserver: Finished" } } function Invoke-ADCDisableAuthenticationvserver { <# .SYNOPSIS Disable Authentication configuration Object. .DESCRIPTION Configuration for authentication virtual server resource. .PARAMETER Name Name for the new authentication virtual server. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Can be changed after the authentication virtual server is added by using the rename authentication vserver command. .EXAMPLE PS C:\>Invoke-ADCDisableAuthenticationvserver -name <string> An example how to disable authenticationvserver configuration Object(s). .NOTES File Name : Invoke-ADCDisableAuthenticationvserver Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name ) begin { Write-Verbose "Invoke-ADCDisableAuthenticationvserver: Starting" } process { try { $payload = @{ name = $name } if ( $PSCmdlet.ShouldProcess($Name, "Disable Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationvserver -Action disable -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $result } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDisableAuthenticationvserver: Finished" } } function Invoke-ADCUnsetAuthenticationvserver { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for authentication virtual server resource. .PARAMETER Name Name for the new authentication virtual server. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Can be changed after the authentication virtual server is added by using the rename authentication vserver command. .PARAMETER Authenticationdomain The domain of the authentication cookie set by Authentication vserver. .PARAMETER Maxloginattempts Maximum Number of login Attempts. .PARAMETER Authentication Require users to be authenticated before sending traffic through this virtual server. Possible values = ON, OFF .PARAMETER Comment Any comments associated with this virtual server. .PARAMETER Appflowlog Log AppFlow flow information. Possible values = ENABLED, DISABLED .PARAMETER Failedlogintimeout Number of minutes an account will be locked if user exceeds maximum permissible attempts. .PARAMETER Certkeynames Name of the certificate key that was bound to the corresponding SSL virtual server as the Certificate Authority for the device certificate. .PARAMETER Samesite SameSite attribute value for Cookies generated in AAATM context. This attribute value will be appended only for the cookies which are specified in the builtin patset ns_cookies_samesite. Possible values = None, LAX, STRICT .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationvserver -name <string> An example how to unset authenticationvserver configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationvserver Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Boolean]$authenticationdomain, [Boolean]$maxloginattempts, [Boolean]$authentication, [Boolean]$comment, [Boolean]$appflowlog, [Boolean]$failedlogintimeout, [Boolean]$certkeynames, [Boolean]$samesite ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationvserver: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('authenticationdomain') ) { $payload.Add('authenticationdomain', $authenticationdomain) } if ( $PSBoundParameters.ContainsKey('maxloginattempts') ) { $payload.Add('maxloginattempts', $maxloginattempts) } if ( $PSBoundParameters.ContainsKey('authentication') ) { $payload.Add('authentication', $authentication) } if ( $PSBoundParameters.ContainsKey('comment') ) { $payload.Add('comment', $comment) } if ( $PSBoundParameters.ContainsKey('appflowlog') ) { $payload.Add('appflowlog', $appflowlog) } if ( $PSBoundParameters.ContainsKey('failedlogintimeout') ) { $payload.Add('failedlogintimeout', $failedlogintimeout) } if ( $PSBoundParameters.ContainsKey('certkeynames') ) { $payload.Add('certkeynames', $certkeynames) } if ( $PSBoundParameters.ContainsKey('samesite') ) { $payload.Add('samesite', $samesite) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationvserver -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationvserver: Finished" } } function Invoke-ADCDeleteAuthenticationvserver { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for authentication virtual server resource. .PARAMETER Name Name for the new authentication virtual server. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Can be changed after the authentication virtual server is added by using the rename authentication vserver command. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationvserver -Name <string> An example how to delete authenticationvserver configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationvserver Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationvserver: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationvserver -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationvserver: Finished" } } function Invoke-ADCUpdateAuthenticationvserver { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for authentication virtual server resource. .PARAMETER Name Name for the new authentication virtual server. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Can be changed after the authentication virtual server is added by using the rename authentication vserver command. .PARAMETER Ipv46 IP address of the authentication virtual server, if a single IP address is assigned to the virtual server. .PARAMETER Authentication Require users to be authenticated before sending traffic through this virtual server. Possible values = ON, OFF .PARAMETER Authenticationdomain The domain of the authentication cookie set by Authentication vserver. .PARAMETER Comment Any comments associated with this virtual server. .PARAMETER Appflowlog Log AppFlow flow information. Possible values = ENABLED, DISABLED .PARAMETER Maxloginattempts Maximum Number of login Attempts. .PARAMETER Failedlogintimeout Number of minutes an account will be locked if user exceeds maximum permissible attempts. .PARAMETER Certkeynames Name of the certificate key that was bound to the corresponding SSL virtual server as the Certificate Authority for the device certificate. .PARAMETER Samesite SameSite attribute value for Cookies generated in AAATM context. This attribute value will be appended only for the cookies which are specified in the builtin patset ns_cookies_samesite. Possible values = None, LAX, STRICT .PARAMETER PassThru Return details about the created authenticationvserver item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationvserver -name <string> An example how to update authenticationvserver configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationvserver Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Ipv46, [ValidateSet('ON', 'OFF')] [string]$Authentication, [ValidateLength(3, 252)] [string]$Authenticationdomain, [string]$Comment, [ValidateSet('ENABLED', 'DISABLED')] [string]$Appflowlog, [ValidateRange(1, 255)] [double]$Maxloginattempts, [double]$Failedlogintimeout, [ValidateLength(1, 127)] [string]$Certkeynames, [ValidateSet('None', 'LAX', 'STRICT')] [string]$Samesite, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationvserver: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('ipv46') ) { $payload.Add('ipv46', $ipv46) } if ( $PSBoundParameters.ContainsKey('authentication') ) { $payload.Add('authentication', $authentication) } if ( $PSBoundParameters.ContainsKey('authenticationdomain') ) { $payload.Add('authenticationdomain', $authenticationdomain) } if ( $PSBoundParameters.ContainsKey('comment') ) { $payload.Add('comment', $comment) } if ( $PSBoundParameters.ContainsKey('appflowlog') ) { $payload.Add('appflowlog', $appflowlog) } if ( $PSBoundParameters.ContainsKey('maxloginattempts') ) { $payload.Add('maxloginattempts', $maxloginattempts) } if ( $PSBoundParameters.ContainsKey('failedlogintimeout') ) { $payload.Add('failedlogintimeout', $failedlogintimeout) } if ( $PSBoundParameters.ContainsKey('certkeynames') ) { $payload.Add('certkeynames', $certkeynames) } if ( $PSBoundParameters.ContainsKey('samesite') ) { $payload.Add('samesite', $samesite) } if ( $PSCmdlet.ShouldProcess("authenticationvserver", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationvserver -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationvserver -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationvserver: Finished" } } function Invoke-ADCAddAuthenticationvserver { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for authentication virtual server resource. .PARAMETER Name Name for the new authentication virtual server. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Can be changed after the authentication virtual server is added by using the rename authentication vserver command. .PARAMETER Servicetype Protocol type of the authentication virtual server. Always SSL. Possible values = SSL .PARAMETER Ipv46 IP address of the authentication virtual server, if a single IP address is assigned to the virtual server. .PARAMETER Range If you are creating a series of virtual servers with a range of IP addresses assigned to them, the length of the range. The new range of authentication virtual servers will have IP addresses consecutively numbered, starting with the primary address specified with the IP Address parameter. .PARAMETER Port TCP port on which the virtual server accepts connections. * in CLI is represented as 65535 in NITRO API .PARAMETER State Initial state of the new virtual server. Possible values = ENABLED, DISABLED .PARAMETER Authentication Require users to be authenticated before sending traffic through this virtual server. Possible values = ON, OFF .PARAMETER Authenticationdomain The domain of the authentication cookie set by Authentication vserver. .PARAMETER Comment Any comments associated with this virtual server. .PARAMETER Td Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0. .PARAMETER Appflowlog Log AppFlow flow information. Possible values = ENABLED, DISABLED .PARAMETER Maxloginattempts Maximum Number of login Attempts. .PARAMETER Failedlogintimeout Number of minutes an account will be locked if user exceeds maximum permissible attempts. .PARAMETER Certkeynames Name of the certificate key that was bound to the corresponding SSL virtual server as the Certificate Authority for the device certificate. .PARAMETER Samesite SameSite attribute value for Cookies generated in AAATM context. This attribute value will be appended only for the cookies which are specified in the builtin patset ns_cookies_samesite. Possible values = None, LAX, STRICT .PARAMETER PassThru Return details about the created authenticationvserver item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationvserver -name <string> -servicetype <string> An example how to add authenticationvserver configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationvserver Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(Mandatory)] [ValidateSet('SSL')] [string]$Servicetype = 'SSL', [ValidateScript({ $_.Length -gt 1 })] [string]$Ipv46, [double]$Range = '1', [ValidateRange(1, 65535)] [int]$Port, [ValidateSet('ENABLED', 'DISABLED')] [string]$State = 'ENABLED', [ValidateSet('ON', 'OFF')] [string]$Authentication = 'ON', [ValidateLength(3, 252)] [string]$Authenticationdomain, [string]$Comment, [ValidateRange(0, 4094)] [double]$Td, [ValidateSet('ENABLED', 'DISABLED')] [string]$Appflowlog = 'ENABLED', [ValidateRange(1, 255)] [double]$Maxloginattempts, [double]$Failedlogintimeout, [ValidateLength(1, 127)] [string]$Certkeynames, [ValidateSet('None', 'LAX', 'STRICT')] [string]$Samesite, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationvserver: Starting" } process { try { $payload = @{ name = $name servicetype = $servicetype } if ( $PSBoundParameters.ContainsKey('ipv46') ) { $payload.Add('ipv46', $ipv46) } if ( $PSBoundParameters.ContainsKey('range') ) { $payload.Add('range', $range) } if ( $PSBoundParameters.ContainsKey('port') ) { $payload.Add('port', $port) } if ( $PSBoundParameters.ContainsKey('state') ) { $payload.Add('state', $state) } if ( $PSBoundParameters.ContainsKey('authentication') ) { $payload.Add('authentication', $authentication) } if ( $PSBoundParameters.ContainsKey('authenticationdomain') ) { $payload.Add('authenticationdomain', $authenticationdomain) } if ( $PSBoundParameters.ContainsKey('comment') ) { $payload.Add('comment', $comment) } if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) } if ( $PSBoundParameters.ContainsKey('appflowlog') ) { $payload.Add('appflowlog', $appflowlog) } if ( $PSBoundParameters.ContainsKey('maxloginattempts') ) { $payload.Add('maxloginattempts', $maxloginattempts) } if ( $PSBoundParameters.ContainsKey('failedlogintimeout') ) { $payload.Add('failedlogintimeout', $failedlogintimeout) } if ( $PSBoundParameters.ContainsKey('certkeynames') ) { $payload.Add('certkeynames', $certkeynames) } if ( $PSBoundParameters.ContainsKey('samesite') ) { $payload.Add('samesite', $samesite) } if ( $PSCmdlet.ShouldProcess("authenticationvserver", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationvserver -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationvserver -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationvserver: Finished" } } function Invoke-ADCGetAuthenticationvserver { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for authentication virtual server resource. .PARAMETER Name Name for the new authentication virtual server. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Can be changed after the authentication virtual server is added by using the rename authentication vserver command. .PARAMETER GetAll Retrieve all authenticationvserver object(s). .PARAMETER Count If specified, the count of the authenticationvserver object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserver Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserver -GetAll Get all authenticationvserver data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserver -Count Get the number of authenticationvserver objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserver -name <string> Get authenticationvserver object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserver -Filter @{ 'name'='<value>' } Get authenticationvserver data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationvserver Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationvserver: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationvserver objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationvserver objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationvserver objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationvserver configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationvserver configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationvserver: Ended" } } function Invoke-ADCAddAuthenticationvserverauditnslogpolicybinding { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Binding object showing the auditnslogpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Priority The priority, if any, of the vpn vserver policy. .PARAMETER Secondary Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Nextfactor Applicable only while binding advance authentication policy as classic authentication policy does not support nFactor. .PARAMETER Gotopriorityexpression Applicable only to advance authentication policy. Expression or other value specifying the next policy to be evaluated if the current policy evaluates to TRUE. Specify one of the following values: * NEXT - Evaluate the policy with the next higher priority number. * END - End policy evaluation. * USE_INVOCATION_RESULT - Applicable if this policy invokes another policy label. If the final goto in the invoked policy label has a value of END, the evaluation stops. If the final goto is anything other than END, the current policy label performs a NEXT. * An expression that evaluates to a number. If you specify an expression, the number to which it evaluates determines the next policy to evaluate, as follows: * If the expression evaluates to a higher numbered priority, the policy with that priority is evaluated next. * If the expression evaluates to the priority of the current policy, the policy with the next higher numbered priority is evaluated next. * If the expression evaluates to a priority number that is numerically higher than the highest numbered priority, policy evaluation ends. An UNDEF event is triggered if: * The expression is invalid. * The expression evaluates to a priority number that is numerically lower than the current policy's priority. * The expression evaluates to a priority number that is between the current policy's priority number (say, 30) and the highest priority number (say, 100), but does not match any configured priority number (for example, the expression evaluates to the number 85). This example assumes that the priority number increments by 10 for every successive policy, and therefore a priority number of 85 does not exist in the policy label. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .PARAMETER PassThru Return details about the created authenticationvserver_auditnslogpolicy_binding item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationvserverauditnslogpolicybinding -name <string> An example how to add authenticationvserver_auditnslogpolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationvserverauditnslogpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_auditnslogpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Policy, [double]$Priority, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Nextfactor, [string]$Gotopriorityexpression, [ValidateSet('REQUEST', 'RESPONSE', 'ICA_REQUEST', 'OTHERTCP_REQUEST', 'AAA_REQUEST', 'AAA_RESPONSE')] [string]$Bindpoint, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationvserverauditnslogpolicybinding: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('policy') ) { $payload.Add('policy', $policy) } if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) } if ( $PSBoundParameters.ContainsKey('secondary') ) { $payload.Add('secondary', $secondary) } if ( $PSBoundParameters.ContainsKey('groupextraction') ) { $payload.Add('groupextraction', $groupextraction) } if ( $PSBoundParameters.ContainsKey('nextfactor') ) { $payload.Add('nextfactor', $nextfactor) } if ( $PSBoundParameters.ContainsKey('gotopriorityexpression') ) { $payload.Add('gotopriorityexpression', $gotopriorityexpression) } if ( $PSBoundParameters.ContainsKey('bindpoint') ) { $payload.Add('bindpoint', $bindpoint) } if ( $PSCmdlet.ShouldProcess("authenticationvserver_auditnslogpolicy_binding", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationvserver_auditnslogpolicy_binding -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationvserverauditnslogpolicybinding -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationvserverauditnslogpolicybinding: Finished" } } function Invoke-ADCDeleteAuthenticationvserverauditnslogpolicybinding { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Binding object showing the auditnslogpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Secondary Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationvserverauditnslogpolicybinding -Name <string> An example how to delete authenticationvserver_auditnslogpolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationvserverauditnslogpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_auditnslogpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name, [string]$Policy, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Bindpoint ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauditnslogpolicybinding: Starting" } process { try { $arguments = @{ } if ( $PSBoundParameters.ContainsKey('Policy') ) { $arguments.Add('policy', $Policy) } if ( $PSBoundParameters.ContainsKey('Secondary') ) { $arguments.Add('secondary', $Secondary) } if ( $PSBoundParameters.ContainsKey('Groupextraction') ) { $arguments.Add('groupextraction', $Groupextraction) } if ( $PSBoundParameters.ContainsKey('Bindpoint') ) { $arguments.Add('bindpoint', $Bindpoint) } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationvserver_auditnslogpolicy_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauditnslogpolicybinding: Finished" } } function Invoke-ADCGetAuthenticationvserverauditnslogpolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the auditnslogpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER GetAll Retrieve all authenticationvserver_auditnslogpolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationvserver_auditnslogpolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauditnslogpolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauditnslogpolicybinding -GetAll Get all authenticationvserver_auditnslogpolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauditnslogpolicybinding -Count Get the number of authenticationvserver_auditnslogpolicy_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauditnslogpolicybinding -name <string> Get authenticationvserver_auditnslogpolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauditnslogpolicybinding -Filter @{ 'name'='<value>' } Get authenticationvserver_auditnslogpolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationvserverauditnslogpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_auditnslogpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationvserverauditnslogpolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationvserver_auditnslogpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_auditnslogpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationvserver_auditnslogpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_auditnslogpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationvserver_auditnslogpolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_auditnslogpolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationvserver_auditnslogpolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_auditnslogpolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationvserver_auditnslogpolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_auditnslogpolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationvserverauditnslogpolicybinding: Ended" } } function Invoke-ADCAddAuthenticationvserverauditsyslogpolicybinding { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Binding object showing the auditsyslogpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Priority The priority, if any, of the vpn vserver policy. .PARAMETER Secondary Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Nextfactor Applicable only while binding advance authentication policy as classic authentication policy does not support nFactor. .PARAMETER Gotopriorityexpression Applicable only to advance authentication policy. Expression or other value specifying the next policy to be evaluated if the current policy evaluates to TRUE. Specify one of the following values: * NEXT - Evaluate the policy with the next higher priority number. * END - End policy evaluation. * USE_INVOCATION_RESULT - Applicable if this policy invokes another policy label. If the final goto in the invoked policy label has a value of END, the evaluation stops. If the final goto is anything other than END, the current policy label performs a NEXT. * An expression that evaluates to a number. If you specify an expression, the number to which it evaluates determines the next policy to evaluate, as follows: * If the expression evaluates to a higher numbered priority, the policy with that priority is evaluated next. * If the expression evaluates to the priority of the current policy, the policy with the next higher numbered priority is evaluated next. * If the expression evaluates to a priority number that is numerically higher than the highest numbered priority, policy evaluation ends. An UNDEF event is triggered if: * The expression is invalid. * The expression evaluates to a priority number that is numerically lower than the current policy's priority. * The expression evaluates to a priority number that is between the current policy's priority number (say, 30) and the highest priority number (say, 100), but does not match any configured priority number (for example, the expression evaluates to the number 85). This example assumes that the priority number increments by 10 for every successive policy, and therefore a priority number of 85 does not exist in the policy label. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .PARAMETER PassThru Return details about the created authenticationvserver_auditsyslogpolicy_binding item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationvserverauditsyslogpolicybinding -name <string> An example how to add authenticationvserver_auditsyslogpolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationvserverauditsyslogpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_auditsyslogpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Policy, [double]$Priority, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Nextfactor, [string]$Gotopriorityexpression, [ValidateSet('REQUEST', 'RESPONSE', 'ICA_REQUEST', 'OTHERTCP_REQUEST', 'AAA_REQUEST', 'AAA_RESPONSE')] [string]$Bindpoint, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationvserverauditsyslogpolicybinding: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('policy') ) { $payload.Add('policy', $policy) } if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) } if ( $PSBoundParameters.ContainsKey('secondary') ) { $payload.Add('secondary', $secondary) } if ( $PSBoundParameters.ContainsKey('groupextraction') ) { $payload.Add('groupextraction', $groupextraction) } if ( $PSBoundParameters.ContainsKey('nextfactor') ) { $payload.Add('nextfactor', $nextfactor) } if ( $PSBoundParameters.ContainsKey('gotopriorityexpression') ) { $payload.Add('gotopriorityexpression', $gotopriorityexpression) } if ( $PSBoundParameters.ContainsKey('bindpoint') ) { $payload.Add('bindpoint', $bindpoint) } if ( $PSCmdlet.ShouldProcess("authenticationvserver_auditsyslogpolicy_binding", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationvserver_auditsyslogpolicy_binding -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationvserverauditsyslogpolicybinding -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationvserverauditsyslogpolicybinding: Finished" } } function Invoke-ADCDeleteAuthenticationvserverauditsyslogpolicybinding { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Binding object showing the auditsyslogpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Secondary Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationvserverauditsyslogpolicybinding -Name <string> An example how to delete authenticationvserver_auditsyslogpolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationvserverauditsyslogpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_auditsyslogpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name, [string]$Policy, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Bindpoint ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauditsyslogpolicybinding: Starting" } process { try { $arguments = @{ } if ( $PSBoundParameters.ContainsKey('Policy') ) { $arguments.Add('policy', $Policy) } if ( $PSBoundParameters.ContainsKey('Secondary') ) { $arguments.Add('secondary', $Secondary) } if ( $PSBoundParameters.ContainsKey('Groupextraction') ) { $arguments.Add('groupextraction', $Groupextraction) } if ( $PSBoundParameters.ContainsKey('Bindpoint') ) { $arguments.Add('bindpoint', $Bindpoint) } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationvserver_auditsyslogpolicy_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauditsyslogpolicybinding: Finished" } } function Invoke-ADCGetAuthenticationvserverauditsyslogpolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the auditsyslogpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER GetAll Retrieve all authenticationvserver_auditsyslogpolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationvserver_auditsyslogpolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauditsyslogpolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauditsyslogpolicybinding -GetAll Get all authenticationvserver_auditsyslogpolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauditsyslogpolicybinding -Count Get the number of authenticationvserver_auditsyslogpolicy_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauditsyslogpolicybinding -name <string> Get authenticationvserver_auditsyslogpolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauditsyslogpolicybinding -Filter @{ 'name'='<value>' } Get authenticationvserver_auditsyslogpolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationvserverauditsyslogpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_auditsyslogpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationvserverauditsyslogpolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationvserver_auditsyslogpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_auditsyslogpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationvserver_auditsyslogpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_auditsyslogpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationvserver_auditsyslogpolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_auditsyslogpolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationvserver_auditsyslogpolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_auditsyslogpolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationvserver_auditsyslogpolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_auditsyslogpolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationvserverauditsyslogpolicybinding: Ended" } } function Invoke-ADCAddAuthenticationvserverauthenticationcertpolicybinding { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationcertpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Priority The priority, if any, of the vpn vserver policy. .PARAMETER Secondary Bind the authentication policy to the secondary chain. Provides for multifactor authentication in which a user must authenticate via both a primary authentication method and, afterward, via a secondary authentication method. Because user groups are aggregated across authentication systems, usernames must be the same on all authentication servers. Passwords can be different. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Nextfactor Applicable only while binding advance authentication policy as classic authentication policy does not support nFactor. .PARAMETER Gotopriorityexpression Applicable only to advance authentication policy. Expression or other value specifying the next policy to be evaluated if the current policy evaluates to TRUE. Specify one of the following values: * NEXT - Evaluate the policy with the next higher priority number. * END - End policy evaluation. * USE_INVOCATION_RESULT - Applicable if this policy invokes another policy label. If the final goto in the invoked policy label has a value of END, the evaluation stops. If the final goto is anything other than END, the current policy label performs a NEXT. * An expression that evaluates to a number. If you specify an expression, the number to which it evaluates determines the next policy to evaluate, as follows: * If the expression evaluates to a higher numbered priority, the policy with that priority is evaluated next. * If the expression evaluates to the priority of the current policy, the policy with the next higher numbered priority is evaluated next. * If the expression evaluates to a priority number that is numerically higher than the highest numbered priority, policy evaluation ends. An UNDEF event is triggered if: * The expression is invalid. * The expression evaluates to a priority number that is numerically lower than the current policy's priority. * The expression evaluates to a priority number that is between the current policy's priority number (say, 30) and the highest priority number (say, 100), but does not match any configured priority number (for example, the expression evaluates to the number 85). This example assumes that the priority number increments by 10 for every successive policy, and therefore a priority number of 85 does not exist in the policy label. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .PARAMETER PassThru Return details about the created authenticationvserver_authenticationcertpolicy_binding item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationvserverauthenticationcertpolicybinding -name <string> An example how to add authenticationvserver_authenticationcertpolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationvserverauthenticationcertpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationcertpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Policy, [double]$Priority, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Nextfactor, [string]$Gotopriorityexpression, [ValidateSet('REQUEST', 'RESPONSE', 'ICA_REQUEST', 'OTHERTCP_REQUEST', 'AAA_REQUEST', 'AAA_RESPONSE')] [string]$Bindpoint, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationcertpolicybinding: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('policy') ) { $payload.Add('policy', $policy) } if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) } if ( $PSBoundParameters.ContainsKey('secondary') ) { $payload.Add('secondary', $secondary) } if ( $PSBoundParameters.ContainsKey('groupextraction') ) { $payload.Add('groupextraction', $groupextraction) } if ( $PSBoundParameters.ContainsKey('nextfactor') ) { $payload.Add('nextfactor', $nextfactor) } if ( $PSBoundParameters.ContainsKey('gotopriorityexpression') ) { $payload.Add('gotopriorityexpression', $gotopriorityexpression) } if ( $PSBoundParameters.ContainsKey('bindpoint') ) { $payload.Add('bindpoint', $bindpoint) } if ( $PSCmdlet.ShouldProcess("authenticationvserver_authenticationcertpolicy_binding", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationvserver_authenticationcertpolicy_binding -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationvserverauthenticationcertpolicybinding -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationcertpolicybinding: Finished" } } function Invoke-ADCDeleteAuthenticationvserverauthenticationcertpolicybinding { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationcertpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Secondary Bind the authentication policy to the secondary chain. Provides for multifactor authentication in which a user must authenticate via both a primary authentication method and, afterward, via a secondary authentication method. Because user groups are aggregated across authentication systems, usernames must be the same on all authentication servers. Passwords can be different. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationvserverauthenticationcertpolicybinding -Name <string> An example how to delete authenticationvserver_authenticationcertpolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationvserverauthenticationcertpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationcertpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name, [string]$Policy, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Bindpoint ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationcertpolicybinding: Starting" } process { try { $arguments = @{ } if ( $PSBoundParameters.ContainsKey('Policy') ) { $arguments.Add('policy', $Policy) } if ( $PSBoundParameters.ContainsKey('Secondary') ) { $arguments.Add('secondary', $Secondary) } if ( $PSBoundParameters.ContainsKey('Groupextraction') ) { $arguments.Add('groupextraction', $Groupextraction) } if ( $PSBoundParameters.ContainsKey('Bindpoint') ) { $arguments.Add('bindpoint', $Bindpoint) } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationvserver_authenticationcertpolicy_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationcertpolicybinding: Finished" } } function Invoke-ADCGetAuthenticationvserverauthenticationcertpolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationcertpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER GetAll Retrieve all authenticationvserver_authenticationcertpolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationvserver_authenticationcertpolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationcertpolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationcertpolicybinding -GetAll Get all authenticationvserver_authenticationcertpolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationcertpolicybinding -Count Get the number of authenticationvserver_authenticationcertpolicy_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationcertpolicybinding -name <string> Get authenticationvserver_authenticationcertpolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationcertpolicybinding -Filter @{ 'name'='<value>' } Get authenticationvserver_authenticationcertpolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationvserverauthenticationcertpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationcertpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationcertpolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationvserver_authenticationcertpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationcertpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationvserver_authenticationcertpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationcertpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationvserver_authenticationcertpolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationcertpolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationvserver_authenticationcertpolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationcertpolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationvserver_authenticationcertpolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationcertpolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationcertpolicybinding: Ended" } } function Invoke-ADCAddAuthenticationvserverauthenticationldappolicybinding { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationldappolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Priority The priority, if any, of the vpn vserver policy. .PARAMETER Secondary Bind the authentication policy to the secondary chain. Provides for multifactor authentication in which a user must authenticate via both a primary authentication method and, afterward, via a secondary authentication method. Because user groups are aggregated across authentication systems, usernames must be the same on all authentication servers. Passwords can be different. .PARAMETER Groupextraction Bind the Authentication policy to a tertiary chain which will be used only for group extraction. The user will not authenticate against this server, and this will only be called if primary and/or secondary authentication has succeeded. .PARAMETER Nextfactor Applicable only while binding advance authentication policy as classic authentication policy does not support nFactor. .PARAMETER Gotopriorityexpression Applicable only to advance authentication policy. Expression or other value specifying the next policy to be evaluated if the current policy evaluates to TRUE. Specify one of the following values: * NEXT - Evaluate the policy with the next higher priority number. * END - End policy evaluation. * USE_INVOCATION_RESULT - Applicable if this policy invokes another policy label. If the final goto in the invoked policy label has a value of END, the evaluation stops. If the final goto is anything other than END, the current policy label performs a NEXT. * An expression that evaluates to a number. If you specify an expression, the number to which it evaluates determines the next policy to evaluate, as follows: * If the expression evaluates to a higher numbered priority, the policy with that priority is evaluated next. * If the expression evaluates to the priority of the current policy, the policy with the next higher numbered priority is evaluated next. * If the expression evaluates to a priority number that is numerically higher than the highest numbered priority, policy evaluation ends. An UNDEF event is triggered if: * The expression is invalid. * The expression evaluates to a priority number that is numerically lower than the current policy's priority. * The expression evaluates to a priority number that is between the current policy's priority number (say, 30) and the highest priority number (say, 100), but does not match any configured priority number (for example, the expression evaluates to the number 85). This example assumes that the priority number increments by 10 for every successive policy, and therefore a priority number of 85 does not exist in the policy label. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .PARAMETER PassThru Return details about the created authenticationvserver_authenticationldappolicy_binding item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationvserverauthenticationldappolicybinding -name <string> An example how to add authenticationvserver_authenticationldappolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationvserverauthenticationldappolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationldappolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Policy, [double]$Priority, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Nextfactor, [string]$Gotopriorityexpression, [ValidateSet('REQUEST', 'RESPONSE', 'ICA_REQUEST', 'OTHERTCP_REQUEST', 'AAA_REQUEST', 'AAA_RESPONSE')] [string]$Bindpoint, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationldappolicybinding: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('policy') ) { $payload.Add('policy', $policy) } if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) } if ( $PSBoundParameters.ContainsKey('secondary') ) { $payload.Add('secondary', $secondary) } if ( $PSBoundParameters.ContainsKey('groupextraction') ) { $payload.Add('groupextraction', $groupextraction) } if ( $PSBoundParameters.ContainsKey('nextfactor') ) { $payload.Add('nextfactor', $nextfactor) } if ( $PSBoundParameters.ContainsKey('gotopriorityexpression') ) { $payload.Add('gotopriorityexpression', $gotopriorityexpression) } if ( $PSBoundParameters.ContainsKey('bindpoint') ) { $payload.Add('bindpoint', $bindpoint) } if ( $PSCmdlet.ShouldProcess("authenticationvserver_authenticationldappolicy_binding", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationvserver_authenticationldappolicy_binding -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationvserverauthenticationldappolicybinding -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationldappolicybinding: Finished" } } function Invoke-ADCDeleteAuthenticationvserverauthenticationldappolicybinding { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationldappolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Secondary Bind the authentication policy to the secondary chain. Provides for multifactor authentication in which a user must authenticate via both a primary authentication method and, afterward, via a secondary authentication method. Because user groups are aggregated across authentication systems, usernames must be the same on all authentication servers. Passwords can be different. .PARAMETER Groupextraction Bind the Authentication policy to a tertiary chain which will be used only for group extraction. The user will not authenticate against this server, and this will only be called if primary and/or secondary authentication has succeeded. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationvserverauthenticationldappolicybinding -Name <string> An example how to delete authenticationvserver_authenticationldappolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationvserverauthenticationldappolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationldappolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name, [string]$Policy, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Bindpoint ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationldappolicybinding: Starting" } process { try { $arguments = @{ } if ( $PSBoundParameters.ContainsKey('Policy') ) { $arguments.Add('policy', $Policy) } if ( $PSBoundParameters.ContainsKey('Secondary') ) { $arguments.Add('secondary', $Secondary) } if ( $PSBoundParameters.ContainsKey('Groupextraction') ) { $arguments.Add('groupextraction', $Groupextraction) } if ( $PSBoundParameters.ContainsKey('Bindpoint') ) { $arguments.Add('bindpoint', $Bindpoint) } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationvserver_authenticationldappolicy_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationldappolicybinding: Finished" } } function Invoke-ADCGetAuthenticationvserverauthenticationldappolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationldappolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER GetAll Retrieve all authenticationvserver_authenticationldappolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationvserver_authenticationldappolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationldappolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationldappolicybinding -GetAll Get all authenticationvserver_authenticationldappolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationldappolicybinding -Count Get the number of authenticationvserver_authenticationldappolicy_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationldappolicybinding -name <string> Get authenticationvserver_authenticationldappolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationldappolicybinding -Filter @{ 'name'='<value>' } Get authenticationvserver_authenticationldappolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationvserverauthenticationldappolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationldappolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationldappolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationvserver_authenticationldappolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationldappolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationvserver_authenticationldappolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationldappolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationvserver_authenticationldappolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationldappolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationvserver_authenticationldappolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationldappolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationvserver_authenticationldappolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationldappolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationldappolicybinding: Ended" } } function Invoke-ADCAddAuthenticationvserverauthenticationlocalpolicybinding { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationlocalpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Priority The priority, if any, of the vpn vserver policy. .PARAMETER Secondary Bind the authentication policy to the secondary chain. Provides for multifactor authentication in which a user must authenticate via both a primary authentication method and, afterward, via a secondary authentication method. Because user groups are aggregated across authentication systems, usernames must be the same on all authentication servers. Passwords can be different. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Nextfactor Applicable only while binding advance authentication policy as classic authentication policy does not support nFactor. .PARAMETER Gotopriorityexpression Applicable only to advance authentication policy. Expression or other value specifying the next policy to be evaluated if the current policy evaluates to TRUE. Specify one of the following values: * NEXT - Evaluate the policy with the next higher priority number. * END - End policy evaluation. * USE_INVOCATION_RESULT - Applicable if this policy invokes another policy label. If the final goto in the invoked policy label has a value of END, the evaluation stops. If the final goto is anything other than END, the current policy label performs a NEXT. * An expression that evaluates to a number. If you specify an expression, the number to which it evaluates determines the next policy to evaluate, as follows: * If the expression evaluates to a higher numbered priority, the policy with that priority is evaluated next. * If the expression evaluates to the priority of the current policy, the policy with the next higher numbered priority is evaluated next. * If the expression evaluates to a priority number that is numerically higher than the highest numbered priority, policy evaluation ends. An UNDEF event is triggered if: * The expression is invalid. * The expression evaluates to a priority number that is numerically lower than the current policy's priority. * The expression evaluates to a priority number that is between the current policy's priority number (say, 30) and the highest priority number (say, 100), but does not match any configured priority number (for example, the expression evaluates to the number 85). This example assumes that the priority number increments by 10 for every successive policy, and therefore a priority number of 85 does not exist in the policy label. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .PARAMETER PassThru Return details about the created authenticationvserver_authenticationlocalpolicy_binding item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationvserverauthenticationlocalpolicybinding -name <string> An example how to add authenticationvserver_authenticationlocalpolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationvserverauthenticationlocalpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationlocalpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Policy, [double]$Priority, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Nextfactor, [string]$Gotopriorityexpression, [ValidateSet('REQUEST', 'RESPONSE', 'ICA_REQUEST', 'OTHERTCP_REQUEST', 'AAA_REQUEST', 'AAA_RESPONSE')] [string]$Bindpoint, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationlocalpolicybinding: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('policy') ) { $payload.Add('policy', $policy) } if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) } if ( $PSBoundParameters.ContainsKey('secondary') ) { $payload.Add('secondary', $secondary) } if ( $PSBoundParameters.ContainsKey('groupextraction') ) { $payload.Add('groupextraction', $groupextraction) } if ( $PSBoundParameters.ContainsKey('nextfactor') ) { $payload.Add('nextfactor', $nextfactor) } if ( $PSBoundParameters.ContainsKey('gotopriorityexpression') ) { $payload.Add('gotopriorityexpression', $gotopriorityexpression) } if ( $PSBoundParameters.ContainsKey('bindpoint') ) { $payload.Add('bindpoint', $bindpoint) } if ( $PSCmdlet.ShouldProcess("authenticationvserver_authenticationlocalpolicy_binding", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationvserver_authenticationlocalpolicy_binding -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationvserverauthenticationlocalpolicybinding -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationlocalpolicybinding: Finished" } } function Invoke-ADCDeleteAuthenticationvserverauthenticationlocalpolicybinding { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationlocalpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Secondary Bind the authentication policy to the secondary chain. Provides for multifactor authentication in which a user must authenticate via both a primary authentication method and, afterward, via a secondary authentication method. Because user groups are aggregated across authentication systems, usernames must be the same on all authentication servers. Passwords can be different. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationvserverauthenticationlocalpolicybinding -Name <string> An example how to delete authenticationvserver_authenticationlocalpolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationvserverauthenticationlocalpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationlocalpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name, [string]$Policy, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Bindpoint ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationlocalpolicybinding: Starting" } process { try { $arguments = @{ } if ( $PSBoundParameters.ContainsKey('Policy') ) { $arguments.Add('policy', $Policy) } if ( $PSBoundParameters.ContainsKey('Secondary') ) { $arguments.Add('secondary', $Secondary) } if ( $PSBoundParameters.ContainsKey('Groupextraction') ) { $arguments.Add('groupextraction', $Groupextraction) } if ( $PSBoundParameters.ContainsKey('Bindpoint') ) { $arguments.Add('bindpoint', $Bindpoint) } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationvserver_authenticationlocalpolicy_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationlocalpolicybinding: Finished" } } function Invoke-ADCGetAuthenticationvserverauthenticationlocalpolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationlocalpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER GetAll Retrieve all authenticationvserver_authenticationlocalpolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationvserver_authenticationlocalpolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationlocalpolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationlocalpolicybinding -GetAll Get all authenticationvserver_authenticationlocalpolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationlocalpolicybinding -Count Get the number of authenticationvserver_authenticationlocalpolicy_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationlocalpolicybinding -name <string> Get authenticationvserver_authenticationlocalpolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationlocalpolicybinding -Filter @{ 'name'='<value>' } Get authenticationvserver_authenticationlocalpolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationvserverauthenticationlocalpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationlocalpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationlocalpolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationvserver_authenticationlocalpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationlocalpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationvserver_authenticationlocalpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationlocalpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationvserver_authenticationlocalpolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationlocalpolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationvserver_authenticationlocalpolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationlocalpolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationvserver_authenticationlocalpolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationlocalpolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationlocalpolicybinding: Ended" } } function Invoke-ADCAddAuthenticationvserverauthenticationloginschemapolicybinding { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationloginschemapolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Priority The priority, if any, of the vpn vserver policy. .PARAMETER Secondary Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Nextfactor Applicable only while binding advance authentication policy as classic authentication policy does not support nFactor. .PARAMETER Gotopriorityexpression Expression specifying the priority of the next policy which will get evaluated if the current policy rule evaluates to TRUE. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .PARAMETER PassThru Return details about the created authenticationvserver_authenticationloginschemapolicy_binding item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationvserverauthenticationloginschemapolicybinding -name <string> An example how to add authenticationvserver_authenticationloginschemapolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationvserverauthenticationloginschemapolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationloginschemapolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Policy, [double]$Priority, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Nextfactor, [string]$Gotopriorityexpression, [ValidateSet('REQUEST', 'RESPONSE', 'ICA_REQUEST', 'OTHERTCP_REQUEST', 'AAA_REQUEST', 'AAA_RESPONSE')] [string]$Bindpoint, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationloginschemapolicybinding: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('policy') ) { $payload.Add('policy', $policy) } if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) } if ( $PSBoundParameters.ContainsKey('secondary') ) { $payload.Add('secondary', $secondary) } if ( $PSBoundParameters.ContainsKey('groupextraction') ) { $payload.Add('groupextraction', $groupextraction) } if ( $PSBoundParameters.ContainsKey('nextfactor') ) { $payload.Add('nextfactor', $nextfactor) } if ( $PSBoundParameters.ContainsKey('gotopriorityexpression') ) { $payload.Add('gotopriorityexpression', $gotopriorityexpression) } if ( $PSBoundParameters.ContainsKey('bindpoint') ) { $payload.Add('bindpoint', $bindpoint) } if ( $PSCmdlet.ShouldProcess("authenticationvserver_authenticationloginschemapolicy_binding", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationvserver_authenticationloginschemapolicy_binding -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationvserverauthenticationloginschemapolicybinding -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationloginschemapolicybinding: Finished" } } function Invoke-ADCDeleteAuthenticationvserverauthenticationloginschemapolicybinding { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationloginschemapolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Secondary Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationvserverauthenticationloginschemapolicybinding -Name <string> An example how to delete authenticationvserver_authenticationloginschemapolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationvserverauthenticationloginschemapolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationloginschemapolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name, [string]$Policy, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Bindpoint ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationloginschemapolicybinding: Starting" } process { try { $arguments = @{ } if ( $PSBoundParameters.ContainsKey('Policy') ) { $arguments.Add('policy', $Policy) } if ( $PSBoundParameters.ContainsKey('Secondary') ) { $arguments.Add('secondary', $Secondary) } if ( $PSBoundParameters.ContainsKey('Groupextraction') ) { $arguments.Add('groupextraction', $Groupextraction) } if ( $PSBoundParameters.ContainsKey('Bindpoint') ) { $arguments.Add('bindpoint', $Bindpoint) } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationvserver_authenticationloginschemapolicy_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationloginschemapolicybinding: Finished" } } function Invoke-ADCGetAuthenticationvserverauthenticationloginschemapolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationloginschemapolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER GetAll Retrieve all authenticationvserver_authenticationloginschemapolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationvserver_authenticationloginschemapolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationloginschemapolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationloginschemapolicybinding -GetAll Get all authenticationvserver_authenticationloginschemapolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationloginschemapolicybinding -Count Get the number of authenticationvserver_authenticationloginschemapolicy_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationloginschemapolicybinding -name <string> Get authenticationvserver_authenticationloginschemapolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationloginschemapolicybinding -Filter @{ 'name'='<value>' } Get authenticationvserver_authenticationloginschemapolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationvserverauthenticationloginschemapolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationloginschemapolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationloginschemapolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationvserver_authenticationloginschemapolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationloginschemapolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationvserver_authenticationloginschemapolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationloginschemapolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationvserver_authenticationloginschemapolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationloginschemapolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationvserver_authenticationloginschemapolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationloginschemapolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationvserver_authenticationloginschemapolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationloginschemapolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationloginschemapolicybinding: Ended" } } function Invoke-ADCAddAuthenticationvserverauthenticationnegotiatepolicybinding { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationnegotiatepolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Priority The priority, if any, of the vpn vserver policy. .PARAMETER Secondary Bind the authentication policy to the secondary chain. Provides for multifactor authentication in which a user must authenticate via both a primary authentication method and, afterward, via a secondary authentication method. Because user groups are aggregated across authentication systems, usernames must be the same on all authentication servers. Passwords can be different. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Nextfactor Applicable only while binding advance authentication policy as classic authentication policy does not support nFactor. .PARAMETER Gotopriorityexpression Applicable only to advance authentication policy. Expression or other value specifying the next policy to be evaluated if the current policy evaluates to TRUE. Specify one of the following values: * NEXT - Evaluate the policy with the next higher priority number. * END - End policy evaluation. * USE_INVOCATION_RESULT - Applicable if this policy invokes another policy label. If the final goto in the invoked policy label has a value of END, the evaluation stops. If the final goto is anything other than END, the current policy label performs a NEXT. * An expression that evaluates to a number. If you specify an expression, the number to which it evaluates determines the next policy to evaluate, as follows: * If the expression evaluates to a higher numbered priority, the policy with that priority is evaluated next. * If the expression evaluates to the priority of the current policy, the policy with the next higher numbered priority is evaluated next. * If the expression evaluates to a priority number that is numerically higher than the highest numbered priority, policy evaluation ends. An UNDEF event is triggered if: * The expression is invalid. * The expression evaluates to a priority number that is numerically lower than the current policy's priority. * The expression evaluates to a priority number that is between the current policy's priority number (say, 30) and the highest priority number (say, 100), but does not match any configured priority number (for example, the expression evaluates to the number 85). This example assumes that the priority number increments by 10 for every successive policy, and therefore a priority number of 85 does not exist in the policy label. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .PARAMETER PassThru Return details about the created authenticationvserver_authenticationnegotiatepolicy_binding item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationvserverauthenticationnegotiatepolicybinding -name <string> An example how to add authenticationvserver_authenticationnegotiatepolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationvserverauthenticationnegotiatepolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationnegotiatepolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Policy, [double]$Priority, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Nextfactor, [string]$Gotopriorityexpression, [ValidateSet('REQUEST', 'RESPONSE', 'ICA_REQUEST', 'OTHERTCP_REQUEST', 'AAA_REQUEST', 'AAA_RESPONSE')] [string]$Bindpoint, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationnegotiatepolicybinding: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('policy') ) { $payload.Add('policy', $policy) } if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) } if ( $PSBoundParameters.ContainsKey('secondary') ) { $payload.Add('secondary', $secondary) } if ( $PSBoundParameters.ContainsKey('groupextraction') ) { $payload.Add('groupextraction', $groupextraction) } if ( $PSBoundParameters.ContainsKey('nextfactor') ) { $payload.Add('nextfactor', $nextfactor) } if ( $PSBoundParameters.ContainsKey('gotopriorityexpression') ) { $payload.Add('gotopriorityexpression', $gotopriorityexpression) } if ( $PSBoundParameters.ContainsKey('bindpoint') ) { $payload.Add('bindpoint', $bindpoint) } if ( $PSCmdlet.ShouldProcess("authenticationvserver_authenticationnegotiatepolicy_binding", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationvserver_authenticationnegotiatepolicy_binding -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationvserverauthenticationnegotiatepolicybinding -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationnegotiatepolicybinding: Finished" } } function Invoke-ADCDeleteAuthenticationvserverauthenticationnegotiatepolicybinding { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationnegotiatepolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Secondary Bind the authentication policy to the secondary chain. Provides for multifactor authentication in which a user must authenticate via both a primary authentication method and, afterward, via a secondary authentication method. Because user groups are aggregated across authentication systems, usernames must be the same on all authentication servers. Passwords can be different. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationvserverauthenticationnegotiatepolicybinding -Name <string> An example how to delete authenticationvserver_authenticationnegotiatepolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationvserverauthenticationnegotiatepolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationnegotiatepolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name, [string]$Policy, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Bindpoint ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationnegotiatepolicybinding: Starting" } process { try { $arguments = @{ } if ( $PSBoundParameters.ContainsKey('Policy') ) { $arguments.Add('policy', $Policy) } if ( $PSBoundParameters.ContainsKey('Secondary') ) { $arguments.Add('secondary', $Secondary) } if ( $PSBoundParameters.ContainsKey('Groupextraction') ) { $arguments.Add('groupextraction', $Groupextraction) } if ( $PSBoundParameters.ContainsKey('Bindpoint') ) { $arguments.Add('bindpoint', $Bindpoint) } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationvserver_authenticationnegotiatepolicy_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationnegotiatepolicybinding: Finished" } } function Invoke-ADCGetAuthenticationvserverauthenticationnegotiatepolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationnegotiatepolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER GetAll Retrieve all authenticationvserver_authenticationnegotiatepolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationvserver_authenticationnegotiatepolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationnegotiatepolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationnegotiatepolicybinding -GetAll Get all authenticationvserver_authenticationnegotiatepolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationnegotiatepolicybinding -Count Get the number of authenticationvserver_authenticationnegotiatepolicy_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationnegotiatepolicybinding -name <string> Get authenticationvserver_authenticationnegotiatepolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationnegotiatepolicybinding -Filter @{ 'name'='<value>' } Get authenticationvserver_authenticationnegotiatepolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationvserverauthenticationnegotiatepolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationnegotiatepolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationnegotiatepolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationvserver_authenticationnegotiatepolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationnegotiatepolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationvserver_authenticationnegotiatepolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationnegotiatepolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationvserver_authenticationnegotiatepolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationnegotiatepolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationvserver_authenticationnegotiatepolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationnegotiatepolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationvserver_authenticationnegotiatepolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationnegotiatepolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationnegotiatepolicybinding: Ended" } } function Invoke-ADCAddAuthenticationvserverauthenticationoauthidppolicybinding { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationoauthidppolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Priority The priority, if any, of the vpn vserver policy. .PARAMETER Secondary Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Nextfactor On success invoke label. .PARAMETER Gotopriorityexpression Expression specifying the priority of the next policy which will get evaluated if the current policy rule evaluates to TRUE. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .PARAMETER PassThru Return details about the created authenticationvserver_authenticationoauthidppolicy_binding item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationvserverauthenticationoauthidppolicybinding -name <string> An example how to add authenticationvserver_authenticationoauthidppolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationvserverauthenticationoauthidppolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationoauthidppolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Policy, [double]$Priority, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Nextfactor, [string]$Gotopriorityexpression, [ValidateSet('REQUEST', 'RESPONSE', 'ICA_REQUEST', 'OTHERTCP_REQUEST', 'AAA_REQUEST', 'AAA_RESPONSE')] [string]$Bindpoint, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationoauthidppolicybinding: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('policy') ) { $payload.Add('policy', $policy) } if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) } if ( $PSBoundParameters.ContainsKey('secondary') ) { $payload.Add('secondary', $secondary) } if ( $PSBoundParameters.ContainsKey('groupextraction') ) { $payload.Add('groupextraction', $groupextraction) } if ( $PSBoundParameters.ContainsKey('nextfactor') ) { $payload.Add('nextfactor', $nextfactor) } if ( $PSBoundParameters.ContainsKey('gotopriorityexpression') ) { $payload.Add('gotopriorityexpression', $gotopriorityexpression) } if ( $PSBoundParameters.ContainsKey('bindpoint') ) { $payload.Add('bindpoint', $bindpoint) } if ( $PSCmdlet.ShouldProcess("authenticationvserver_authenticationoauthidppolicy_binding", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationvserver_authenticationoauthidppolicy_binding -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationvserverauthenticationoauthidppolicybinding -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationoauthidppolicybinding: Finished" } } function Invoke-ADCDeleteAuthenticationvserverauthenticationoauthidppolicybinding { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationoauthidppolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Secondary Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationvserverauthenticationoauthidppolicybinding -Name <string> An example how to delete authenticationvserver_authenticationoauthidppolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationvserverauthenticationoauthidppolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationoauthidppolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name, [string]$Policy, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Bindpoint ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationoauthidppolicybinding: Starting" } process { try { $arguments = @{ } if ( $PSBoundParameters.ContainsKey('Policy') ) { $arguments.Add('policy', $Policy) } if ( $PSBoundParameters.ContainsKey('Secondary') ) { $arguments.Add('secondary', $Secondary) } if ( $PSBoundParameters.ContainsKey('Groupextraction') ) { $arguments.Add('groupextraction', $Groupextraction) } if ( $PSBoundParameters.ContainsKey('Bindpoint') ) { $arguments.Add('bindpoint', $Bindpoint) } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationvserver_authenticationoauthidppolicy_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationoauthidppolicybinding: Finished" } } function Invoke-ADCGetAuthenticationvserverauthenticationoauthidppolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationoauthidppolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER GetAll Retrieve all authenticationvserver_authenticationoauthidppolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationvserver_authenticationoauthidppolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationoauthidppolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationoauthidppolicybinding -GetAll Get all authenticationvserver_authenticationoauthidppolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationoauthidppolicybinding -Count Get the number of authenticationvserver_authenticationoauthidppolicy_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationoauthidppolicybinding -name <string> Get authenticationvserver_authenticationoauthidppolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationoauthidppolicybinding -Filter @{ 'name'='<value>' } Get authenticationvserver_authenticationoauthidppolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationvserverauthenticationoauthidppolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationoauthidppolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationoauthidppolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationvserver_authenticationoauthidppolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationoauthidppolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationvserver_authenticationoauthidppolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationoauthidppolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationvserver_authenticationoauthidppolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationoauthidppolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationvserver_authenticationoauthidppolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationoauthidppolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationvserver_authenticationoauthidppolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationoauthidppolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationoauthidppolicybinding: Ended" } } function Invoke-ADCAddAuthenticationvserverauthenticationpolicybinding { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Priority The priority, if any, of the vpn vserver policy. .PARAMETER Secondary Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Nextfactor On success invoke label. .PARAMETER Gotopriorityexpression Expression specifying the priority of the next policy which will get evaluated if the current policy rule evaluates to TRUE. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .PARAMETER PassThru Return details about the created authenticationvserver_authenticationpolicy_binding item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationvserverauthenticationpolicybinding -name <string> An example how to add authenticationvserver_authenticationpolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationvserverauthenticationpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Policy, [double]$Priority, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Nextfactor, [string]$Gotopriorityexpression, [ValidateSet('REQUEST', 'RESPONSE', 'ICA_REQUEST', 'OTHERTCP_REQUEST', 'AAA_REQUEST', 'AAA_RESPONSE')] [string]$Bindpoint, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationpolicybinding: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('policy') ) { $payload.Add('policy', $policy) } if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) } if ( $PSBoundParameters.ContainsKey('secondary') ) { $payload.Add('secondary', $secondary) } if ( $PSBoundParameters.ContainsKey('groupextraction') ) { $payload.Add('groupextraction', $groupextraction) } if ( $PSBoundParameters.ContainsKey('nextfactor') ) { $payload.Add('nextfactor', $nextfactor) } if ( $PSBoundParameters.ContainsKey('gotopriorityexpression') ) { $payload.Add('gotopriorityexpression', $gotopriorityexpression) } if ( $PSBoundParameters.ContainsKey('bindpoint') ) { $payload.Add('bindpoint', $bindpoint) } if ( $PSCmdlet.ShouldProcess("authenticationvserver_authenticationpolicy_binding", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationvserver_authenticationpolicy_binding -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationvserverauthenticationpolicybinding -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationpolicybinding: Finished" } } function Invoke-ADCDeleteAuthenticationvserverauthenticationpolicybinding { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Secondary Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationvserverauthenticationpolicybinding -Name <string> An example how to delete authenticationvserver_authenticationpolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationvserverauthenticationpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name, [string]$Policy, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Bindpoint ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationpolicybinding: Starting" } process { try { $arguments = @{ } if ( $PSBoundParameters.ContainsKey('Policy') ) { $arguments.Add('policy', $Policy) } if ( $PSBoundParameters.ContainsKey('Secondary') ) { $arguments.Add('secondary', $Secondary) } if ( $PSBoundParameters.ContainsKey('Groupextraction') ) { $arguments.Add('groupextraction', $Groupextraction) } if ( $PSBoundParameters.ContainsKey('Bindpoint') ) { $arguments.Add('bindpoint', $Bindpoint) } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationvserver_authenticationpolicy_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationpolicybinding: Finished" } } function Invoke-ADCGetAuthenticationvserverauthenticationpolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER GetAll Retrieve all authenticationvserver_authenticationpolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationvserver_authenticationpolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationpolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationpolicybinding -GetAll Get all authenticationvserver_authenticationpolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationpolicybinding -Count Get the number of authenticationvserver_authenticationpolicy_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationpolicybinding -name <string> Get authenticationvserver_authenticationpolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationpolicybinding -Filter @{ 'name'='<value>' } Get authenticationvserver_authenticationpolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationvserverauthenticationpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationpolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationvserver_authenticationpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationvserver_authenticationpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationvserver_authenticationpolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationpolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationvserver_authenticationpolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationpolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationvserver_authenticationpolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationpolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationpolicybinding: Ended" } } function Invoke-ADCAddAuthenticationvserverauthenticationradiuspolicybinding { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationradiuspolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Priority The priority, if any, of the vpn vserver policy. .PARAMETER Secondary Bind the authentication policy to the secondary chain. Provides for multifactor authentication in which a user must authenticate via both a primary authentication method and, afterward, via a secondary authentication method. Because user groups are aggregated across authentication systems, usernames must be the same on all authentication servers. Passwords can be different. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Nextfactor Applicable only while binding advance authentication policy as classic authentication policy does not support nFactor. .PARAMETER Gotopriorityexpression Applicable only to advance authentication policy. Expression or other value specifying the next policy to be evaluated if the current policy evaluates to TRUE. Specify one of the following values: * NEXT - Evaluate the policy with the next higher priority number. * END - End policy evaluation. * USE_INVOCATION_RESULT - Applicable if this policy invokes another policy label. If the final goto in the invoked policy label has a value of END, the evaluation stops. If the final goto is anything other than END, the current policy label performs a NEXT. * An expression that evaluates to a number. If you specify an expression, the number to which it evaluates determines the next policy to evaluate, as follows: * If the expression evaluates to a higher numbered priority, the policy with that priority is evaluated next. * If the expression evaluates to the priority of the current policy, the policy with the next higher numbered priority is evaluated next. * If the expression evaluates to a priority number that is numerically higher than the highest numbered priority, policy evaluation ends. An UNDEF event is triggered if: * The expression is invalid. * The expression evaluates to a priority number that is numerically lower than the current policy's priority. * The expression evaluates to a priority number that is between the current policy's priority number (say, 30) and the highest priority number (say, 100), but does not match any configured priority number (for example, the expression evaluates to the number 85). This example assumes that the priority number increments by 10 for every successive policy, and therefore a priority number of 85 does not exist in the policy label. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .PARAMETER PassThru Return details about the created authenticationvserver_authenticationradiuspolicy_binding item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationvserverauthenticationradiuspolicybinding -name <string> An example how to add authenticationvserver_authenticationradiuspolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationvserverauthenticationradiuspolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationradiuspolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Policy, [double]$Priority, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Nextfactor, [string]$Gotopriorityexpression, [ValidateSet('REQUEST', 'RESPONSE', 'ICA_REQUEST', 'OTHERTCP_REQUEST', 'AAA_REQUEST', 'AAA_RESPONSE')] [string]$Bindpoint, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationradiuspolicybinding: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('policy') ) { $payload.Add('policy', $policy) } if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) } if ( $PSBoundParameters.ContainsKey('secondary') ) { $payload.Add('secondary', $secondary) } if ( $PSBoundParameters.ContainsKey('groupextraction') ) { $payload.Add('groupextraction', $groupextraction) } if ( $PSBoundParameters.ContainsKey('nextfactor') ) { $payload.Add('nextfactor', $nextfactor) } if ( $PSBoundParameters.ContainsKey('gotopriorityexpression') ) { $payload.Add('gotopriorityexpression', $gotopriorityexpression) } if ( $PSBoundParameters.ContainsKey('bindpoint') ) { $payload.Add('bindpoint', $bindpoint) } if ( $PSCmdlet.ShouldProcess("authenticationvserver_authenticationradiuspolicy_binding", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationvserver_authenticationradiuspolicy_binding -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationvserverauthenticationradiuspolicybinding -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationradiuspolicybinding: Finished" } } function Invoke-ADCDeleteAuthenticationvserverauthenticationradiuspolicybinding { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationradiuspolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Secondary Bind the authentication policy to the secondary chain. Provides for multifactor authentication in which a user must authenticate via both a primary authentication method and, afterward, via a secondary authentication method. Because user groups are aggregated across authentication systems, usernames must be the same on all authentication servers. Passwords can be different. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationvserverauthenticationradiuspolicybinding -Name <string> An example how to delete authenticationvserver_authenticationradiuspolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationvserverauthenticationradiuspolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationradiuspolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name, [string]$Policy, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Bindpoint ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationradiuspolicybinding: Starting" } process { try { $arguments = @{ } if ( $PSBoundParameters.ContainsKey('Policy') ) { $arguments.Add('policy', $Policy) } if ( $PSBoundParameters.ContainsKey('Secondary') ) { $arguments.Add('secondary', $Secondary) } if ( $PSBoundParameters.ContainsKey('Groupextraction') ) { $arguments.Add('groupextraction', $Groupextraction) } if ( $PSBoundParameters.ContainsKey('Bindpoint') ) { $arguments.Add('bindpoint', $Bindpoint) } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationvserver_authenticationradiuspolicy_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationradiuspolicybinding: Finished" } } function Invoke-ADCGetAuthenticationvserverauthenticationradiuspolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationradiuspolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER GetAll Retrieve all authenticationvserver_authenticationradiuspolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationvserver_authenticationradiuspolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationradiuspolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationradiuspolicybinding -GetAll Get all authenticationvserver_authenticationradiuspolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationradiuspolicybinding -Count Get the number of authenticationvserver_authenticationradiuspolicy_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationradiuspolicybinding -name <string> Get authenticationvserver_authenticationradiuspolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationradiuspolicybinding -Filter @{ 'name'='<value>' } Get authenticationvserver_authenticationradiuspolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationvserverauthenticationradiuspolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationradiuspolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationradiuspolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationvserver_authenticationradiuspolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationradiuspolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationvserver_authenticationradiuspolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationradiuspolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationvserver_authenticationradiuspolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationradiuspolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationvserver_authenticationradiuspolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationradiuspolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationvserver_authenticationradiuspolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationradiuspolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationradiuspolicybinding: Ended" } } function Invoke-ADCAddAuthenticationvserverauthenticationsamlidppolicybinding { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationsamlidppolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Priority The priority, if any, of the vpn vserver policy. .PARAMETER Secondary Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Nextfactor On success invoke label. .PARAMETER Gotopriorityexpression Expression specifying the priority of the next policy which will get evaluated if the current policy rule evaluates to TRUE. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .PARAMETER PassThru Return details about the created authenticationvserver_authenticationsamlidppolicy_binding item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationvserverauthenticationsamlidppolicybinding -name <string> An example how to add authenticationvserver_authenticationsamlidppolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationvserverauthenticationsamlidppolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationsamlidppolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Policy, [double]$Priority, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Nextfactor, [string]$Gotopriorityexpression, [ValidateSet('REQUEST', 'RESPONSE', 'ICA_REQUEST', 'OTHERTCP_REQUEST', 'AAA_REQUEST', 'AAA_RESPONSE')] [string]$Bindpoint, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationsamlidppolicybinding: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('policy') ) { $payload.Add('policy', $policy) } if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) } if ( $PSBoundParameters.ContainsKey('secondary') ) { $payload.Add('secondary', $secondary) } if ( $PSBoundParameters.ContainsKey('groupextraction') ) { $payload.Add('groupextraction', $groupextraction) } if ( $PSBoundParameters.ContainsKey('nextfactor') ) { $payload.Add('nextfactor', $nextfactor) } if ( $PSBoundParameters.ContainsKey('gotopriorityexpression') ) { $payload.Add('gotopriorityexpression', $gotopriorityexpression) } if ( $PSBoundParameters.ContainsKey('bindpoint') ) { $payload.Add('bindpoint', $bindpoint) } if ( $PSCmdlet.ShouldProcess("authenticationvserver_authenticationsamlidppolicy_binding", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationvserver_authenticationsamlidppolicy_binding -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationvserverauthenticationsamlidppolicybinding -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationsamlidppolicybinding: Finished" } } function Invoke-ADCDeleteAuthenticationvserverauthenticationsamlidppolicybinding { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationsamlidppolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Secondary Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationvserverauthenticationsamlidppolicybinding -Name <string> An example how to delete authenticationvserver_authenticationsamlidppolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationvserverauthenticationsamlidppolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationsamlidppolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name, [string]$Policy, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Bindpoint ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationsamlidppolicybinding: Starting" } process { try { $arguments = @{ } if ( $PSBoundParameters.ContainsKey('Policy') ) { $arguments.Add('policy', $Policy) } if ( $PSBoundParameters.ContainsKey('Secondary') ) { $arguments.Add('secondary', $Secondary) } if ( $PSBoundParameters.ContainsKey('Groupextraction') ) { $arguments.Add('groupextraction', $Groupextraction) } if ( $PSBoundParameters.ContainsKey('Bindpoint') ) { $arguments.Add('bindpoint', $Bindpoint) } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationvserver_authenticationsamlidppolicy_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationsamlidppolicybinding: Finished" } } function Invoke-ADCGetAuthenticationvserverauthenticationsamlidppolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationsamlidppolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER GetAll Retrieve all authenticationvserver_authenticationsamlidppolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationvserver_authenticationsamlidppolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationsamlidppolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationsamlidppolicybinding -GetAll Get all authenticationvserver_authenticationsamlidppolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationsamlidppolicybinding -Count Get the number of authenticationvserver_authenticationsamlidppolicy_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationsamlidppolicybinding -name <string> Get authenticationvserver_authenticationsamlidppolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationsamlidppolicybinding -Filter @{ 'name'='<value>' } Get authenticationvserver_authenticationsamlidppolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationvserverauthenticationsamlidppolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationsamlidppolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationsamlidppolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationvserver_authenticationsamlidppolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationsamlidppolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationvserver_authenticationsamlidppolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationsamlidppolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationvserver_authenticationsamlidppolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationsamlidppolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationvserver_authenticationsamlidppolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationsamlidppolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationvserver_authenticationsamlidppolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationsamlidppolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationsamlidppolicybinding: Ended" } } function Invoke-ADCAddAuthenticationvserverauthenticationsamlpolicybinding { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationsamlpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Priority The priority, if any, of the vpn vserver policy. .PARAMETER Secondary Bind the authentication policy to the secondary chain. Provides for multifactor authentication in which a user must authenticate via both a primary authentication method and, afterward, via a secondary authentication method. Because user groups are aggregated across authentication systems, usernames must be the same on all authentication servers. Passwords can be different. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Nextfactor Applicable only while binding advance authentication policy as classic authentication policy does not support nFactor. .PARAMETER Gotopriorityexpression Applicable only to advance authentication policy. Expression or other value specifying the next policy to be evaluated if the current policy evaluates to TRUE. Specify one of the following values: * NEXT - Evaluate the policy with the next higher priority number. * END - End policy evaluation. * USE_INVOCATION_RESULT - Applicable if this policy invokes another policy label. If the final goto in the invoked policy label has a value of END, the evaluation stops. If the final goto is anything other than END, the current policy label performs a NEXT. * An expression that evaluates to a number. If you specify an expression, the number to which it evaluates determines the next policy to evaluate, as follows: * If the expression evaluates to a higher numbered priority, the policy with that priority is evaluated next. * If the expression evaluates to the priority of the current policy, the policy with the next higher numbered priority is evaluated next. * If the expression evaluates to a priority number that is numerically higher than the highest numbered priority, policy evaluation ends. An UNDEF event is triggered if: * The expression is invalid. * The expression evaluates to a priority number that is numerically lower than the current policy's priority. * The expression evaluates to a priority number that is between the current policy's priority number (say, 30) and the highest priority number (say, 100), but does not match any configured priority number (for example, the expression evaluates to the number 85). This example assumes that the priority number increments by 10 for every successive policy, and therefore a priority number of 85 does not exist in the policy label. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .PARAMETER PassThru Return details about the created authenticationvserver_authenticationsamlpolicy_binding item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationvserverauthenticationsamlpolicybinding -name <string> An example how to add authenticationvserver_authenticationsamlpolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationvserverauthenticationsamlpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationsamlpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Policy, [double]$Priority, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Nextfactor, [string]$Gotopriorityexpression, [ValidateSet('REQUEST', 'RESPONSE', 'ICA_REQUEST', 'OTHERTCP_REQUEST', 'AAA_REQUEST', 'AAA_RESPONSE')] [string]$Bindpoint, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationsamlpolicybinding: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('policy') ) { $payload.Add('policy', $policy) } if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) } if ( $PSBoundParameters.ContainsKey('secondary') ) { $payload.Add('secondary', $secondary) } if ( $PSBoundParameters.ContainsKey('groupextraction') ) { $payload.Add('groupextraction', $groupextraction) } if ( $PSBoundParameters.ContainsKey('nextfactor') ) { $payload.Add('nextfactor', $nextfactor) } if ( $PSBoundParameters.ContainsKey('gotopriorityexpression') ) { $payload.Add('gotopriorityexpression', $gotopriorityexpression) } if ( $PSBoundParameters.ContainsKey('bindpoint') ) { $payload.Add('bindpoint', $bindpoint) } if ( $PSCmdlet.ShouldProcess("authenticationvserver_authenticationsamlpolicy_binding", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationvserver_authenticationsamlpolicy_binding -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationvserverauthenticationsamlpolicybinding -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationsamlpolicybinding: Finished" } } function Invoke-ADCDeleteAuthenticationvserverauthenticationsamlpolicybinding { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationsamlpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Secondary Bind the authentication policy to the secondary chain. Provides for multifactor authentication in which a user must authenticate via both a primary authentication method and, afterward, via a secondary authentication method. Because user groups are aggregated across authentication systems, usernames must be the same on all authentication servers. Passwords can be different. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationvserverauthenticationsamlpolicybinding -Name <string> An example how to delete authenticationvserver_authenticationsamlpolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationvserverauthenticationsamlpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationsamlpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name, [string]$Policy, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Bindpoint ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationsamlpolicybinding: Starting" } process { try { $arguments = @{ } if ( $PSBoundParameters.ContainsKey('Policy') ) { $arguments.Add('policy', $Policy) } if ( $PSBoundParameters.ContainsKey('Secondary') ) { $arguments.Add('secondary', $Secondary) } if ( $PSBoundParameters.ContainsKey('Groupextraction') ) { $arguments.Add('groupextraction', $Groupextraction) } if ( $PSBoundParameters.ContainsKey('Bindpoint') ) { $arguments.Add('bindpoint', $Bindpoint) } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationvserver_authenticationsamlpolicy_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationsamlpolicybinding: Finished" } } function Invoke-ADCGetAuthenticationvserverauthenticationsamlpolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationsamlpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER GetAll Retrieve all authenticationvserver_authenticationsamlpolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationvserver_authenticationsamlpolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationsamlpolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationsamlpolicybinding -GetAll Get all authenticationvserver_authenticationsamlpolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationsamlpolicybinding -Count Get the number of authenticationvserver_authenticationsamlpolicy_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationsamlpolicybinding -name <string> Get authenticationvserver_authenticationsamlpolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationsamlpolicybinding -Filter @{ 'name'='<value>' } Get authenticationvserver_authenticationsamlpolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationvserverauthenticationsamlpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationsamlpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationsamlpolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationvserver_authenticationsamlpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationsamlpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationvserver_authenticationsamlpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationsamlpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationvserver_authenticationsamlpolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationsamlpolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationvserver_authenticationsamlpolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationsamlpolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationvserver_authenticationsamlpolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationsamlpolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationsamlpolicybinding: Ended" } } function Invoke-ADCAddAuthenticationvserverauthenticationtacacspolicybinding { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationtacacspolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Priority The priority, if any, of the vpn vserver policy. .PARAMETER Secondary Bind the authentication policy to the secondary chain. Provides for multifactor authentication in which a user must authenticate via both a primary authentication method and, afterward, via a secondary authentication method. Because user groups are aggregated across authentication systems, usernames must be the same on all authentication servers. Passwords can be different. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Nextfactor Applicable only while binding advance authentication policy as classic authentication policy does not support nFactor. .PARAMETER Gotopriorityexpression Applicable only to advance authentication policy. Expression or other value specifying the next policy to be evaluated if the current policy evaluates to TRUE. Specify one of the following values: * NEXT - Evaluate the policy with the next higher priority number. * END - End policy evaluation. * USE_INVOCATION_RESULT - Applicable if this policy invokes another policy label. If the final goto in the invoked policy label has a value of END, the evaluation stops. If the final goto is anything other than END, the current policy label performs a NEXT. * An expression that evaluates to a number. If you specify an expression, the number to which it evaluates determines the next policy to evaluate, as follows: * If the expression evaluates to a higher numbered priority, the policy with that priority is evaluated next. * If the expression evaluates to the priority of the current policy, the policy with the next higher numbered priority is evaluated next. * If the expression evaluates to a priority number that is numerically higher than the highest numbered priority, policy evaluation ends. An UNDEF event is triggered if: * The expression is invalid. * The expression evaluates to a priority number that is numerically lower than the current policy's priority. * The expression evaluates to a priority number that is between the current policy's priority number (say, 30) and the highest priority number (say, 100), but does not match any configured priority number (for example, the expression evaluates to the number 85). This example assumes that the priority number increments by 10 for every successive policy, and therefore a priority number of 85 does not exist in the policy label. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .PARAMETER PassThru Return details about the created authenticationvserver_authenticationtacacspolicy_binding item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationvserverauthenticationtacacspolicybinding -name <string> An example how to add authenticationvserver_authenticationtacacspolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationvserverauthenticationtacacspolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationtacacspolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Policy, [double]$Priority, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Nextfactor, [string]$Gotopriorityexpression, [ValidateSet('REQUEST', 'RESPONSE', 'ICA_REQUEST', 'OTHERTCP_REQUEST', 'AAA_REQUEST', 'AAA_RESPONSE')] [string]$Bindpoint, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationtacacspolicybinding: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('policy') ) { $payload.Add('policy', $policy) } if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) } if ( $PSBoundParameters.ContainsKey('secondary') ) { $payload.Add('secondary', $secondary) } if ( $PSBoundParameters.ContainsKey('groupextraction') ) { $payload.Add('groupextraction', $groupextraction) } if ( $PSBoundParameters.ContainsKey('nextfactor') ) { $payload.Add('nextfactor', $nextfactor) } if ( $PSBoundParameters.ContainsKey('gotopriorityexpression') ) { $payload.Add('gotopriorityexpression', $gotopriorityexpression) } if ( $PSBoundParameters.ContainsKey('bindpoint') ) { $payload.Add('bindpoint', $bindpoint) } if ( $PSCmdlet.ShouldProcess("authenticationvserver_authenticationtacacspolicy_binding", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationvserver_authenticationtacacspolicy_binding -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationvserverauthenticationtacacspolicybinding -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationtacacspolicybinding: Finished" } } function Invoke-ADCDeleteAuthenticationvserverauthenticationtacacspolicybinding { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationtacacspolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Secondary Bind the authentication policy to the secondary chain. Provides for multifactor authentication in which a user must authenticate via both a primary authentication method and, afterward, via a secondary authentication method. Because user groups are aggregated across authentication systems, usernames must be the same on all authentication servers. Passwords can be different. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationvserverauthenticationtacacspolicybinding -Name <string> An example how to delete authenticationvserver_authenticationtacacspolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationvserverauthenticationtacacspolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationtacacspolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name, [string]$Policy, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Bindpoint ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationtacacspolicybinding: Starting" } process { try { $arguments = @{ } if ( $PSBoundParameters.ContainsKey('Policy') ) { $arguments.Add('policy', $Policy) } if ( $PSBoundParameters.ContainsKey('Secondary') ) { $arguments.Add('secondary', $Secondary) } if ( $PSBoundParameters.ContainsKey('Groupextraction') ) { $arguments.Add('groupextraction', $Groupextraction) } if ( $PSBoundParameters.ContainsKey('Bindpoint') ) { $arguments.Add('bindpoint', $Bindpoint) } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationvserver_authenticationtacacspolicy_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationtacacspolicybinding: Finished" } } function Invoke-ADCGetAuthenticationvserverauthenticationtacacspolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationtacacspolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER GetAll Retrieve all authenticationvserver_authenticationtacacspolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationvserver_authenticationtacacspolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationtacacspolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationtacacspolicybinding -GetAll Get all authenticationvserver_authenticationtacacspolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationtacacspolicybinding -Count Get the number of authenticationvserver_authenticationtacacspolicy_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationtacacspolicybinding -name <string> Get authenticationvserver_authenticationtacacspolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationtacacspolicybinding -Filter @{ 'name'='<value>' } Get authenticationvserver_authenticationtacacspolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationvserverauthenticationtacacspolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationtacacspolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationtacacspolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationvserver_authenticationtacacspolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationtacacspolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationvserver_authenticationtacacspolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationtacacspolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationvserver_authenticationtacacspolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationtacacspolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationvserver_authenticationtacacspolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationtacacspolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationvserver_authenticationtacacspolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationtacacspolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationtacacspolicybinding: Ended" } } function Invoke-ADCAddAuthenticationvserverauthenticationwebauthpolicybinding { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationwebauthpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Priority The priority, if any, of the vpn vserver policy. .PARAMETER Secondary Bind the authentication policy to the secondary chain. Provides for multifactor authentication in which a user must authenticate via both a primary authentication method and, afterward, via a secondary authentication method. Because user groups are aggregated across authentication systems, usernames must be the same on all authentication servers. Passwords can be different. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Nextfactor Applicable only while binding advance authentication policy as classic authentication policy does not support nFactor. .PARAMETER Gotopriorityexpression Applicable only to advance authentication policy. Expression or other value specifying the next policy to be evaluated if the current policy evaluates to TRUE. Specify one of the following values: * NEXT - Evaluate the policy with the next higher priority number. * END - End policy evaluation. * USE_INVOCATION_RESULT - Applicable if this policy invokes another policy label. If the final goto in the invoked policy label has a value of END, the evaluation stops. If the final goto is anything other than END, the current policy label performs a NEXT. * An expression that evaluates to a number. If you specify an expression, the number to which it evaluates determines the next policy to evaluate, as follows: * If the expression evaluates to a higher numbered priority, the policy with that priority is evaluated next. * If the expression evaluates to the priority of the current policy, the policy with the next higher numbered priority is evaluated next. * If the expression evaluates to a priority number that is numerically higher than the highest numbered priority, policy evaluation ends. An UNDEF event is triggered if: * The expression is invalid. * The expression evaluates to a priority number that is numerically lower than the current policy's priority. * The expression evaluates to a priority number that is between the current policy's priority number (say, 30) and the highest priority number (say, 100), but does not match any configured priority number (for example, the expression evaluates to the number 85). This example assumes that the priority number increments by 10 for every successive policy, and therefore a priority number of 85 does not exist in the policy label. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .PARAMETER PassThru Return details about the created authenticationvserver_authenticationwebauthpolicy_binding item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationvserverauthenticationwebauthpolicybinding -name <string> An example how to add authenticationvserver_authenticationwebauthpolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationvserverauthenticationwebauthpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationwebauthpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Policy, [double]$Priority, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Nextfactor, [string]$Gotopriorityexpression, [ValidateSet('REQUEST', 'RESPONSE', 'ICA_REQUEST', 'OTHERTCP_REQUEST', 'AAA_REQUEST', 'AAA_RESPONSE')] [string]$Bindpoint, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationwebauthpolicybinding: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('policy') ) { $payload.Add('policy', $policy) } if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) } if ( $PSBoundParameters.ContainsKey('secondary') ) { $payload.Add('secondary', $secondary) } if ( $PSBoundParameters.ContainsKey('groupextraction') ) { $payload.Add('groupextraction', $groupextraction) } if ( $PSBoundParameters.ContainsKey('nextfactor') ) { $payload.Add('nextfactor', $nextfactor) } if ( $PSBoundParameters.ContainsKey('gotopriorityexpression') ) { $payload.Add('gotopriorityexpression', $gotopriorityexpression) } if ( $PSBoundParameters.ContainsKey('bindpoint') ) { $payload.Add('bindpoint', $bindpoint) } if ( $PSCmdlet.ShouldProcess("authenticationvserver_authenticationwebauthpolicy_binding", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationvserver_authenticationwebauthpolicy_binding -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationvserverauthenticationwebauthpolicybinding -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationvserverauthenticationwebauthpolicybinding: Finished" } } function Invoke-ADCDeleteAuthenticationvserverauthenticationwebauthpolicybinding { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Binding object showing the authenticationwebauthpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Secondary Bind the authentication policy to the secondary chain. Provides for multifactor authentication in which a user must authenticate via both a primary authentication method and, afterward, via a secondary authentication method. Because user groups are aggregated across authentication systems, usernames must be the same on all authentication servers. Passwords can be different. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationvserverauthenticationwebauthpolicybinding -Name <string> An example how to delete authenticationvserver_authenticationwebauthpolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationvserverauthenticationwebauthpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationwebauthpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name, [string]$Policy, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Bindpoint ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationwebauthpolicybinding: Starting" } process { try { $arguments = @{ } if ( $PSBoundParameters.ContainsKey('Policy') ) { $arguments.Add('policy', $Policy) } if ( $PSBoundParameters.ContainsKey('Secondary') ) { $arguments.Add('secondary', $Secondary) } if ( $PSBoundParameters.ContainsKey('Groupextraction') ) { $arguments.Add('groupextraction', $Groupextraction) } if ( $PSBoundParameters.ContainsKey('Bindpoint') ) { $arguments.Add('bindpoint', $Bindpoint) } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationvserver_authenticationwebauthpolicy_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverauthenticationwebauthpolicybinding: Finished" } } function Invoke-ADCGetAuthenticationvserverauthenticationwebauthpolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationwebauthpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER GetAll Retrieve all authenticationvserver_authenticationwebauthpolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationvserver_authenticationwebauthpolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationwebauthpolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationwebauthpolicybinding -GetAll Get all authenticationvserver_authenticationwebauthpolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationwebauthpolicybinding -Count Get the number of authenticationvserver_authenticationwebauthpolicy_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationwebauthpolicybinding -name <string> Get authenticationvserver_authenticationwebauthpolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverauthenticationwebauthpolicybinding -Filter @{ 'name'='<value>' } Get authenticationvserver_authenticationwebauthpolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationvserverauthenticationwebauthpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_authenticationwebauthpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationwebauthpolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationvserver_authenticationwebauthpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationwebauthpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationvserver_authenticationwebauthpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationwebauthpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationvserver_authenticationwebauthpolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationwebauthpolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationvserver_authenticationwebauthpolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationwebauthpolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationvserver_authenticationwebauthpolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_authenticationwebauthpolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationvserverauthenticationwebauthpolicybinding: Ended" } } function Invoke-ADCGetAuthenticationvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object which returns the resources bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server. .PARAMETER GetAll Retrieve all authenticationvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverbinding -GetAll Get all authenticationvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverbinding -name <string> Get authenticationvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverbinding -Filter @{ 'name'='<value>' } Get authenticationvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationvserverbinding: Ended" } } function Invoke-ADCAddAuthenticationvservercachepolicybinding { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Binding object showing the cachepolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Priority The priority, if any, of the vpn vserver policy. .PARAMETER Secondary Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Nextfactor Applicable only while binding advance authentication policy as classic authentication policy does not support nFactor. .PARAMETER Gotopriorityexpression Expression specifying the priority of the next policy which will get evaluated if the current policy rule evaluates to TRUE. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .PARAMETER PassThru Return details about the created authenticationvserver_cachepolicy_binding item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationvservercachepolicybinding -name <string> An example how to add authenticationvserver_cachepolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationvservercachepolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_cachepolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Policy, [double]$Priority, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Nextfactor, [string]$Gotopriorityexpression, [ValidateSet('REQUEST', 'RESPONSE', 'ICA_REQUEST', 'OTHERTCP_REQUEST', 'AAA_REQUEST', 'AAA_RESPONSE')] [string]$Bindpoint, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationvservercachepolicybinding: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('policy') ) { $payload.Add('policy', $policy) } if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) } if ( $PSBoundParameters.ContainsKey('secondary') ) { $payload.Add('secondary', $secondary) } if ( $PSBoundParameters.ContainsKey('groupextraction') ) { $payload.Add('groupextraction', $groupextraction) } if ( $PSBoundParameters.ContainsKey('nextfactor') ) { $payload.Add('nextfactor', $nextfactor) } if ( $PSBoundParameters.ContainsKey('gotopriorityexpression') ) { $payload.Add('gotopriorityexpression', $gotopriorityexpression) } if ( $PSBoundParameters.ContainsKey('bindpoint') ) { $payload.Add('bindpoint', $bindpoint) } if ( $PSCmdlet.ShouldProcess("authenticationvserver_cachepolicy_binding", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationvserver_cachepolicy_binding -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationvservercachepolicybinding -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationvservercachepolicybinding: Finished" } } function Invoke-ADCDeleteAuthenticationvservercachepolicybinding { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Binding object showing the cachepolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Secondary Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationvservercachepolicybinding -Name <string> An example how to delete authenticationvserver_cachepolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationvservercachepolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_cachepolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name, [string]$Policy, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Bindpoint ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationvservercachepolicybinding: Starting" } process { try { $arguments = @{ } if ( $PSBoundParameters.ContainsKey('Policy') ) { $arguments.Add('policy', $Policy) } if ( $PSBoundParameters.ContainsKey('Secondary') ) { $arguments.Add('secondary', $Secondary) } if ( $PSBoundParameters.ContainsKey('Groupextraction') ) { $arguments.Add('groupextraction', $Groupextraction) } if ( $PSBoundParameters.ContainsKey('Bindpoint') ) { $arguments.Add('bindpoint', $Bindpoint) } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationvserver_cachepolicy_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationvservercachepolicybinding: Finished" } } function Invoke-ADCGetAuthenticationvservercachepolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the cachepolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER GetAll Retrieve all authenticationvserver_cachepolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationvserver_cachepolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvservercachepolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvservercachepolicybinding -GetAll Get all authenticationvserver_cachepolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvservercachepolicybinding -Count Get the number of authenticationvserver_cachepolicy_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvservercachepolicybinding -name <string> Get authenticationvserver_cachepolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvservercachepolicybinding -Filter @{ 'name'='<value>' } Get authenticationvserver_cachepolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationvservercachepolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_cachepolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationvservercachepolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationvserver_cachepolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_cachepolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationvserver_cachepolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_cachepolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationvserver_cachepolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_cachepolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationvserver_cachepolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_cachepolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationvserver_cachepolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_cachepolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationvservercachepolicybinding: Ended" } } function Invoke-ADCAddAuthenticationvservercspolicybinding { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Binding object showing the cspolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Priority The priority, if any, of the vpn vserver policy. .PARAMETER Secondary Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Nextfactor Applicable only while binding advance authentication policy as classic authentication policy does not support nFactor. .PARAMETER Gotopriorityexpression Expression specifying the priority of the next policy which will get evaluated if the current policy rule evaluates to TRUE. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .PARAMETER PassThru Return details about the created authenticationvserver_cspolicy_binding item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationvservercspolicybinding -name <string> An example how to add authenticationvserver_cspolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationvservercspolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_cspolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Policy, [double]$Priority, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Nextfactor, [string]$Gotopriorityexpression, [ValidateSet('REQUEST', 'RESPONSE', 'ICA_REQUEST', 'OTHERTCP_REQUEST', 'AAA_REQUEST', 'AAA_RESPONSE')] [string]$Bindpoint, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationvservercspolicybinding: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('policy') ) { $payload.Add('policy', $policy) } if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) } if ( $PSBoundParameters.ContainsKey('secondary') ) { $payload.Add('secondary', $secondary) } if ( $PSBoundParameters.ContainsKey('groupextraction') ) { $payload.Add('groupextraction', $groupextraction) } if ( $PSBoundParameters.ContainsKey('nextfactor') ) { $payload.Add('nextfactor', $nextfactor) } if ( $PSBoundParameters.ContainsKey('gotopriorityexpression') ) { $payload.Add('gotopriorityexpression', $gotopriorityexpression) } if ( $PSBoundParameters.ContainsKey('bindpoint') ) { $payload.Add('bindpoint', $bindpoint) } if ( $PSCmdlet.ShouldProcess("authenticationvserver_cspolicy_binding", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationvserver_cspolicy_binding -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationvservercspolicybinding -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationvservercspolicybinding: Finished" } } function Invoke-ADCDeleteAuthenticationvservercspolicybinding { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Binding object showing the cspolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Secondary Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationvservercspolicybinding -Name <string> An example how to delete authenticationvserver_cspolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationvservercspolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_cspolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name, [string]$Policy, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Bindpoint ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationvservercspolicybinding: Starting" } process { try { $arguments = @{ } if ( $PSBoundParameters.ContainsKey('Policy') ) { $arguments.Add('policy', $Policy) } if ( $PSBoundParameters.ContainsKey('Secondary') ) { $arguments.Add('secondary', $Secondary) } if ( $PSBoundParameters.ContainsKey('Groupextraction') ) { $arguments.Add('groupextraction', $Groupextraction) } if ( $PSBoundParameters.ContainsKey('Bindpoint') ) { $arguments.Add('bindpoint', $Bindpoint) } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationvserver_cspolicy_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationvservercspolicybinding: Finished" } } function Invoke-ADCGetAuthenticationvservercspolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the cspolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER GetAll Retrieve all authenticationvserver_cspolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationvserver_cspolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvservercspolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvservercspolicybinding -GetAll Get all authenticationvserver_cspolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvservercspolicybinding -Count Get the number of authenticationvserver_cspolicy_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvservercspolicybinding -name <string> Get authenticationvserver_cspolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvservercspolicybinding -Filter @{ 'name'='<value>' } Get authenticationvserver_cspolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationvservercspolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_cspolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationvservercspolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationvserver_cspolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_cspolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationvserver_cspolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_cspolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationvserver_cspolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_cspolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationvserver_cspolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_cspolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationvserver_cspolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_cspolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationvservercspolicybinding: Ended" } } function Invoke-ADCAddAuthenticationvserverresponderpolicybinding { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Binding object showing the responderpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Priority The priority, if any, of the vpn vserver policy. .PARAMETER Secondary Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Nextfactor Applicable only while binding advance authentication policy as classic authentication policy does not support nFactor. .PARAMETER Gotopriorityexpression Expression specifying the priority of the next policy which will get evaluated if the current policy rule evaluates to TRUE. .PARAMETER Bindpoint Bindpoint to which the policy is bound. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .PARAMETER PassThru Return details about the created authenticationvserver_responderpolicy_binding item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationvserverresponderpolicybinding -name <string> An example how to add authenticationvserver_responderpolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationvserverresponderpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_responderpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Policy, [double]$Priority, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Nextfactor, [string]$Gotopriorityexpression, [ValidateSet('REQUEST', 'RESPONSE', 'ICA_REQUEST', 'OTHERTCP_REQUEST', 'AAA_REQUEST', 'AAA_RESPONSE')] [string]$Bindpoint, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationvserverresponderpolicybinding: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('policy') ) { $payload.Add('policy', $policy) } if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) } if ( $PSBoundParameters.ContainsKey('secondary') ) { $payload.Add('secondary', $secondary) } if ( $PSBoundParameters.ContainsKey('groupextraction') ) { $payload.Add('groupextraction', $groupextraction) } if ( $PSBoundParameters.ContainsKey('nextfactor') ) { $payload.Add('nextfactor', $nextfactor) } if ( $PSBoundParameters.ContainsKey('gotopriorityexpression') ) { $payload.Add('gotopriorityexpression', $gotopriorityexpression) } if ( $PSBoundParameters.ContainsKey('bindpoint') ) { $payload.Add('bindpoint', $bindpoint) } if ( $PSCmdlet.ShouldProcess("authenticationvserver_responderpolicy_binding", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationvserver_responderpolicy_binding -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationvserverresponderpolicybinding -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationvserverresponderpolicybinding: Finished" } } function Invoke-ADCDeleteAuthenticationvserverresponderpolicybinding { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Binding object showing the responderpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Secondary Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Bindpoint Bindpoint to which the policy is bound. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationvserverresponderpolicybinding -Name <string> An example how to delete authenticationvserver_responderpolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationvserverresponderpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_responderpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name, [string]$Policy, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Bindpoint ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverresponderpolicybinding: Starting" } process { try { $arguments = @{ } if ( $PSBoundParameters.ContainsKey('Policy') ) { $arguments.Add('policy', $Policy) } if ( $PSBoundParameters.ContainsKey('Secondary') ) { $arguments.Add('secondary', $Secondary) } if ( $PSBoundParameters.ContainsKey('Groupextraction') ) { $arguments.Add('groupextraction', $Groupextraction) } if ( $PSBoundParameters.ContainsKey('Bindpoint') ) { $arguments.Add('bindpoint', $Bindpoint) } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationvserver_responderpolicy_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationvserverresponderpolicybinding: Finished" } } function Invoke-ADCGetAuthenticationvserverresponderpolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the responderpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER GetAll Retrieve all authenticationvserver_responderpolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationvserver_responderpolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverresponderpolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverresponderpolicybinding -GetAll Get all authenticationvserver_responderpolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverresponderpolicybinding -Count Get the number of authenticationvserver_responderpolicy_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverresponderpolicybinding -name <string> Get authenticationvserver_responderpolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvserverresponderpolicybinding -Filter @{ 'name'='<value>' } Get authenticationvserver_responderpolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationvserverresponderpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_responderpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationvserverresponderpolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationvserver_responderpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_responderpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationvserver_responderpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_responderpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationvserver_responderpolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_responderpolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationvserver_responderpolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_responderpolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationvserver_responderpolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_responderpolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationvserverresponderpolicybinding: Ended" } } function Invoke-ADCAddAuthenticationvservertmsessionpolicybinding { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Binding object showing the tmsessionpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Priority The priority, if any, of the vpn vserver policy. .PARAMETER Secondary Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Nextfactor Applicable only while binding advance authentication policy as classic authentication policy does not support nFactor. .PARAMETER Gotopriorityexpression Expression specifying the priority of the next policy which will get evaluated if the current policy rule evaluates to TRUE. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .PARAMETER PassThru Return details about the created authenticationvserver_tmsessionpolicy_binding item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationvservertmsessionpolicybinding -name <string> An example how to add authenticationvserver_tmsessionpolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationvservertmsessionpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_tmsessionpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Policy, [double]$Priority, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Nextfactor, [string]$Gotopriorityexpression, [ValidateSet('REQUEST', 'RESPONSE', 'ICA_REQUEST', 'OTHERTCP_REQUEST', 'AAA_REQUEST', 'AAA_RESPONSE')] [string]$Bindpoint, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationvservertmsessionpolicybinding: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('policy') ) { $payload.Add('policy', $policy) } if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) } if ( $PSBoundParameters.ContainsKey('secondary') ) { $payload.Add('secondary', $secondary) } if ( $PSBoundParameters.ContainsKey('groupextraction') ) { $payload.Add('groupextraction', $groupextraction) } if ( $PSBoundParameters.ContainsKey('nextfactor') ) { $payload.Add('nextfactor', $nextfactor) } if ( $PSBoundParameters.ContainsKey('gotopriorityexpression') ) { $payload.Add('gotopriorityexpression', $gotopriorityexpression) } if ( $PSBoundParameters.ContainsKey('bindpoint') ) { $payload.Add('bindpoint', $bindpoint) } if ( $PSCmdlet.ShouldProcess("authenticationvserver_tmsessionpolicy_binding", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationvserver_tmsessionpolicy_binding -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationvservertmsessionpolicybinding -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationvservertmsessionpolicybinding: Finished" } } function Invoke-ADCDeleteAuthenticationvservertmsessionpolicybinding { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Binding object showing the tmsessionpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Policy The name of the policy, if any, bound to the authentication vserver. .PARAMETER Secondary Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Groupextraction Applicable only while bindind classic authentication policy as advance authentication policy use nFactor. .PARAMETER Bindpoint Bind point to which to bind the policy. Applies only to rewrite and cache policies. If you do not set this parameter, the policy is bound to REQ_DEFAULT or RES_DEFAULT, depending on whether the policy rule is a response-time or a request-time expression. Possible values = REQUEST, RESPONSE, ICA_REQUEST, OTHERTCP_REQUEST, AAA_REQUEST, AAA_RESPONSE .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationvservertmsessionpolicybinding -Name <string> An example how to delete authenticationvserver_tmsessionpolicy_binding configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationvservertmsessionpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_tmsessionpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name, [string]$Policy, [boolean]$Secondary, [boolean]$Groupextraction, [string]$Bindpoint ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationvservertmsessionpolicybinding: Starting" } process { try { $arguments = @{ } if ( $PSBoundParameters.ContainsKey('Policy') ) { $arguments.Add('policy', $Policy) } if ( $PSBoundParameters.ContainsKey('Secondary') ) { $arguments.Add('secondary', $Secondary) } if ( $PSBoundParameters.ContainsKey('Groupextraction') ) { $arguments.Add('groupextraction', $Groupextraction) } if ( $PSBoundParameters.ContainsKey('Bindpoint') ) { $arguments.Add('bindpoint', $Bindpoint) } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationvserver_tmsessionpolicy_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationvservertmsessionpolicybinding: Finished" } } function Invoke-ADCGetAuthenticationvservertmsessionpolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the tmsessionpolicy that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER GetAll Retrieve all authenticationvserver_tmsessionpolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationvserver_tmsessionpolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvservertmsessionpolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvservertmsessionpolicybinding -GetAll Get all authenticationvserver_tmsessionpolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvservertmsessionpolicybinding -Count Get the number of authenticationvserver_tmsessionpolicy_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvservertmsessionpolicybinding -name <string> Get authenticationvserver_tmsessionpolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvservertmsessionpolicybinding -Filter @{ 'name'='<value>' } Get authenticationvserver_tmsessionpolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationvservertmsessionpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_tmsessionpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationvservertmsessionpolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationvserver_tmsessionpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_tmsessionpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationvserver_tmsessionpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_tmsessionpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationvserver_tmsessionpolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_tmsessionpolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationvserver_tmsessionpolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_tmsessionpolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationvserver_tmsessionpolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_tmsessionpolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationvservertmsessionpolicybinding: Ended" } } function Invoke-ADCAddAuthenticationvservervpnportalthemebinding { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Binding object showing the vpnportaltheme that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Portaltheme Theme for Authentication virtual server Login portal. .PARAMETER PassThru Return details about the created authenticationvserver_vpnportaltheme_binding item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationvservervpnportalthemebinding -name <string> An example how to add authenticationvserver_vpnportaltheme_binding configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationvservervpnportalthemebinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_vpnportaltheme_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [string]$Portaltheme, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationvservervpnportalthemebinding: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('portaltheme') ) { $payload.Add('portaltheme', $portaltheme) } if ( $PSCmdlet.ShouldProcess("authenticationvserver_vpnportaltheme_binding", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationvserver_vpnportaltheme_binding -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationvservervpnportalthemebinding -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationvservervpnportalthemebinding: Finished" } } function Invoke-ADCDeleteAuthenticationvservervpnportalthemebinding { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Binding object showing the vpnportaltheme that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER Portaltheme Theme for Authentication virtual server Login portal. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationvservervpnportalthemebinding -Name <string> An example how to delete authenticationvserver_vpnportaltheme_binding configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationvservervpnportalthemebinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_vpnportaltheme_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name, [string]$Portaltheme ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationvservervpnportalthemebinding: Starting" } process { try { $arguments = @{ } if ( $PSBoundParameters.ContainsKey('Portaltheme') ) { $arguments.Add('portaltheme', $Portaltheme) } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationvserver_vpnportaltheme_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationvservervpnportalthemebinding: Finished" } } function Invoke-ADCGetAuthenticationvservervpnportalthemebinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the vpnportaltheme that can be bound to authenticationvserver. .PARAMETER Name Name of the authentication virtual server to which to bind the policy. .PARAMETER GetAll Retrieve all authenticationvserver_vpnportaltheme_binding object(s). .PARAMETER Count If specified, the count of the authenticationvserver_vpnportaltheme_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvservervpnportalthemebinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvservervpnportalthemebinding -GetAll Get all authenticationvserver_vpnportaltheme_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvservervpnportalthemebinding -Count Get the number of authenticationvserver_vpnportaltheme_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvservervpnportalthemebinding -name <string> Get authenticationvserver_vpnportaltheme_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationvservervpnportalthemebinding -Filter @{ 'name'='<value>' } Get authenticationvserver_vpnportaltheme_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationvservervpnportalthemebinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationvserver_vpnportaltheme_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationvservervpnportalthemebinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationvserver_vpnportaltheme_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_vpnportaltheme_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationvserver_vpnportaltheme_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_vpnportaltheme_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationvserver_vpnportaltheme_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_vpnportaltheme_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationvserver_vpnportaltheme_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_vpnportaltheme_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationvserver_vpnportaltheme_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationvserver_vpnportaltheme_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationvservervpnportalthemebinding: Ended" } } function Invoke-ADCUnsetAuthenticationwebauthaction { <# .SYNOPSIS Unset Authentication configuration Object. .DESCRIPTION Configuration for Web authentication action resource. .PARAMETER Name Name for the Web Authentication action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the profile is created. .PARAMETER Serverip IP address of the web server to be used for authentication. .PARAMETER Serverport Port on which the web server accepts connections. * in CLI is represented as 65535 in NITRO API .PARAMETER Fullreqexpr Exact HTTP request, in the form of an expression, which the Citrix ADC sends to the authentication server. The Citrix ADC does not check the validity of this request. One must manually validate the request. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER Attribute1 Expression that would be evaluated to extract attribute1 from the webauth response. .PARAMETER Attribute2 Expression that would be evaluated to extract attribute2 from the webauth response. .PARAMETER Attribute3 Expression that would be evaluated to extract attribute3 from the webauth response. .PARAMETER Attribute4 Expression that would be evaluated to extract attribute4 from the webauth response. .PARAMETER Attribute5 Expression that would be evaluated to extract attribute5 from the webauth response. .PARAMETER Attribute6 Expression that would be evaluated to extract attribute6 from the webauth response. .PARAMETER Attribute7 Expression that would be evaluated to extract attribute7 from the webauth response. .PARAMETER Attribute8 Expression that would be evaluated to extract attribute8 from the webauth response. .PARAMETER Attribute9 Expression that would be evaluated to extract attribute9 from the webauth response. .PARAMETER Attribute10 Expression that would be evaluated to extract attribute10 from the webauth response. .PARAMETER Attribute11 Expression that would be evaluated to extract attribute11 from the webauth response. .PARAMETER Attribute12 Expression that would be evaluated to extract attribute12 from the webauth response. .PARAMETER Attribute13 Expression that would be evaluated to extract attribute13 from the webauth response. .PARAMETER Attribute14 Expression that would be evaluated to extract attribute14 from the webauth response. .PARAMETER Attribute15 Expression that would be evaluated to extract attribute15 from the webauth response. .PARAMETER Attribute16 Expression that would be evaluated to extract attribute16 from the webauth response. .EXAMPLE PS C:\>Invoke-ADCUnsetAuthenticationwebauthaction -name <string> An example how to unset authenticationwebauthaction configuration Object(s). .NOTES File Name : Invoke-ADCUnsetAuthenticationwebauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationwebauthaction Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Boolean]$serverip, [Boolean]$serverport, [Boolean]$fullreqexpr, [Boolean]$defaultauthenticationgroup, [Boolean]$attribute1, [Boolean]$attribute2, [Boolean]$attribute3, [Boolean]$attribute4, [Boolean]$attribute5, [Boolean]$attribute6, [Boolean]$attribute7, [Boolean]$attribute8, [Boolean]$attribute9, [Boolean]$attribute10, [Boolean]$attribute11, [Boolean]$attribute12, [Boolean]$attribute13, [Boolean]$attribute14, [Boolean]$attribute15, [Boolean]$attribute16 ) begin { Write-Verbose "Invoke-ADCUnsetAuthenticationwebauthaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('serverip') ) { $payload.Add('serverip', $serverip) } if ( $PSBoundParameters.ContainsKey('serverport') ) { $payload.Add('serverport', $serverport) } if ( $PSBoundParameters.ContainsKey('fullreqexpr') ) { $payload.Add('fullreqexpr', $fullreqexpr) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('attribute1') ) { $payload.Add('attribute1', $attribute1) } if ( $PSBoundParameters.ContainsKey('attribute2') ) { $payload.Add('attribute2', $attribute2) } if ( $PSBoundParameters.ContainsKey('attribute3') ) { $payload.Add('attribute3', $attribute3) } if ( $PSBoundParameters.ContainsKey('attribute4') ) { $payload.Add('attribute4', $attribute4) } if ( $PSBoundParameters.ContainsKey('attribute5') ) { $payload.Add('attribute5', $attribute5) } if ( $PSBoundParameters.ContainsKey('attribute6') ) { $payload.Add('attribute6', $attribute6) } if ( $PSBoundParameters.ContainsKey('attribute7') ) { $payload.Add('attribute7', $attribute7) } if ( $PSBoundParameters.ContainsKey('attribute8') ) { $payload.Add('attribute8', $attribute8) } if ( $PSBoundParameters.ContainsKey('attribute9') ) { $payload.Add('attribute9', $attribute9) } if ( $PSBoundParameters.ContainsKey('attribute10') ) { $payload.Add('attribute10', $attribute10) } if ( $PSBoundParameters.ContainsKey('attribute11') ) { $payload.Add('attribute11', $attribute11) } if ( $PSBoundParameters.ContainsKey('attribute12') ) { $payload.Add('attribute12', $attribute12) } if ( $PSBoundParameters.ContainsKey('attribute13') ) { $payload.Add('attribute13', $attribute13) } if ( $PSBoundParameters.ContainsKey('attribute14') ) { $payload.Add('attribute14', $attribute14) } if ( $PSBoundParameters.ContainsKey('attribute15') ) { $payload.Add('attribute15', $attribute15) } if ( $PSBoundParameters.ContainsKey('attribute16') ) { $payload.Add('attribute16', $attribute16) } if ( $PSCmdlet.ShouldProcess("$name", "Unset Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type authenticationwebauthaction -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUnsetAuthenticationwebauthaction: Finished" } } function Invoke-ADCDeleteAuthenticationwebauthaction { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for Web authentication action resource. .PARAMETER Name Name for the Web Authentication action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the profile is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationwebauthaction -Name <string> An example how to delete authenticationwebauthaction configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationwebauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationwebauthaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationwebauthaction: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationwebauthaction -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationwebauthaction: Finished" } } function Invoke-ADCUpdateAuthenticationwebauthaction { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for Web authentication action resource. .PARAMETER Name Name for the Web Authentication action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the profile is created. .PARAMETER Serverip IP address of the web server to be used for authentication. .PARAMETER Serverport Port on which the web server accepts connections. * in CLI is represented as 65535 in NITRO API .PARAMETER Fullreqexpr Exact HTTP request, in the form of an expression, which the Citrix ADC sends to the authentication server. The Citrix ADC does not check the validity of this request. One must manually validate the request. .PARAMETER Scheme Type of scheme for the web server. Possible values = http, https .PARAMETER Successrule Expression, that checks to see if authentication is successful. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER Attribute1 Expression that would be evaluated to extract attribute1 from the webauth response. .PARAMETER Attribute2 Expression that would be evaluated to extract attribute2 from the webauth response. .PARAMETER Attribute3 Expression that would be evaluated to extract attribute3 from the webauth response. .PARAMETER Attribute4 Expression that would be evaluated to extract attribute4 from the webauth response. .PARAMETER Attribute5 Expression that would be evaluated to extract attribute5 from the webauth response. .PARAMETER Attribute6 Expression that would be evaluated to extract attribute6 from the webauth response. .PARAMETER Attribute7 Expression that would be evaluated to extract attribute7 from the webauth response. .PARAMETER Attribute8 Expression that would be evaluated to extract attribute8 from the webauth response. .PARAMETER Attribute9 Expression that would be evaluated to extract attribute9 from the webauth response. .PARAMETER Attribute10 Expression that would be evaluated to extract attribute10 from the webauth response. .PARAMETER Attribute11 Expression that would be evaluated to extract attribute11 from the webauth response. .PARAMETER Attribute12 Expression that would be evaluated to extract attribute12 from the webauth response. .PARAMETER Attribute13 Expression that would be evaluated to extract attribute13 from the webauth response. .PARAMETER Attribute14 Expression that would be evaluated to extract attribute14 from the webauth response. .PARAMETER Attribute15 Expression that would be evaluated to extract attribute15 from the webauth response. .PARAMETER Attribute16 Expression that would be evaluated to extract attribute16 from the webauth response. .PARAMETER PassThru Return details about the created authenticationwebauthaction item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationwebauthaction -name <string> An example how to update authenticationwebauthaction configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationwebauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationwebauthaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Serverip, [ValidateRange(1, 65535)] [int]$Serverport, [string]$Fullreqexpr, [ValidateSet('http', 'https')] [string]$Scheme, [string]$Successrule, [string]$Defaultauthenticationgroup, [string]$Attribute1, [string]$Attribute2, [string]$Attribute3, [string]$Attribute4, [string]$Attribute5, [string]$Attribute6, [string]$Attribute7, [string]$Attribute8, [string]$Attribute9, [string]$Attribute10, [string]$Attribute11, [string]$Attribute12, [string]$Attribute13, [string]$Attribute14, [string]$Attribute15, [string]$Attribute16, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationwebauthaction: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('serverip') ) { $payload.Add('serverip', $serverip) } if ( $PSBoundParameters.ContainsKey('serverport') ) { $payload.Add('serverport', $serverport) } if ( $PSBoundParameters.ContainsKey('fullreqexpr') ) { $payload.Add('fullreqexpr', $fullreqexpr) } if ( $PSBoundParameters.ContainsKey('scheme') ) { $payload.Add('scheme', $scheme) } if ( $PSBoundParameters.ContainsKey('successrule') ) { $payload.Add('successrule', $successrule) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('attribute1') ) { $payload.Add('attribute1', $attribute1) } if ( $PSBoundParameters.ContainsKey('attribute2') ) { $payload.Add('attribute2', $attribute2) } if ( $PSBoundParameters.ContainsKey('attribute3') ) { $payload.Add('attribute3', $attribute3) } if ( $PSBoundParameters.ContainsKey('attribute4') ) { $payload.Add('attribute4', $attribute4) } if ( $PSBoundParameters.ContainsKey('attribute5') ) { $payload.Add('attribute5', $attribute5) } if ( $PSBoundParameters.ContainsKey('attribute6') ) { $payload.Add('attribute6', $attribute6) } if ( $PSBoundParameters.ContainsKey('attribute7') ) { $payload.Add('attribute7', $attribute7) } if ( $PSBoundParameters.ContainsKey('attribute8') ) { $payload.Add('attribute8', $attribute8) } if ( $PSBoundParameters.ContainsKey('attribute9') ) { $payload.Add('attribute9', $attribute9) } if ( $PSBoundParameters.ContainsKey('attribute10') ) { $payload.Add('attribute10', $attribute10) } if ( $PSBoundParameters.ContainsKey('attribute11') ) { $payload.Add('attribute11', $attribute11) } if ( $PSBoundParameters.ContainsKey('attribute12') ) { $payload.Add('attribute12', $attribute12) } if ( $PSBoundParameters.ContainsKey('attribute13') ) { $payload.Add('attribute13', $attribute13) } if ( $PSBoundParameters.ContainsKey('attribute14') ) { $payload.Add('attribute14', $attribute14) } if ( $PSBoundParameters.ContainsKey('attribute15') ) { $payload.Add('attribute15', $attribute15) } if ( $PSBoundParameters.ContainsKey('attribute16') ) { $payload.Add('attribute16', $attribute16) } if ( $PSCmdlet.ShouldProcess("authenticationwebauthaction", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationwebauthaction -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationwebauthaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationwebauthaction: Finished" } } function Invoke-ADCAddAuthenticationwebauthaction { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for Web authentication action resource. .PARAMETER Name Name for the Web Authentication action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the profile is created. .PARAMETER Serverip IP address of the web server to be used for authentication. .PARAMETER Serverport Port on which the web server accepts connections. * in CLI is represented as 65535 in NITRO API .PARAMETER Fullreqexpr Exact HTTP request, in the form of an expression, which the Citrix ADC sends to the authentication server. The Citrix ADC does not check the validity of this request. One must manually validate the request. .PARAMETER Scheme Type of scheme for the web server. Possible values = http, https .PARAMETER Successrule Expression, that checks to see if authentication is successful. .PARAMETER Defaultauthenticationgroup This is the default group that is chosen when the authentication succeeds in addition to extracted groups. .PARAMETER Attribute1 Expression that would be evaluated to extract attribute1 from the webauth response. .PARAMETER Attribute2 Expression that would be evaluated to extract attribute2 from the webauth response. .PARAMETER Attribute3 Expression that would be evaluated to extract attribute3 from the webauth response. .PARAMETER Attribute4 Expression that would be evaluated to extract attribute4 from the webauth response. .PARAMETER Attribute5 Expression that would be evaluated to extract attribute5 from the webauth response. .PARAMETER Attribute6 Expression that would be evaluated to extract attribute6 from the webauth response. .PARAMETER Attribute7 Expression that would be evaluated to extract attribute7 from the webauth response. .PARAMETER Attribute8 Expression that would be evaluated to extract attribute8 from the webauth response. .PARAMETER Attribute9 Expression that would be evaluated to extract attribute9 from the webauth response. .PARAMETER Attribute10 Expression that would be evaluated to extract attribute10 from the webauth response. .PARAMETER Attribute11 Expression that would be evaluated to extract attribute11 from the webauth response. .PARAMETER Attribute12 Expression that would be evaluated to extract attribute12 from the webauth response. .PARAMETER Attribute13 Expression that would be evaluated to extract attribute13 from the webauth response. .PARAMETER Attribute14 Expression that would be evaluated to extract attribute14 from the webauth response. .PARAMETER Attribute15 Expression that would be evaluated to extract attribute15 from the webauth response. .PARAMETER Attribute16 Expression that would be evaluated to extract attribute16 from the webauth response. .PARAMETER PassThru Return details about the created authenticationwebauthaction item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationwebauthaction -name <string> -serverip <string> -serverport <int> -scheme <string> -successrule <string> An example how to add authenticationwebauthaction configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationwebauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationwebauthaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Serverip, [Parameter(Mandatory)] [ValidateRange(1, 65535)] [int]$Serverport, [string]$Fullreqexpr, [Parameter(Mandatory)] [ValidateSet('http', 'https')] [string]$Scheme, [Parameter(Mandatory)] [string]$Successrule, [string]$Defaultauthenticationgroup, [string]$Attribute1, [string]$Attribute2, [string]$Attribute3, [string]$Attribute4, [string]$Attribute5, [string]$Attribute6, [string]$Attribute7, [string]$Attribute8, [string]$Attribute9, [string]$Attribute10, [string]$Attribute11, [string]$Attribute12, [string]$Attribute13, [string]$Attribute14, [string]$Attribute15, [string]$Attribute16, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationwebauthaction: Starting" } process { try { $payload = @{ name = $name serverip = $serverip serverport = $serverport scheme = $scheme successrule = $successrule } if ( $PSBoundParameters.ContainsKey('fullreqexpr') ) { $payload.Add('fullreqexpr', $fullreqexpr) } if ( $PSBoundParameters.ContainsKey('defaultauthenticationgroup') ) { $payload.Add('defaultauthenticationgroup', $defaultauthenticationgroup) } if ( $PSBoundParameters.ContainsKey('attribute1') ) { $payload.Add('attribute1', $attribute1) } if ( $PSBoundParameters.ContainsKey('attribute2') ) { $payload.Add('attribute2', $attribute2) } if ( $PSBoundParameters.ContainsKey('attribute3') ) { $payload.Add('attribute3', $attribute3) } if ( $PSBoundParameters.ContainsKey('attribute4') ) { $payload.Add('attribute4', $attribute4) } if ( $PSBoundParameters.ContainsKey('attribute5') ) { $payload.Add('attribute5', $attribute5) } if ( $PSBoundParameters.ContainsKey('attribute6') ) { $payload.Add('attribute6', $attribute6) } if ( $PSBoundParameters.ContainsKey('attribute7') ) { $payload.Add('attribute7', $attribute7) } if ( $PSBoundParameters.ContainsKey('attribute8') ) { $payload.Add('attribute8', $attribute8) } if ( $PSBoundParameters.ContainsKey('attribute9') ) { $payload.Add('attribute9', $attribute9) } if ( $PSBoundParameters.ContainsKey('attribute10') ) { $payload.Add('attribute10', $attribute10) } if ( $PSBoundParameters.ContainsKey('attribute11') ) { $payload.Add('attribute11', $attribute11) } if ( $PSBoundParameters.ContainsKey('attribute12') ) { $payload.Add('attribute12', $attribute12) } if ( $PSBoundParameters.ContainsKey('attribute13') ) { $payload.Add('attribute13', $attribute13) } if ( $PSBoundParameters.ContainsKey('attribute14') ) { $payload.Add('attribute14', $attribute14) } if ( $PSBoundParameters.ContainsKey('attribute15') ) { $payload.Add('attribute15', $attribute15) } if ( $PSBoundParameters.ContainsKey('attribute16') ) { $payload.Add('attribute16', $attribute16) } if ( $PSCmdlet.ShouldProcess("authenticationwebauthaction", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationwebauthaction -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationwebauthaction -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationwebauthaction: Finished" } } function Invoke-ADCGetAuthenticationwebauthaction { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for Web authentication action resource. .PARAMETER Name Name for the Web Authentication action. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the profile is created. .PARAMETER GetAll Retrieve all authenticationwebauthaction object(s). .PARAMETER Count If specified, the count of the authenticationwebauthaction object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthaction Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthaction -GetAll Get all authenticationwebauthaction data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthaction -Count Get the number of authenticationwebauthaction objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthaction -name <string> Get authenticationwebauthaction object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthaction -Filter @{ 'name'='<value>' } Get authenticationwebauthaction data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationwebauthaction Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationwebauthaction/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationwebauthaction: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationwebauthaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationwebauthaction objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthaction -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationwebauthaction objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthaction -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationwebauthaction configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthaction -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationwebauthaction configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthaction -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationwebauthaction: Ended" } } function Invoke-ADCAddAuthenticationwebauthpolicy { <# .SYNOPSIS Add Authentication configuration Object. .DESCRIPTION Configuration for Web authentication policy resource. .PARAMETER Name Name for the WebAuth policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after LDAP policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to determine whether to attempt to authenticate the user with the Web server. .PARAMETER Action Name of the WebAuth action to perform if the policy matches. .PARAMETER PassThru Return details about the created authenticationwebauthpolicy item. .EXAMPLE PS C:\>Invoke-ADCAddAuthenticationwebauthpolicy -name <string> -rule <string> -action <string> An example how to add authenticationwebauthpolicy configuration Object(s). .NOTES File Name : Invoke-ADCAddAuthenticationwebauthpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationwebauthpolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Rule, [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Action, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCAddAuthenticationwebauthpolicy: Starting" } process { try { $payload = @{ name = $name rule = $rule action = $action } if ( $PSCmdlet.ShouldProcess("authenticationwebauthpolicy", "Add Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type authenticationwebauthpolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 201 Created #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationwebauthpolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCAddAuthenticationwebauthpolicy: Finished" } } function Invoke-ADCDeleteAuthenticationwebauthpolicy { <# .SYNOPSIS Delete Authentication configuration Object. .DESCRIPTION Configuration for Web authentication policy resource. .PARAMETER Name Name for the WebAuth policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after LDAP policy is created. .EXAMPLE PS C:\>Invoke-ADCDeleteAuthenticationwebauthpolicy -Name <string> An example how to delete authenticationwebauthpolicy configuration Object(s). .NOTES File Name : Invoke-ADCDeleteAuthenticationwebauthpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationwebauthpolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [string]$Name ) begin { Write-Verbose "Invoke-ADCDeleteAuthenticationwebauthpolicy: Starting" } process { try { $arguments = @{ } if ( $PSCmdlet.ShouldProcess("$name", "Delete Authentication configuration Object") ) { $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type authenticationwebauthpolicy -NitroPath nitro/v1/config -Resource $name -Arguments $arguments #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error Write-Output $response } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCDeleteAuthenticationwebauthpolicy: Finished" } } function Invoke-ADCUpdateAuthenticationwebauthpolicy { <# .SYNOPSIS Update Authentication configuration Object. .DESCRIPTION Configuration for Web authentication policy resource. .PARAMETER Name Name for the WebAuth policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after LDAP policy is created. .PARAMETER Rule Name of the Citrix ADC named rule, or an expression, that the policy uses to determine whether to attempt to authenticate the user with the Web server. .PARAMETER Action Name of the WebAuth action to perform if the policy matches. .PARAMETER PassThru Return details about the created authenticationwebauthpolicy item. .EXAMPLE PS C:\>Invoke-ADCUpdateAuthenticationwebauthpolicy -name <string> An example how to update authenticationwebauthpolicy configuration Object(s). .NOTES File Name : Invoke-ADCUpdateAuthenticationwebauthpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationwebauthpolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(Mandatory)] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [ValidateScript({ $_.Length -gt 1 })] [string]$Rule, [ValidateScript({ $_.Length -gt 1 })] [string]$Action, [Switch]$PassThru ) begin { Write-Verbose "Invoke-ADCUpdateAuthenticationwebauthpolicy: Starting" } process { try { $payload = @{ name = $name } if ( $PSBoundParameters.ContainsKey('rule') ) { $payload.Add('rule', $rule) } if ( $PSBoundParameters.ContainsKey('action') ) { $payload.Add('action', $action) } if ( $PSCmdlet.ShouldProcess("authenticationwebauthpolicy", "Update Authentication configuration Object") ) { $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type authenticationwebauthpolicy -Payload $payload -GetWarning #HTTP Status Code on Success: 200 OK #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error if ( $PSBoundParameters.ContainsKey('PassThru') ) { Write-Output (Invoke-ADCGetAuthenticationwebauthpolicy -Filter $payload) } else { Write-Output $result } } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" throw $_ } } end { Write-Verbose "Invoke-ADCUpdateAuthenticationwebauthpolicy: Finished" } } function Invoke-ADCGetAuthenticationwebauthpolicy { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Configuration for Web authentication policy resource. .PARAMETER Name Name for the WebAuth policy. Must begin with a letter, number, or the underscore character (_), and must contain only letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after LDAP policy is created. .PARAMETER GetAll Retrieve all authenticationwebauthpolicy object(s). .PARAMETER Count If specified, the count of the authenticationwebauthpolicy object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicy Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicy -GetAll Get all authenticationwebauthpolicy data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicy -Count Get the number of authenticationwebauthpolicy objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicy -name <string> Get authenticationwebauthpolicy object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicy -Filter @{ 'name'='<value>' } Get authenticationwebauthpolicy data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationwebauthpolicy Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationwebauthpolicy/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll, [Parameter(ParameterSetName = 'GetAll')] [Parameter(ParameterSetName = 'Get')] [Switch]$ViewSummary ) begin { Write-Verbose "Invoke-ADCGetAuthenticationwebauthpolicy: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ } Write-Verbose "Retrieving all authenticationwebauthpolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationwebauthpolicy objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationwebauthpolicy objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationwebauthpolicy configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationwebauthpolicy configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationwebauthpolicy: Ended" } } function Invoke-ADCGetAuthenticationwebauthpolicyauthenticationvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the authenticationvserver that can be bound to authenticationwebauthpolicy. .PARAMETER Name Name of the WebAuth policy. .PARAMETER GetAll Retrieve all authenticationwebauthpolicy_authenticationvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationwebauthpolicy_authenticationvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicyauthenticationvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicyauthenticationvserverbinding -GetAll Get all authenticationwebauthpolicy_authenticationvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicyauthenticationvserverbinding -Count Get the number of authenticationwebauthpolicy_authenticationvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicyauthenticationvserverbinding -name <string> Get authenticationwebauthpolicy_authenticationvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicyauthenticationvserverbinding -Filter @{ 'name'='<value>' } Get authenticationwebauthpolicy_authenticationvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationwebauthpolicyauthenticationvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationwebauthpolicy_authenticationvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationwebauthpolicyauthenticationvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationwebauthpolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationwebauthpolicy_authenticationvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationwebauthpolicy_authenticationvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationwebauthpolicy_authenticationvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationwebauthpolicy_authenticationvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_authenticationvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationwebauthpolicyauthenticationvserverbinding: Ended" } } function Invoke-ADCGetAuthenticationwebauthpolicybinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object which returns the resources bound to authenticationwebauthpolicy. .PARAMETER Name Name of the WebAuth policy. .PARAMETER GetAll Retrieve all authenticationwebauthpolicy_binding object(s). .PARAMETER Count If specified, the count of the authenticationwebauthpolicy_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicybinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicybinding -GetAll Get all authenticationwebauthpolicy_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicybinding -name <string> Get authenticationwebauthpolicy_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicybinding -Filter @{ 'name'='<value>' } Get authenticationwebauthpolicy_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationwebauthpolicybinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationwebauthpolicy_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationwebauthpolicybinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationwebauthpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationwebauthpolicy_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationwebauthpolicy_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationwebauthpolicy_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationwebauthpolicy_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationwebauthpolicybinding: Ended" } } function Invoke-ADCGetAuthenticationwebauthpolicysystemglobalbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the systemglobal that can be bound to authenticationwebauthpolicy. .PARAMETER Name Name of the WebAuth policy. .PARAMETER GetAll Retrieve all authenticationwebauthpolicy_systemglobal_binding object(s). .PARAMETER Count If specified, the count of the authenticationwebauthpolicy_systemglobal_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicysystemglobalbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicysystemglobalbinding -GetAll Get all authenticationwebauthpolicy_systemglobal_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicysystemglobalbinding -Count Get the number of authenticationwebauthpolicy_systemglobal_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicysystemglobalbinding -name <string> Get authenticationwebauthpolicy_systemglobal_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicysystemglobalbinding -Filter @{ 'name'='<value>' } Get authenticationwebauthpolicy_systemglobal_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationwebauthpolicysystemglobalbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationwebauthpolicy_systemglobal_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationwebauthpolicysystemglobalbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationwebauthpolicy_systemglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_systemglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationwebauthpolicy_systemglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_systemglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationwebauthpolicy_systemglobal_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_systemglobal_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationwebauthpolicy_systemglobal_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_systemglobal_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationwebauthpolicy_systemglobal_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_systemglobal_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationwebauthpolicysystemglobalbinding: Ended" } } function Invoke-ADCGetAuthenticationwebauthpolicyvpnglobalbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the vpnglobal that can be bound to authenticationwebauthpolicy. .PARAMETER Name Name of the WebAuth policy. .PARAMETER GetAll Retrieve all authenticationwebauthpolicy_vpnglobal_binding object(s). .PARAMETER Count If specified, the count of the authenticationwebauthpolicy_vpnglobal_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicyvpnglobalbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicyvpnglobalbinding -GetAll Get all authenticationwebauthpolicy_vpnglobal_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicyvpnglobalbinding -Count Get the number of authenticationwebauthpolicy_vpnglobal_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicyvpnglobalbinding -name <string> Get authenticationwebauthpolicy_vpnglobal_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicyvpnglobalbinding -Filter @{ 'name'='<value>' } Get authenticationwebauthpolicy_vpnglobal_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationwebauthpolicyvpnglobalbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationwebauthpolicy_vpnglobal_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationwebauthpolicyvpnglobalbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationwebauthpolicy_vpnglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_vpnglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationwebauthpolicy_vpnglobal_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_vpnglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationwebauthpolicy_vpnglobal_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_vpnglobal_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationwebauthpolicy_vpnglobal_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_vpnglobal_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationwebauthpolicy_vpnglobal_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_vpnglobal_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationwebauthpolicyvpnglobalbinding: Ended" } } function Invoke-ADCGetAuthenticationwebauthpolicyvpnvserverbinding { <# .SYNOPSIS Get Authentication configuration object(s). .DESCRIPTION Binding object showing the vpnvserver that can be bound to authenticationwebauthpolicy. .PARAMETER Name Name of the WebAuth policy. .PARAMETER GetAll Retrieve all authenticationwebauthpolicy_vpnvserver_binding object(s). .PARAMETER Count If specified, the count of the authenticationwebauthpolicy_vpnvserver_binding object(s) will be returned. .PARAMETER Filter Specify a filter. -Filter @{ 'name'='<value>' } .PARAMETER ViewSummary When specified, only a summary of information is returned. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicyvpnvserverbinding Get data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicyvpnvserverbinding -GetAll Get all authenticationwebauthpolicy_vpnvserver_binding data. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicyvpnvserverbinding -Count Get the number of authenticationwebauthpolicy_vpnvserver_binding objects. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicyvpnvserverbinding -name <string> Get authenticationwebauthpolicy_vpnvserver_binding object by specifying for example the name. .EXAMPLE PS C:\>Invoke-ADCGetAuthenticationwebauthpolicyvpnvserverbinding -Filter @{ 'name'='<value>' } Get authenticationwebauthpolicy_vpnvserver_binding data with a filter. .NOTES File Name : Invoke-ADCGetAuthenticationwebauthpolicyvpnvserverbinding Version : v2210.2317 Author : John Billekens Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/authentication/authenticationwebauthpolicy_vpnvserver_binding/ Requires : PowerShell v5.1 and up ADC 13.x and up. ADC 12 and lower may work, not guaranteed. .LINK https://blog.j81.nl #> [CmdletBinding(DefaultParameterSetName = "GetAll")] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')] [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')] param( [Parameter(DontShow)] [Object]$ADCSession = (Get-ADCSession), [Parameter(ParameterSetName = 'GetByResource')] [ValidateScript({ $_.Length -gt 1 })] [string]$Name, [Parameter(ParameterSetName = 'Count', Mandatory)] [Switch]$Count, [hashtable]$Filter = @{ }, [Parameter(ParameterSetName = 'GetAll')] [Switch]$GetAll ) begin { Write-Verbose "Invoke-ADCGetAuthenticationwebauthpolicyvpnvserverbinding: Beginning" } process { try { if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) { $query = @{ bulkbindings = 'yes' } Write-Verbose "Retrieving all authenticationwebauthpolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) { if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } } Write-Verbose "Retrieving total count for authenticationwebauthpolicy_vpnvserver_binding objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_vpnvserver_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) { Write-Verbose "Retrieving authenticationwebauthpolicy_vpnvserver_binding objects by arguments" $arguments = @{ } $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_vpnvserver_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) { Write-Verbose "Retrieving authenticationwebauthpolicy_vpnvserver_binding configuration for property 'name'" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_vpnvserver_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning } else { Write-Verbose "Retrieving authenticationwebauthpolicy_vpnvserver_binding configuration objects" $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type authenticationwebauthpolicy_vpnvserver_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning } } catch { Write-Verbose "ERROR: $($_.Exception.Message)" $response = $null } Write-Output $response } end { Write-Verbose "Invoke-ADCGetAuthenticationwebauthpolicyvpnvserverbinding: Ended" } } # SIG # Begin signature block # MIITYgYJKoZIhvcNAQcCoIITUzCCE08CAQExDzANBglghkgBZQMEAgEFADB5Bgor # BgEEAYI3AgEEoGswaTA0BgorBgEEAYI3AgEeMCYCAwEAAAQQH8w7YFlLCE63JNLG # KX7zUQIBAAIBAAIBAAIBAAIBADAxMA0GCWCGSAFlAwQCAQUABCCEy8weAZMs5r09 # 3OiycTEITN9f/BsQv916fBEMojJUBqCCEHUwggTzMIID26ADAgECAhAsJ03zZBC0 # i/247uUvWN5TMA0GCSqGSIb3DQEBCwUAMHwxCzAJBgNVBAYTAkdCMRswGQYDVQQI # ExJHcmVhdGVyIE1hbmNoZXN0ZXIxEDAOBgNVBAcTB1NhbGZvcmQxGDAWBgNVBAoT # D1NlY3RpZ28gTGltaXRlZDEkMCIGA1UEAxMbU2VjdGlnbyBSU0EgQ29kZSBTaWdu # aW5nIENBMB4XDTIxMDUwNTAwMDAwMFoXDTI0MDUwNDIzNTk1OVowWzELMAkGA1UE # BhMCTkwxEjAQBgNVBAcMCVZlbGRob3ZlbjEbMBkGA1UECgwSSm9oYW5uZXMgQmls # bGVrZW5zMRswGQYDVQQDDBJKb2hhbm5lcyBCaWxsZWtlbnMwggEiMA0GCSqGSIb3 # DQEBAQUAA4IBDwAwggEKAoIBAQCsfgRG81keOHalHfCUgxOa1Qy4VNOnGxB8SL8e # rjP9SfcF13McP7F1HGka5Be495pTZ+duGbaQMNozwg/5Dg9IRJEeBabeSSJJCbZo # SNpmUu7NNRRfidQxlPC81LxTVHxJ7In0MEfCVm7rWcri28MRCAuafqOfSE+hyb1Z # /tKyCyQ5RUq3kjs/CF+VfMHsJn6ZT63YqewRkwHuc7UogTTZKjhPJ9prGLTer8UX # UgvsGRbvhYZXIEuy+bmx/iJ1yRl1kX4nj6gUYzlhemOnlSDD66YOrkLDhXPMXLym # AN7h0/W5Bo//R5itgvdGBkXkWCKRASnq/9PTcoxW6mwtgU8xAgMBAAGjggGQMIIB # jDAfBgNVHSMEGDAWgBQO4TqoUzox1Yq+wbutZxoDha00DjAdBgNVHQ4EFgQUZWMy # gC0i1u2NZ1msk2Mm5nJm5AswDgYDVR0PAQH/BAQDAgeAMAwGA1UdEwEB/wQCMAAw # EwYDVR0lBAwwCgYIKwYBBQUHAwMwEQYJYIZIAYb4QgEBBAQDAgQQMEoGA1UdIARD # MEEwNQYMKwYBBAGyMQECAQMCMCUwIwYIKwYBBQUHAgEWF2h0dHBzOi8vc2VjdGln # by5jb20vQ1BTMAgGBmeBDAEEATBDBgNVHR8EPDA6MDigNqA0hjJodHRwOi8vY3Js # LnNlY3RpZ28uY29tL1NlY3RpZ29SU0FDb2RlU2lnbmluZ0NBLmNybDBzBggrBgEF # BQcBAQRnMGUwPgYIKwYBBQUHMAKGMmh0dHA6Ly9jcnQuc2VjdGlnby5jb20vU2Vj # dGlnb1JTQUNvZGVTaWduaW5nQ0EuY3J0MCMGCCsGAQUFBzABhhdodHRwOi8vb2Nz # cC5zZWN0aWdvLmNvbTANBgkqhkiG9w0BAQsFAAOCAQEARjv9ieRocb1DXRWm3XtY # jjuSRjlvkoPd9wS6DNfsGlSU42BFd9LCKSyRREZVu8FDq7dN0PhD4bBTT+k6AgrY # KG6f/8yUponOdxskv850SjN2S2FeVuR20pqActMrpd1+GCylG8mj8RGjdrLQ3QuX # qYKS68WJ39WWYdVB/8Ftajir5p6sAfwHErLhbJS6WwmYjGI/9SekossvU8mZjZwo # Gbu+fjZhPc4PhjbEh0ABSsPMfGjQQsg5zLFjg/P+cS6hgYI7qctToo0TexGe32DY # fFWHrHuBErW2qXEJvzSqM5OtLRD06a4lH5ZkhojhMOX9S8xDs/ArDKgX1j1Xm4Tu # DjCCBYEwggRpoAMCAQICEDlyRDr5IrdR19NsEN0xNZUwDQYJKoZIhvcNAQEMBQAw # ezELMAkGA1UEBhMCR0IxGzAZBgNVBAgMEkdyZWF0ZXIgTWFuY2hlc3RlcjEQMA4G # A1UEBwwHU2FsZm9yZDEaMBgGA1UECgwRQ29tb2RvIENBIExpbWl0ZWQxITAfBgNV # BAMMGEFBQSBDZXJ0aWZpY2F0ZSBTZXJ2aWNlczAeFw0xOTAzMTIwMDAwMDBaFw0y # ODEyMzEyMzU5NTlaMIGIMQswCQYDVQQGEwJVUzETMBEGA1UECBMKTmV3IEplcnNl # eTEUMBIGA1UEBxMLSmVyc2V5IENpdHkxHjAcBgNVBAoTFVRoZSBVU0VSVFJVU1Qg # TmV0d29yazEuMCwGA1UEAxMlVVNFUlRydXN0IFJTQSBDZXJ0aWZpY2F0aW9uIEF1 # dGhvcml0eTCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBAIASZRc2DsPb # CLPQrFcNdu3NJ9NMrVCDYeKqIE0JLWQJ3M6Jn8w9qez2z8Hc8dOx1ns3KBErR9o5 # xrw6GbRfpr19naNjQrZ28qk7K5H44m/Q7BYgkAk+4uh0yRi0kdRiZNt/owbxiBhq # kCI8vP4T8IcUe/bkH47U5FHGEWdGCFHLhhRUP7wz/n5snP8WnRi9UY41pqdmyHJn # 2yFmsdSbeAPAUDrozPDcvJ5M/q8FljUfV1q3/875PbcstvZU3cjnEjpNrkyKt1ya # tLcgPcp/IjSufjtoZgFE5wFORlObM2D3lL5TN5BzQ/Myw1Pv26r+dE5px2uMYJPe # xMcM3+EyrsyTO1F4lWeL7j1W/gzQaQ8bD/MlJmszbfduR/pzQ+V+DqVmsSl8MoRj # VYnEDcGTVDAZE6zTfTen6106bDVc20HXEtqpSQvf2ICKCZNijrVmzyWIzYS4sT+k # OQ/ZAp7rEkyVfPNrBaleFoPMuGfi6BOdzFuC00yz7Vv/3uVzrCM7LQC/NVV0CUnY # SVgaf5I25lGSDvMmfRxNF7zJ7EMm0L9BX0CpRET0medXh55QH1dUqD79dGMvsVBl # CeZYQi5DGky08CVHWfoEHpPUJkZKUIGy3r54t/xnFeHJV4QeD2PW6WK61l9VLupc # xigIBCU5uA4rqfJMlxwHPw1S9e3vL4IPAgMBAAGjgfIwge8wHwYDVR0jBBgwFoAU # oBEKIz6W8Qfs4q8p74Klf9AwpLQwHQYDVR0OBBYEFFN5v1qqK0rPVIDh2JvAnfKy # A2bLMA4GA1UdDwEB/wQEAwIBhjAPBgNVHRMBAf8EBTADAQH/MBEGA1UdIAQKMAgw # BgYEVR0gADBDBgNVHR8EPDA6MDigNqA0hjJodHRwOi8vY3JsLmNvbW9kb2NhLmNv # bS9BQUFDZXJ0aWZpY2F0ZVNlcnZpY2VzLmNybDA0BggrBgEFBQcBAQQoMCYwJAYI # KwYBBQUHMAGGGGh0dHA6Ly9vY3NwLmNvbW9kb2NhLmNvbTANBgkqhkiG9w0BAQwF # AAOCAQEAGIdR3HQhPZyK4Ce3M9AuzOzw5steEd4ib5t1jp5y/uTW/qofnJYt7wNK # fq70jW9yPEM7wD/ruN9cqqnGrvL82O6je0P2hjZ8FODN9Pc//t64tIrwkZb+/UNk # fv3M0gGhfX34GRnJQisTv1iLuqSiZgR2iJFODIkUzqJNyTKzuugUGrxx8VvwQQuY # AAoiAxDlDLH5zZI3Ge078eQ6tvlFEyZ1r7uq7z97dzvSxAKRPRkA0xdcOds/exgN # Rc2ThZYvXd9ZFk8/Ub3VRRg/7UqO6AZhdCMWtQ1QcydER38QXYkqa4UxFMToqWpM # gLxqeM+4f452cpkMnf7XkQgWoaNflTCCBfUwggPdoAMCAQICEB2iSDBvmyYY0ILg # ln0z02owDQYJKoZIhvcNAQEMBQAwgYgxCzAJBgNVBAYTAlVTMRMwEQYDVQQIEwpO # ZXcgSmVyc2V5MRQwEgYDVQQHEwtKZXJzZXkgQ2l0eTEeMBwGA1UEChMVVGhlIFVT # RVJUUlVTVCBOZXR3b3JrMS4wLAYDVQQDEyVVU0VSVHJ1c3QgUlNBIENlcnRpZmlj # YXRpb24gQXV0aG9yaXR5MB4XDTE4MTEwMjAwMDAwMFoXDTMwMTIzMTIzNTk1OVow # fDELMAkGA1UEBhMCR0IxGzAZBgNVBAgTEkdyZWF0ZXIgTWFuY2hlc3RlcjEQMA4G # A1UEBxMHU2FsZm9yZDEYMBYGA1UEChMPU2VjdGlnbyBMaW1pdGVkMSQwIgYDVQQD # ExtTZWN0aWdvIFJTQSBDb2RlIFNpZ25pbmcgQ0EwggEiMA0GCSqGSIb3DQEBAQUA # A4IBDwAwggEKAoIBAQCGIo0yhXoYn0nwli9jCB4t3HyfFM/jJrYlZilAhlRGdDFi # xRDtsocnppnLlTDAVvWkdcapDlBipVGREGrgS2Ku/fD4GKyn/+4uMyD6DBmJqGx7 # rQDDYaHcaWVtH24nlteXUYam9CflfGqLlR5bYNV+1xaSnAAvaPeX7Wpyvjg7Y96P # v25MQV0SIAhZ6DnNj9LWzwa0VwW2TqE+V2sfmLzEYtYbC43HZhtKn52BxHJAteJf # 7wtF/6POF6YtVbC3sLxUap28jVZTxvC6eVBJLPcDuf4vZTXyIuosB69G2flGHNyM # fHEo8/6nxhTdVZFuihEN3wYklX0Pp6F8OtqGNWHTAgMBAAGjggFkMIIBYDAfBgNV # HSMEGDAWgBRTeb9aqitKz1SA4dibwJ3ysgNmyzAdBgNVHQ4EFgQUDuE6qFM6MdWK # vsG7rWcaA4WtNA4wDgYDVR0PAQH/BAQDAgGGMBIGA1UdEwEB/wQIMAYBAf8CAQAw # HQYDVR0lBBYwFAYIKwYBBQUHAwMGCCsGAQUFBwMIMBEGA1UdIAQKMAgwBgYEVR0g # ADBQBgNVHR8ESTBHMEWgQ6BBhj9odHRwOi8vY3JsLnVzZXJ0cnVzdC5jb20vVVNF # UlRydXN0UlNBQ2VydGlmaWNhdGlvbkF1dGhvcml0eS5jcmwwdgYIKwYBBQUHAQEE # ajBoMD8GCCsGAQUFBzAChjNodHRwOi8vY3J0LnVzZXJ0cnVzdC5jb20vVVNFUlRy # dXN0UlNBQWRkVHJ1c3RDQS5jcnQwJQYIKwYBBQUHMAGGGWh0dHA6Ly9vY3NwLnVz # ZXJ0cnVzdC5jb20wDQYJKoZIhvcNAQEMBQADggIBAE1jUO1HNEphpNveaiqMm/EA # AB4dYns61zLC9rPgY7P7YQCImhttEAcET7646ol4IusPRuzzRl5ARokS9At3Wpwq # QTr81vTr5/cVlTPDoYMot94v5JT3hTODLUpASL+awk9KsY8k9LOBN9O3ZLCmI2pZ # aFJCX/8E6+F0ZXkI9amT3mtxQJmWunjxucjiwwgWsatjWsgVgG10Xkp1fqW4w2y1 # z99KeYdcx0BNYzX2MNPPtQoOCwR/oEuuu6Ol0IQAkz5TXTSlADVpbL6fICUQDRn7 # UJBhvjmPeo5N9p8OHv4HURJmgyYZSJXOSsnBf/M6BZv5b9+If8AjntIeQ3pFMcGc # TanwWbJZGehqjSkEAnd8S0vNcL46slVaeD68u28DECV3FTSK+TbMQ5Lkuk/xYpMo # JVcp+1EZx6ElQGqEV8aynbG8HArafGd+fS7pKEwYfsR7MUFxmksp7As9V1DSyt39 # ngVR5UR43QHesXWYDVQk/fBO4+L4g71yuss9Ou7wXheSaG3IYfmm8SoKC6W59J7u # mDIFhZ7r+YMp08Ysfb06dy6LN0KgaoLtO0qqlBCk4Q34F8W2WnkzGJLjtXX4oemO # CiUe5B7xn1qHI/+fpFGe+zmAEc3btcSnqIBv5VPU4OOiwtJbGvoyJi1qV3AcPKRY # LqPzW0sH3DJZ84enGm1YMYICQzCCAj8CAQEwgZAwfDELMAkGA1UEBhMCR0IxGzAZ # BgNVBAgTEkdyZWF0ZXIgTWFuY2hlc3RlcjEQMA4GA1UEBxMHU2FsZm9yZDEYMBYG # A1UEChMPU2VjdGlnbyBMaW1pdGVkMSQwIgYDVQQDExtTZWN0aWdvIFJTQSBDb2Rl # IFNpZ25pbmcgQ0ECECwnTfNkELSL/bju5S9Y3lMwDQYJYIZIAWUDBAIBBQCggYQw # GAYKKwYBBAGCNwIBDDEKMAigAoAAoQKAADAZBgkqhkiG9w0BCQMxDAYKKwYBBAGC # NwIBBDAcBgorBgEEAYI3AgELMQ4wDAYKKwYBBAGCNwIBFTAvBgkqhkiG9w0BCQQx # IgQgg99VJCuiVq82FJhzXjmvMLoYIg6aas7x1leR9aZktekwDQYJKoZIhvcNAQEB # BQAEggEADQ0Qt+KBLToXAZ9AG433VHI2AGkuRQrSH2N/tHUTttoVfirroEP0WcG9 # NiMVC/Xh8+/QpOPS5UM+mQ7pAtjua1BdzsZBzzu3uw9PQR/y3sPMNmpe9Fs4L+YY # Y0B01+DAiBhFTMuXdD9EQIUVfO6h5dey4aDtpcgwyK+S12KyPXevW5tTHRI2UHU4 # YGKnH42yJQzHWhQuCj8KP41s3AlRMuSlkCSTM8hAvZC6qzppa+wBula1KsOWxOm/ # rTc8T6db8w2P0i0xdDtTvLnBEyXBJ5HdueHiaVRTv/jpTWvx4V9yjSbOh32y34Hp # 6xl2fEgmCMwYB06ShGsEHYdue9NuWw== # SIG # End signature block |