Hi Tobias,

 

I’ll continue in English due to English speaking list members. 😊

What version of ADFSToolkit do you have?

 

The value of your rule needs to be a PSCustomObject. Something like this:

 

$TransformRules."CompanyID" = [PSCustomObject]@{

    Rule=@"

    @RuleName = "Send CompanyID"

=> issue(Type = "company_id", Value = "55080");

"@

    }

 

If you want it in OID format you must also include the OID for CompanyID and a propery:

 

$TransformRules."CompanyID" = [PSCustomObject]@{

    Rule=@"

    @RuleName = "Send CompanyID"

    => issue(Type = "urn:oid:
", Value = "55080",

    Properties[http://schemas.xmlsoap.org/ws/2005/05/identity/claimproperties/attributename] = "urn:oasis:names:tc:SAML:2.0:attrname-format:uri");

"@

    }

 

Don’t forget to restart PowerShell after you have edited LocalManualSettings (or run Remove-ADFSTkCache -FullMemoryCache)!

It’s cached to speed up the main process


 

Best regards

Johan Peterson

IT-Architect

 

 

Digitalisation Division

DIGIT

s-581 83 Linköping

Phone: +46 (0)13-28 57 30

Mobile: +46 (0)703 222 405

Visiting address: D-Building

Please visit us at liu.se

E-mailing Linköping University will result in Linköping University processing your personal data. Find more information on how this is done at https://liu.se/en/article/integritetspolicy-liu

 

From: Tobias Galéus <tobias.galeus@gu.se>
Sent: den 4 oktober 2023 15:22
To: adfstoolkit-users@lists.sunet.se
Subject: [Adfstoolkit-users] get-ADFSTkLocalManualSpSettings.ps1 (för Egencia i SWAMID)

 

Hej!

 

Jag försöker göra en anpassad attributrelease till Egencia som finns med i SWAMID. I c:\adfstoolkit\config\institution\get-ADFSTkLocalManualSpSettings.ps1 har jag lagt till

 

$TransformRules = [Ordered]@{}

 

$TransformRules."CompanyID" = @"

=> issue(Type = "company_id", Value = "55080");

"@

$IssuanceTransformRuleManualSP[https://www.egencia.com/auth/v1] = $TransformRules

 

(Lite förkortat)

 

Men det verkar inte bita nÀr jag uppdaterar SPn i AD FS. I filen get-ADFSTkLocalManualSpSettings.ps1 hÀnvisar man till en sökvÀg som inte finns i nÄgon av vÄra installationer:

    # This file exists as a template in the Module with a runtime instance in:

    #     c:\ADFSToolkit\<version>\config\get-ADFSTkLocalManualSPSettings.ps1 

Vi saknar version i sökvÀgen, men tar man bort det sÄ stÀmmer den ju.

 

Det stÄr ocksÄ att man ska kunna fÄ mer hjÀlp med följande kommando
# To see examples invoke Powershell get-help:

    #   get-help get-ADFSTkLocalManualSPSettings -Examples

 

    To see example code blocks invoke detailed help by: get-help get-ADFSTkManualSPSettings -Detailed

 

Men det fungerar inte pÄ vÄra installationer:

get-help get-ADFSTkLocalManualSPSettings -Examples

get-help : Get-Help could not find get-ADFSTkLocalManualSPSettings in a help file in this session. To download updated help topics type: "Update-Help". To get help onlin

e, search for the help topic in the TechNet library at https:/go.microsoft.com/fwlink/?LinkID=107116.

 

Vad gör jag för fel?

 

Mvh Tobias Galéus

IT-Enheten

Göteborgs universitet