scimgateway 5.1.2 → 5.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +71 -39
- package/bun.lock +616 -0
- package/config/plugin-entra-id.json +4 -7
- package/lib/helper-rest.ts +259 -142
- package/lib/logger.ts +1 -1
- package/lib/postinstall.ts +1 -2
- package/lib/scim-stream.js +1 -1
- package/lib/scimgateway.ts +8 -4
- package/lib/utils.ts +23 -0
- package/package.json +1 -1
- package/bun.lockb +0 -0
package/README.md
CHANGED
|
@@ -7,7 +7,7 @@ Author: Jarle Elshaug
|
|
|
7
7
|
|
|
8
8
|
Validated through IdP's:
|
|
9
9
|
|
|
10
|
-
- Symantec/Broadcom
|
|
10
|
+
- Symantec/Broadcom Identity Manager
|
|
11
11
|
- Microsoft Entra ID
|
|
12
12
|
- One Identity Manager/OneLogin
|
|
13
13
|
- Okta
|
|
@@ -78,7 +78,7 @@ Demonstrates SAP HANA specific user provisioning
|
|
|
78
78
|
Entra ID user provisioning including license management (App Service plans) e.g. Office 365
|
|
79
79
|
Using Microsoft Graph API through HelperRest
|
|
80
80
|
Using customized SCIM attributes according to Microsoft Graph API
|
|
81
|
-
Includes Symantec/Broadcom
|
|
81
|
+
Includes Symantec/Broadcom ConnectorXpress metafile for creating provisioning "Azure - ScimGateway" endpoint type
|
|
82
82
|
|
|
83
83
|
* **LDAP** (Directory)
|
|
84
84
|
Fully functional LDAP plugin
|
|
@@ -122,8 +122,6 @@ If internet connection is blocked, we could install on another machine and copy
|
|
|
122
122
|
#### Startup and verify default Loki plugin
|
|
123
123
|
|
|
124
124
|
bun c:\my-scimgateway
|
|
125
|
-
|
|
126
|
-
If using Node.js instead of Bun, scimgateway must be downloaded from github and startup: node --experimental-strip-types c:\my-scimgateway\index.ts
|
|
127
125
|
|
|
128
126
|
Start a browser (note, Edge do not pop-up logon dialog box when using http)
|
|
129
127
|
|
|
@@ -152,6 +150,8 @@ If internet connection is blocked, we could install on another machine and copy
|
|
|
152
150
|
|
|
153
151
|
>Tip, take a look at bun test scripts located in `node_modules\scimgateway\test\lib`
|
|
154
152
|
|
|
153
|
+
> If using Node.js instead of Bun, scimgateway must be downloaded from github and startup:
|
|
154
|
+
node --experimental-strip-types c:\my-scimgateway\index.ts
|
|
155
155
|
|
|
156
156
|
#### Upgrade SCIM Gateway
|
|
157
157
|
|
|
@@ -413,13 +413,11 @@ Definitions in `endpoint` object are customized according to our plugin code. Pl
|
|
|
413
413
|
"ca": null
|
|
414
414
|
}
|
|
415
415
|
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
openssl req -nodes -newkey rsa:2048 -x509 -sha256 -days 3650 -keyout key.pem -out cert.pem -subj "/O=Testing/OU=SCIM Gateway/CN=<FQDN>" -config "<path>\openssl.cnf"
|
|
416
|
+
Example of how to make a self signed certificate:
|
|
419
417
|
|
|
420
|
-
|
|
418
|
+
openssl.exe req -nodes -newkey rsa:2048 -x509 -sha256 -days 3650 -keyout key.pem -out cert.pem -subj "/O=My Company/OU=Application/CN=SCIM Gateway" -addext "subjectAltName=DNS:localhost,DNS:127.0.0.1,DNS:*.mycompany.com" -addext "extendedKeyUsage=serverAuth" -addext "keyUsage=digitalSignature"
|
|
421
419
|
|
|
422
|
-
Note, when using Symantec/Broadcom
|
|
420
|
+
Note, when using Symantec/Broadcom Provisioning, the "certificate authority - CA" also must be imported on the Connector Server. For self-signed certificate, CA and the certificate (public key) is the same.
|
|
423
421
|
|
|
424
422
|
PFX / PKCS#12 bundle can be used instead of key/cert/ca e.g:
|
|
425
423
|
|
|
@@ -428,7 +426,7 @@ Definitions in `endpoint` object are customized according to our plugin code. Pl
|
|
|
428
426
|
"password": "password"
|
|
429
427
|
}
|
|
430
428
|
|
|
431
|
-
Note, we should normally use certificate (https) for communicating with SCIM Gateway unless we install
|
|
429
|
+
Note, we should normally use certificate (https) for communicating with SCIM Gateway unless we install gateway locally on the manager (e.g. on the provisioning Connector Server). When installed on the manager, we could use `http://localhost:port` or `http://127.0.0.1:port` which will not be passed down to the data link layer for transmission. We could then also set {"localhostonly": true}
|
|
432
430
|
|
|
433
431
|
- **ipAllowList** - Array of one or more IPv4/IPv6 subnets (CIDR) allowed for incoming traffic. E.g. using Entra ID as IdP, we would like to restrict access to IP addresses used by Azure. Azure IP-range can be downloaded from: [https://azureipranges.azurewebsites.net](https://azureipranges.azurewebsites.net), enter **AzureActiveDirectory** in the search list and select JSON download. Copy the "addressPrefixes" array content and paste into ipAllowList array. CIDR single IP-host syntax is a.b.c.d/32. Note, front-end HTTP proxy or a load balancer must include client IP-address in the **X-Forwarded-For** header. Configuration example:
|
|
434
432
|
|
|
@@ -606,8 +604,6 @@ Definitions in `endpoint` object are customized according to our plugin code. Pl
|
|
|
606
604
|
|
|
607
605
|
Using `scimgateway.authPassThroughAllowed = true` and `plugin-<name>.json` configuration `scimgateway.auth.passThrough=true` enables Authentication PassTrhough
|
|
608
606
|
|
|
609
|
-
|
|
610
|
-
|
|
611
607
|
## Manual startup
|
|
612
608
|
|
|
613
609
|
Gateway can be started from a command window running in administrative mode
|
|
@@ -795,16 +791,11 @@ Some notes related to Entra ID:
|
|
|
795
791
|
- Deleting a user in Entra ID sends a modify user `{"active":"False"}` which means user should be disabled. This logic is default set in attribute mappings expression rule `Switch([IsSoftDeleted], , "False", "True", "True", "False")`. Standard SCIM "DELETE" method seems not to be used.
|
|
796
792
|
|
|
797
793
|
|
|
798
|
-
##
|
|
799
|
-
|
|
800
|
-
Using Symantec/Broadcom/CA Identity Manger, plugin configuration might have to use **SCIM Version "1.1"** (scimgateway.scim.version).
|
|
801
|
-
|
|
802
|
-
In the Provisioning Manager we have to use
|
|
803
|
-
|
|
794
|
+
## Symantec Identity Manager as IdP using SCIM Gateway
|
|
804
795
|
|
|
805
|
-
|
|
796
|
+
Using Symantec/Broadcom Identity Manger, plugin configuration must use **SCIM Version "1.1"** (scimgateway.scim.version).
|
|
806
797
|
|
|
807
|
-
or create our own custom endpoint type based on this one
|
|
798
|
+
In the Provisioning Manager we could use `Endpoint type = SCIM (DYN Endpoint)` or create our own custom endpoint type based on this one
|
|
808
799
|
|
|
809
800
|
SCIM endpoint configuration example for Loki plugin (plugin-loki)
|
|
810
801
|
|
|
@@ -829,13 +820,10 @@ http://localhost:8880/client-b
|
|
|
829
820
|
|
|
830
821
|
Each baseEntity should then be defined in the plugin configuration file with custom attributes needed. Please see examples in plugin-soap.json
|
|
831
822
|
|
|
832
|
-
IM 12.6 SP7 (and above) also supports pagination for SCIM endpoint (data transferred in bulks - endpoint explore of users). Loki plugin supports pagination. Other plugin may ignore this setting.
|
|
833
|
-
|
|
834
|
-
|
|
835
823
|
## Entra ID provisioning
|
|
836
824
|
Using plugin-entra-id we could do user provisioning towards Entra ID
|
|
837
825
|
|
|
838
|
-
For testing purposes we could get an Azure free account
|
|
826
|
+
For testing purposes we could get an Azure free account
|
|
839
827
|
|
|
840
828
|
### Entra ID configuration
|
|
841
829
|
|
|
@@ -861,25 +849,30 @@ For testing purposes we could get an Azure free account
|
|
|
861
849
|
- Application permissions
|
|
862
850
|
- Directory - Directory.ReadWriteAll
|
|
863
851
|
- Organization - Organization.ReadWrite.All
|
|
864
|
-
- Click "Add permissions"
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
852
|
+
- Click "Add permissions"
|
|
853
|
+
- API permissions: - Grant Admin consent
|
|
854
|
+
Or we could go to Enterprise application to grant these consents:
|
|
855
|
+
- Microsoft Entra ID - Enterprise applications - SCIM Gateway Inbound
|
|
856
|
+
- Permissions:
|
|
857
|
+
- Click "Grant admin consent for [tenant name]"
|
|
858
|
+
- In the logon dialog, logon as global administrator
|
|
859
|
+
- In permissions request dialog, click "Accept"
|
|
860
|
+
- Click "Refresh", directory and organization permissions are now listed and OK
|
|
872
861
|
|
|
873
862
|
|
|
874
|
-
**
|
|
863
|
+
**Seems Application needs to be member of "User administrator" for having privileges to manage office/mobile phone on users that is member of any administrator roles**
|
|
875
864
|
|
|
876
865
|
Also note, enable/disable user (accountEnabled - through Graph API) will fail if user have an "Administrator" role other than above mentioned "User Administrator" e.g. "Group Administrator"/"Application Administrator". To be sure we can enable/disable all users, application needs to be member of **"Global administrator"** - 62e90394-69f5-4237-9190-012177145e10.
|
|
877
866
|
|
|
878
|
-
- Microsoft Entra ID - Roles and
|
|
879
|
-
-
|
|
867
|
+
- Microsoft Entra ID - Manage - Roles and administrators
|
|
868
|
+
- Search: User administrator
|
|
869
|
+
- Click on role **User administrator**
|
|
880
870
|
- Click "Add assignments"
|
|
881
|
-
-
|
|
882
|
-
-
|
|
871
|
+
- Click "No member selected" to add members
|
|
872
|
+
- Search: SCIM Gateway Inbound (name of the application we have created)
|
|
873
|
+
- Select the application name that shows up and click "Add"
|
|
874
|
+
- Click Next
|
|
875
|
+
- Assignment type=Active and enable "Permanent assigned", add some justification text and click "Assign"
|
|
883
876
|
|
|
884
877
|
### SCIM Gateway configuration
|
|
885
878
|
|
|
@@ -890,7 +883,7 @@ Set plugin to be started to `entra-id`
|
|
|
890
883
|
|
|
891
884
|
**Edit plugin-entra-id.json**
|
|
892
885
|
|
|
893
|
-
Note, for Symantec/Broadcom
|
|
886
|
+
Note, for Symantec/Broadcom Provisioning we must use SCIM version 1.1
|
|
894
887
|
|
|
895
888
|
scimgateway: {
|
|
896
889
|
"scim": {
|
|
@@ -964,7 +957,7 @@ For additional details, see baseEntity description.
|
|
|
964
957
|
|
|
965
958
|
Note, we should normally use certificate (https) for communicating with SCIM Gateway unless we install gateway locally on the manager (e.g. on the CA Connector Server). When installed on the manager, we could use `http://localhost:port` or `http://127.0.0.1:port` which will not be passed down to the data link layer for transmission. We could then also set {"localhostonly": true}
|
|
966
959
|
|
|
967
|
-
### Using Symantec/Broadcom
|
|
960
|
+
### Using Symantec/Broadcom Provisioning
|
|
968
961
|
Create a new endpoint type "Azure - ScimGateway"
|
|
969
962
|
|
|
970
963
|
- Start SCIM Gateway
|
|
@@ -1182,6 +1175,45 @@ MIT © [Jarle Elshaug](https://www.elshaug.xyz)
|
|
|
1182
1175
|
|
|
1183
1176
|
## Change log
|
|
1184
1177
|
|
|
1178
|
+
### v5.1.4
|
|
1179
|
+
|
|
1180
|
+
[Fixed]
|
|
1181
|
+
|
|
1182
|
+
- Postinstall failed using the new Bun v1.2.0
|
|
1183
|
+
|
|
1184
|
+
### v5.1.3
|
|
1185
|
+
|
|
1186
|
+
[Fixed]
|
|
1187
|
+
|
|
1188
|
+
- HelperRest, auth.type=`oauthJwtBearer` and auth.options=`tenantIdGUID`
|
|
1189
|
+
|
|
1190
|
+
Configuration example using Entra ID application having uploaded cert.pem as certificate secret:
|
|
1191
|
+
|
|
1192
|
+
"endpoint": {
|
|
1193
|
+
"entity": {
|
|
1194
|
+
"undefined": {
|
|
1195
|
+
"connection": {
|
|
1196
|
+
"baseUrls": [],
|
|
1197
|
+
"auth": {
|
|
1198
|
+
"type": "oauthJwtBearer",
|
|
1199
|
+
"options": {
|
|
1200
|
+
"tenantIdGUID": "Entra ID Tenant ID (GUID)",
|
|
1201
|
+
"clientId": "<application clientId>",
|
|
1202
|
+
"certificate": { // files located in ./config/certs
|
|
1203
|
+
"key": "key.pem",
|
|
1204
|
+
"cert": "cert.pem"
|
|
1205
|
+
}
|
|
1206
|
+
}
|
|
1207
|
+
}
|
|
1208
|
+
}
|
|
1209
|
+
}
|
|
1210
|
+
}
|
|
1211
|
+
}
|
|
1212
|
+
|
|
1213
|
+
Please see code editor method HelperRest doRequest() IntelliSense for details
|
|
1214
|
+
|
|
1215
|
+
Note, this fix may break `plugin-entra-id` if baseUrls configuration not empty. If baseUrl not empty, it will be used. If empty, baseUrl will automatically be set according to graph api when using tenantIdGUID definition
|
|
1216
|
+
|
|
1185
1217
|
### v5.1.2
|
|
1186
1218
|
|
|
1187
1219
|
[Improved]
|