To receive notifications about scheduled maintenance, please subscribe to the mailing-list gitlab-operations@sympa.ethz.ch. You can subscribe to the mailing-list at https://sympa.ethz.ch

...
 
Commits (2)
......@@ -7,7 +7,7 @@
RootModule = 'IAMClient.psm1'
# Version number of this module.
ModuleVersion = '1.2.0'
ModuleVersion = '1.2.2'
# ID used to uniquely identify this module
GUID = '33ce3afe-9156-4f0e-bbc7-6d4fab3f2ad7'
......
......@@ -3,4 +3,4 @@ param (
[string]$NuGetApiKey
)
Publish-Module -Name .\IAMClient.psd1 -NuGetApiKey $NuGetApiKey
\ No newline at end of file
Publish-Module -Name "$PSScriptRoot\..\dist\IAMClient.psd1" -NuGetApiKey $NuGetApiKey
\ No newline at end of file
......@@ -6,14 +6,12 @@ function Get-ETHMaillistMember {
[string]$Identity
)
BEGIN {
$membersCn = (Get-ETHMaillist -Identity $Identity).members
}
BEGIN {}
PROCESS {
$membersCn = (Get-ETHMaillist -Identity $Identity).members
foreach ($member in $membersCn) {
$Name = ($member -split ",OU=")[0] -replace "CN="
......
function Test-ETHCredentials {
[CmdletBinding()]
param (
[Parameter(Position = 0, Mandatory = 1)]
[pscredential]$Credentials
)
try {
$script:IAMCreds = $Credentials
Get-ETHUser -Identity $Credentials.UserName
$script:IAMCreds = $null
$script:IAMCreds = $Credentials
try {
Get-ETHUser -Identity $Credentials.UserName -ErrorAction Stop
return $true
}
catch {
return $false
}
}
\ No newline at end of file
finally {
$script:IAMCreds = $null
}
}