From 15cf4ec79334b946888151f8f7a2192c7d5673b4 Mon Sep 17 00:00:00 2001 From: Greg Brownstein Date: Sat, 15 Jul 2023 16:54:50 +0000 Subject: [PATCH] Update manifest and docs to 5.7.0 --- CHANGELOG.md | 9 + VenafiPS/VenafiPS.psd1 | 7 +- docs/changelog.md | 9 + docs/functions/Find-VenafiCertificate.md | 23 ++- docs/functions/Get-VaasSatellite.md | 178 ++++++++++++++++++ .../Set-VaasCertificateAssignment.md | 138 ++++++++++++++ mkdocs.yml | 2 + 7 files changed, 362 insertions(+), 4 deletions(-) create mode 100644 docs/functions/Get-VaasSatellite.md create mode 100644 docs/functions/Set-VaasCertificateAssignment.md diff --git a/CHANGELOG.md b/CHANGELOG.md index 9303b789..c0301da9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,11 @@ +## 5.7.0 +- Add `Find-VenafiCertificate -SavedSearchName` to find VaaS certificate details via an existing saved search filter +- Add `Get-VaasSatellite` to retrieve vsatellite details optionally including encryption key and algorithm +- Add `Set-VaasCertificateAssignment` to add or replace applications associated to certificates +- Add User property to `$VenafiSession` when connecting to VaaS. All kinds of helpful info here including company ID. +- Fix credentials not being written to the vault with `New-VenafiSession -VaultVaasKeyName` + + ## 5.6.0 - Add specific error messages when a TPP token scope/privilege is not sufficient for the current function. The message will include both the current and missing scope/privilege, [#175](https://github.com/Venafi/VenafiPS/issues/175). - Add `Set-VaasTeam` to update existing VaaS teams. You can update the name, role, and/or user matching rules. User matching rules can be overwritten or appended to. @@ -542,5 +550,6 @@ + diff --git a/VenafiPS/VenafiPS.psd1 b/VenafiPS/VenafiPS.psd1 index 1680bf09..e529c7a7 100644 --- a/VenafiPS/VenafiPS.psd1 +++ b/VenafiPS/VenafiPS.psd1 @@ -3,7 +3,7 @@ # # Generated by: Venafi # -# Generated on: 07/12/2023 +# Generated on: 07/15/2023 # @{ @@ -12,7 +12,7 @@ RootModule = 'VenafiPS.psm1' # Version number of this module. -ModuleVersion = '5.7' +ModuleVersion = '5.7.0' # Supported PSEditions # CompatiblePSEditions = @() @@ -107,7 +107,8 @@ FunctionsToExport = 'Add-TppCertificateAssociation', 'Convert-TppObject', 'Remove-TppEngineFolder', 'Add-TppEngineFolder', 'Revoke-TppGrant', 'Add-TppAdaptableHash', 'New-VaasCertificate', 'Find-VaasObject', 'Remove-TppObject', 'Set-VaasTeam', 'Remove-VaasObject', - 'Invoke-VaasWorkflow', 'Get-VaasSatellite', 'Set-VaasCertificateAssignment' + 'Invoke-VaasWorkflow', 'Get-VaasSatellite', + 'Set-VaasCertificateAssignment' # Cmdlets to export from this module, for best performance, do not use wildcards and do not delete the entry, use an empty array if there are no cmdlets to export. CmdletsToExport = @() diff --git a/docs/changelog.md b/docs/changelog.md index f2ec96dd..50a3f020 100644 --- a/docs/changelog.md +++ b/docs/changelog.md @@ -1,3 +1,11 @@ +## 5.7.0 +- Add `Find-VenafiCertificate -SavedSearchName` to find VaaS certificate details via an existing saved search filter +- Add `Get-VaasSatellite` to retrieve vsatellite details optionally including encryption key and algorithm +- Add `Set-VaasCertificateAssignment` to add or replace applications associated to certificates +- Add User property to `$VenafiSession` when connecting to VaaS. All kinds of helpful info here including company ID. +- Fix credentials not being written to the vault with `New-VenafiSession -VaultVaasKeyName` + + ## 5.6.0 - Add specific error messages when a TPP token scope/privilege is not sufficient for the current function. The message will include both the current and missing scope/privilege, [#175](https://github.com/Venafi/VenafiPS/issues/175). - Add `Set-VaasTeam` to update existing VaaS teams. You can update the name, role, and/or user matching rules. User matching rules can be overwritten or appended to. @@ -542,5 +550,6 @@ + diff --git a/docs/functions/Find-VenafiCertificate.md b/docs/functions/Find-VenafiCertificate.md index 3d97800e..686d1c30 100644 --- a/docs/functions/Find-VenafiCertificate.md +++ b/docs/functions/Find-VenafiCertificate.md @@ -33,6 +33,12 @@ Find-VenafiCertificate [-Filter ] [-Order ] [-IncludeVaas [-VenafiSession ] [-IncludeTotalCount] [-Skip ] [-First ] [] ``` +### VaasSavedSearch +``` +Find-VenafiCertificate -SavedSearchName [-IncludeVaasOwner] [-VenafiSession ] + [-IncludeTotalCount] [-Skip ] [-First ] [] +``` + ## DESCRIPTION Find certificates based on various attributes. Supports standard PS paging parameters First, Skip, and IncludeTotalCount. @@ -890,13 +896,28 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -SavedSearchName +{{ Fill SavedSearchName Description }} + +```yaml +Type: String +Parameter Sets: VaasSavedSearch +Aliases: + +Required: True +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -IncludeVaasOwner Retrieve detailed user/team owner info, only for VaaS. This will cause additional api calls to be made and take longer. ```yaml Type: SwitchParameter -Parameter Sets: VaaS +Parameter Sets: VaaS, VaasSavedSearch Aliases: Required: False diff --git a/docs/functions/Get-VaasSatellite.md b/docs/functions/Get-VaasSatellite.md new file mode 100644 index 00000000..cda2d608 --- /dev/null +++ b/docs/functions/Get-VaasSatellite.md @@ -0,0 +1,178 @@ +# Get-VaasSatellite + +## SYNOPSIS +Get VSatellite info + +## SYNTAX + +### ID (Default) +``` +Get-VaasSatellite -ID [-IncludeKey] [-VenafiSession ] [] +``` + +### All +``` +Get-VaasSatellite [-All] [-IncludeKey] [-VenafiSession ] [] +``` + +## DESCRIPTION +Get info for either a specific VSatellite or all. +There is an option to also include the encryption key and algorithm. + +## EXAMPLES + +### EXAMPLE 1 +``` +Get-VaasSatellite -ID 'VSatellite Hub 0001' +``` + +companyId : a05013bd-921d-440c-bc22-c9ead5c8d548 +productEntitlements : {ANY} +environmentId : a05013bd-921d-440c-bc22-c9ead5c8d548 +pairingCodeId : a05013bd-921d-440c-bc22-c9ead5c8d548 +name : VSatellite Hub 0001 +edgeType : HUB +edgeStatus : ACTIVE +clientId : a05013bd-921d-440c-bc22-c9ead5c8d548 +modificationDate : 6/15/2023 11:48:40 AM +address : 1.2.3.4 +deploymentDate : 6/15/2023 11:44:14 AM +lastSeenOnDate : 7/13/2023 12:00:40 PM +reconciliationFailed : False +encryptionKeyId : mwU4oTet9KwTGggRfhek0UtvighIw= +encryptionKeyDeploymentDate : 6/15/2023 11:48:40 AM +kubernetesVersion : v1.23.6+k3s1 +integrationServicesCount : 0 +vsatelliteId : a05013bd-921d-440c-bc22-c9ead5c8d548 +encryptionKey : +encryptionKeyAlgorithm : + +Get info for a specific VSatellite by name + +### EXAMPLE 2 +``` +Get-VaasSatellite -ID 'ca7ff555-88d2-4bfc-9efa-2630ac44c1f2' +``` + +Get info for a specific VSatellite + +### EXAMPLE 3 +``` +Get-VaasSatellite -All +``` + +Get info for all VSatellites + +### EXAMPLE 4 +``` +Get-VaasSatellite -All -IncludeKey +``` + +companyId : a05013bd-921d-440c-bc22-c9ead5c8d548 +productEntitlements : {ANY} +environmentId : a05013bd-921d-440c-bc22-c9ead5c8d548 +pairingCodeId : a05013bd-921d-440c-bc22-c9ead5c8d548 +name : VSatellite Hub 0001 +edgeType : HUB +edgeStatus : ACTIVE +clientId : a05013bd-921d-440c-bc22-c9ead5c8d548 +modificationDate : 6/15/2023 11:48:40 AM +address : 1.2.3.4 +deploymentDate : 6/15/2023 11:44:14 AM +lastSeenOnDate : 7/13/2023 12:00:40 PM +reconciliationFailed : False +encryptionKeyId : mwU4oTet9KwTGggRfhek0UtvighIw= +encryptionKeyDeploymentDate : 6/15/2023 11:48:40 AM +kubernetesVersion : v1.23.6+k3s1 +integrationServicesCount : 0 +vsatelliteId : a05013bd-921d-440c-bc22-c9ead5c8d548 +encryptionKey : o4aFaJUTtCydprvgRupQ1ZiY= +encryptionKeyAlgorithm : ED25519 + +Get info for VSatellites including the encryption key and algorithm + +## PARAMETERS + +### -ID +Name or uuid to get info for a specific VSatellite + +```yaml +Type: String +Parameter Sets: ID +Aliases: applicationId + +Required: True +Position: Named +Default value: None +Accept pipeline input: True (ByPropertyName, ByValue) +Accept wildcard characters: False +``` + +### -All +Get all VSatellites + +```yaml +Type: SwitchParameter +Parameter Sets: All +Aliases: + +Required: True +Position: Named +Default value: False +Accept pipeline input: False +Accept wildcard characters: False +``` + +### -IncludeKey +Include the encryption key and algorithm + +```yaml +Type: SwitchParameter +Parameter Sets: (All) +Aliases: + +Required: False +Position: Named +Default value: False +Accept pipeline input: False +Accept wildcard characters: False +``` + +### -VenafiSession +Authentication for the function. +The value defaults to the script session object $VenafiSession created by New-VenafiSession. +A VaaS key can also provided. + +```yaml +Type: PSObject +Parameter Sets: (All) +Aliases: + +Required: False +Position: Named +Default value: $script:VenafiSession +Accept pipeline input: False +Accept wildcard characters: False +``` + +### CommonParameters +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). + +## INPUTS + +### ID +## OUTPUTS + +### PSCustomObject +## NOTES + +## RELATED LINKS + +[http://VenafiPS.readthedocs.io/en/latest/functions/Get-VaasSatellite/](http://VenafiPS.readthedocs.io/en/latest/functions/Get-VaasSatellite/) + +[https://github.com/Venafi/VenafiPS/blob/main/VenafiPS/Public/Get-VaasSatellite.ps1](https://github.com/Venafi/VenafiPS/blob/main/VenafiPS/Public/Get-VaasSatellite.ps1) + +[https://developer.venafi.com/tlsprotectcloud/reference/edgeinstances_getall](https://developer.venafi.com/tlsprotectcloud/reference/edgeinstances_getall) + +[https://developer.venafi.com/tlsprotectcloud/reference/edgeencryptionkeys_getall](https://developer.venafi.com/tlsprotectcloud/reference/edgeencryptionkeys_getall) + diff --git a/docs/functions/Set-VaasCertificateAssignment.md b/docs/functions/Set-VaasCertificateAssignment.md new file mode 100644 index 00000000..bb61a11f --- /dev/null +++ b/docs/functions/Set-VaasCertificateAssignment.md @@ -0,0 +1,138 @@ +# Set-VaasCertificateAssignment + +## SYNOPSIS +Associate certificates with applications + +## SYNTAX + +``` +Set-VaasCertificateAssignment [-CertificateID] [-ApplicationID] [-NoOverwrite] [-PassThru] + [[-VenafiSession] ] [] +``` + +## DESCRIPTION +Associate one or more certificates with one or more applications. +The associated applications can either replace or be added to existing. +By default, applications will be replaced. + +## EXAMPLES + +### EXAMPLE 1 +``` +Set-VaasCertificateAssignment -CertificateID '7ac56ec0-2017-11ee-9417-a17dd25b82f9' -ApplicationID '96fc9310-67ec-11eb-a8a7-794fe75a8e6f' +``` + +Associate a certificate to an application + +### EXAMPLE 2 +``` +Set-VaasCertificateAssignment -CertificateID '7ac56ec0-2017-11ee-9417-a17dd25b82f9' -ApplicationID '96fc9310-67ec-11eb-a8a7-794fe75a8e6f', 'a05013bd-921d-440c-bc22-c9ead5c8d548' +``` + +Associate a certificate to multiple applications + +### EXAMPLE 3 +``` +Find-VenafiCertificate -First 5 | Set-VaasCertificateAssignment -ApplicationID '96fc9310-67ec-11eb-a8a7-794fe75a8e6f' +``` + +Associate multiple certificates to 1 application + +### EXAMPLE 4 +``` +Set-VaasCertificateAssignment -CertificateID '7ac56ec0-2017-11ee-9417-a17dd25b82f9' -ApplicationID '96fc9310-67ec-11eb-a8a7-794fe75a8e6f' -NoOverwrite +``` + +Associate a certificate to another application, keeping the existing + +## PARAMETERS + +### -CertificateID +Certificate ID to be associated + +```yaml +Type: String +Parameter Sets: (All) +Aliases: + +Required: True +Position: 1 +Default value: None +Accept pipeline input: True (ByPropertyName) +Accept wildcard characters: False +``` + +### -ApplicationID +One or more application IDs + +```yaml +Type: String[] +Parameter Sets: (All) +Aliases: + +Required: True +Position: 2 +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + +### -NoOverwrite +Append to existing applications as opposed to overwriting + +```yaml +Type: SwitchParameter +Parameter Sets: (All) +Aliases: + +Required: False +Position: Named +Default value: False +Accept pipeline input: False +Accept wildcard characters: False +``` + +### -PassThru +Return the newly updated certificate object(s) + +```yaml +Type: SwitchParameter +Parameter Sets: (All) +Aliases: + +Required: False +Position: Named +Default value: False +Accept pipeline input: False +Accept wildcard characters: False +``` + +### -VenafiSession +Authentication for the function. +The value defaults to the script session object $VenafiSession created by New-VenafiSession. +A VaaS key can also provided. + +```yaml +Type: PSObject +Parameter Sets: (All) +Aliases: Key + +Required: False +Position: 3 +Default value: $script:VenafiSession +Accept pipeline input: False +Accept wildcard characters: False +``` + +### CommonParameters +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). + +## INPUTS + +### CertificateID +## OUTPUTS + +### PSCustomObject +## NOTES + +## RELATED LINKS diff --git a/mkdocs.yml b/mkdocs.yml index 8b3cab50..73327ed0 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -63,6 +63,7 @@ nav: - Get-VaasApplication: functions/Get-VaasApplication.md - Get-VaasConnector: functions/Get-VaasConnector.md - Get-VaasIssuingTemplate: functions/Get-VaasIssuingTemplate.md + - Get-VaasSatellite: functions/Get-VaasSatellite.md - Get-VenafiCertificate: functions/Get-VenafiCertificate.md - Get-VenafiIdentity: functions/Get-VenafiIdentity.md - Get-VenafiTeam: functions/Get-VenafiTeam.md @@ -111,6 +112,7 @@ nav: - Set-TppCredential: functions/Set-TppCredential.md - Set-TppPermission: functions/Set-TppPermission.md - Set-TppWorkflowTicketStatus: functions/Set-TppWorkflowTicketStatus.md + - Set-VaasCertificateAssignment: functions/Set-VaasCertificateAssignment.md - Set-VaasTeam: functions/Set-VaasTeam.md - Test-ModuleHash: functions/Test-ModuleHash.md - Test-TppIdentity: functions/Test-TppIdentity.md