scimgateway 3.2.8 → 4.0.0
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 +269 -294
- package/config/plugin-api.json +9 -4
- package/config/plugin-azure-ad.json +9 -4
- package/config/plugin-forwardinc.json +19 -11
- package/config/plugin-ldap.json +9 -4
- package/config/plugin-loki.json +9 -4
- package/config/plugin-mongodb.json +101 -0
- package/config/plugin-mssql.json +9 -4
- package/config/plugin-restful.json +9 -4
- package/config/plugin-saphana.json +9 -4
- package/index.js +1 -0
- package/lib/plugin-api.js +1 -1
- package/lib/plugin-azure-ad.js +608 -572
- package/lib/plugin-forwardinc.js +304 -373
- package/lib/plugin-ldap.js +267 -382
- package/lib/plugin-loki.js +232 -177
- package/lib/plugin-mongodb.js +776 -0
- package/lib/plugin-mssql.js +105 -196
- package/lib/plugin-restful.js +171 -314
- package/lib/plugin-saphana.js +96 -131
- package/lib/postinstall.js +10 -8
- package/lib/scimdef-v1.js +18 -6
- package/lib/scimdef-v2.js +19 -5
- package/lib/scimgateway.js +554 -436
- package/lib/utils.js +36 -1
- package/package.json +11 -10
- package/test/index.js +1 -3
- package/test/lib/plugin-loki.js +79 -41
- package/test/lib/plugin-mongodb.js +631 -0
- package/test/lib/plugin-restful.js +66 -33
package/config/plugin-api.json
CHANGED
|
@@ -19,18 +19,22 @@
|
|
|
19
19
|
{
|
|
20
20
|
"username": "gwadmin",
|
|
21
21
|
"password": "password",
|
|
22
|
-
"readOnly": false
|
|
22
|
+
"readOnly": false,
|
|
23
|
+
"baseEntities": []
|
|
23
24
|
}
|
|
24
25
|
],
|
|
25
26
|
"bearerToken": [
|
|
26
27
|
{
|
|
27
28
|
"token": null,
|
|
28
|
-
"readOnly": false
|
|
29
|
+
"readOnly": false,
|
|
30
|
+
"baseEntities": []
|
|
29
31
|
}
|
|
30
32
|
],
|
|
31
33
|
"bearerJwtAzure": [
|
|
32
34
|
{
|
|
33
|
-
"tenantIdGUID": null
|
|
35
|
+
"tenantIdGUID": null,
|
|
36
|
+
"readOnly": false,
|
|
37
|
+
"baseEntities": []
|
|
34
38
|
}
|
|
35
39
|
],
|
|
36
40
|
"bearerJwt": [
|
|
@@ -40,7 +44,8 @@
|
|
|
40
44
|
"options": {
|
|
41
45
|
"issuer": null
|
|
42
46
|
},
|
|
43
|
-
"readOnly": false
|
|
47
|
+
"readOnly": false,
|
|
48
|
+
"baseEntities": []
|
|
44
49
|
}
|
|
45
50
|
]
|
|
46
51
|
},
|
|
@@ -19,18 +19,22 @@
|
|
|
19
19
|
{
|
|
20
20
|
"username": "gwadmin",
|
|
21
21
|
"password": "password",
|
|
22
|
-
"readOnly": false
|
|
22
|
+
"readOnly": false,
|
|
23
|
+
"baseEntities": []
|
|
23
24
|
}
|
|
24
25
|
],
|
|
25
26
|
"bearerToken": [
|
|
26
27
|
{
|
|
27
28
|
"token": null,
|
|
28
|
-
"readOnly": false
|
|
29
|
+
"readOnly": false,
|
|
30
|
+
"baseEntities": []
|
|
29
31
|
}
|
|
30
32
|
],
|
|
31
33
|
"bearerJwtAzure": [
|
|
32
34
|
{
|
|
33
|
-
"tenantIdGUID": null
|
|
35
|
+
"tenantIdGUID": null,
|
|
36
|
+
"readOnly": false,
|
|
37
|
+
"baseEntities": []
|
|
34
38
|
}
|
|
35
39
|
],
|
|
36
40
|
"bearerJwt": [
|
|
@@ -40,7 +44,8 @@
|
|
|
40
44
|
"options": {
|
|
41
45
|
"issuer": null
|
|
42
46
|
},
|
|
43
|
-
"readOnly": false
|
|
47
|
+
"readOnly": false,
|
|
48
|
+
"baseEntities": []
|
|
44
49
|
}
|
|
45
50
|
]
|
|
46
51
|
},
|
|
@@ -19,18 +19,22 @@
|
|
|
19
19
|
{
|
|
20
20
|
"username": "gwadmin",
|
|
21
21
|
"password": "password",
|
|
22
|
-
"readOnly": false
|
|
22
|
+
"readOnly": false,
|
|
23
|
+
"baseEntities": []
|
|
23
24
|
}
|
|
24
25
|
],
|
|
25
26
|
"bearerToken": [
|
|
26
27
|
{
|
|
27
28
|
"token": null,
|
|
28
|
-
"readOnly": false
|
|
29
|
+
"readOnly": false,
|
|
30
|
+
"baseEntities": []
|
|
29
31
|
}
|
|
30
32
|
],
|
|
31
33
|
"bearerJwtAzure": [
|
|
32
34
|
{
|
|
33
|
-
"tenantIdGUID": null
|
|
35
|
+
"tenantIdGUID": null,
|
|
36
|
+
"readOnly": false,
|
|
37
|
+
"baseEntities": []
|
|
34
38
|
}
|
|
35
39
|
],
|
|
36
40
|
"bearerJwt": [
|
|
@@ -40,7 +44,8 @@
|
|
|
40
44
|
"options": {
|
|
41
45
|
"issuer": null
|
|
42
46
|
},
|
|
43
|
-
"readOnly": false
|
|
47
|
+
"readOnly": false,
|
|
48
|
+
"baseEntities": []
|
|
44
49
|
}
|
|
45
50
|
]
|
|
46
51
|
},
|
|
@@ -72,9 +77,7 @@
|
|
|
72
77
|
"endpoint": {
|
|
73
78
|
"username": "admin",
|
|
74
79
|
"password": "password",
|
|
75
|
-
"
|
|
76
|
-
"http://localhost:8089/forwardinc/services"
|
|
77
|
-
],
|
|
80
|
+
"baseServiceEndpoint": "http://localhost:8089/forwardinc/services",
|
|
78
81
|
"exploreUsers": {
|
|
79
82
|
"service": "UserService",
|
|
80
83
|
"method": "searchUsers"
|
|
@@ -116,14 +119,19 @@
|
|
|
116
119
|
"method": "N/A"
|
|
117
120
|
},
|
|
118
121
|
"entity": {
|
|
119
|
-
"
|
|
120
|
-
"userId": "
|
|
122
|
+
"undefined": {
|
|
123
|
+
"userId": "user1",
|
|
121
124
|
"key": "clientA.key",
|
|
122
125
|
"cert": "clientA.cert"
|
|
123
126
|
},
|
|
124
|
-
"
|
|
125
|
-
"userId": "
|
|
127
|
+
"clientA": {
|
|
128
|
+
"userId": "user2",
|
|
126
129
|
"key": "clientB.key",
|
|
130
|
+
"cert": "clientB.cert"
|
|
131
|
+
},
|
|
132
|
+
"clientB": {
|
|
133
|
+
"userId": "user3",
|
|
134
|
+
"key": "clientC.key",
|
|
127
135
|
"cert": "clientC.cert"
|
|
128
136
|
}
|
|
129
137
|
}
|
package/config/plugin-ldap.json
CHANGED
|
@@ -19,18 +19,22 @@
|
|
|
19
19
|
{
|
|
20
20
|
"username": "gwadmin",
|
|
21
21
|
"password": "password",
|
|
22
|
-
"readOnly": false
|
|
22
|
+
"readOnly": false,
|
|
23
|
+
"baseEntities": []
|
|
23
24
|
}
|
|
24
25
|
],
|
|
25
26
|
"bearerToken": [
|
|
26
27
|
{
|
|
27
28
|
"token": null,
|
|
28
|
-
"readOnly": false
|
|
29
|
+
"readOnly": false,
|
|
30
|
+
"baseEntities": []
|
|
29
31
|
}
|
|
30
32
|
],
|
|
31
33
|
"bearerJwtAzure": [
|
|
32
34
|
{
|
|
33
|
-
"tenantIdGUID": null
|
|
35
|
+
"tenantIdGUID": null,
|
|
36
|
+
"readOnly": false,
|
|
37
|
+
"baseEntities": []
|
|
34
38
|
}
|
|
35
39
|
],
|
|
36
40
|
"bearerJwt": [
|
|
@@ -40,7 +44,8 @@
|
|
|
40
44
|
"options": {
|
|
41
45
|
"issuer": null
|
|
42
46
|
},
|
|
43
|
-
"readOnly": false
|
|
47
|
+
"readOnly": false,
|
|
48
|
+
"baseEntities": []
|
|
44
49
|
}
|
|
45
50
|
]
|
|
46
51
|
},
|
package/config/plugin-loki.json
CHANGED
|
@@ -19,18 +19,22 @@
|
|
|
19
19
|
{
|
|
20
20
|
"username": "gwadmin",
|
|
21
21
|
"password": "password",
|
|
22
|
-
"readOnly": false
|
|
22
|
+
"readOnly": false,
|
|
23
|
+
"baseEntities": []
|
|
23
24
|
}
|
|
24
25
|
],
|
|
25
26
|
"bearerToken": [
|
|
26
27
|
{
|
|
27
28
|
"token": null,
|
|
28
|
-
"readOnly": false
|
|
29
|
+
"readOnly": false,
|
|
30
|
+
"baseEntities": []
|
|
29
31
|
}
|
|
30
32
|
],
|
|
31
33
|
"bearerJwtAzure": [
|
|
32
34
|
{
|
|
33
|
-
"tenantIdGUID": null
|
|
35
|
+
"tenantIdGUID": null,
|
|
36
|
+
"readOnly": false,
|
|
37
|
+
"baseEntities": []
|
|
34
38
|
}
|
|
35
39
|
],
|
|
36
40
|
"bearerJwt": [
|
|
@@ -40,7 +44,8 @@
|
|
|
40
44
|
"options": {
|
|
41
45
|
"issuer": null
|
|
42
46
|
},
|
|
43
|
-
"readOnly": false
|
|
47
|
+
"readOnly": false,
|
|
48
|
+
"baseEntities": []
|
|
44
49
|
}
|
|
45
50
|
]
|
|
46
51
|
},
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
{
|
|
2
|
+
"scimgateway": {
|
|
3
|
+
"port": 8885,
|
|
4
|
+
"localhostonly": false,
|
|
5
|
+
"scim": {
|
|
6
|
+
"version": "2.0",
|
|
7
|
+
"customSchema": null,
|
|
8
|
+
"skipTypeConvert": false
|
|
9
|
+
},
|
|
10
|
+
"log": {
|
|
11
|
+
"loglevel": {
|
|
12
|
+
"file": "debug",
|
|
13
|
+
"console": "error"
|
|
14
|
+
},
|
|
15
|
+
"customMasking": null
|
|
16
|
+
},
|
|
17
|
+
"auth": {
|
|
18
|
+
"basic": [
|
|
19
|
+
{
|
|
20
|
+
"username": "gwadmin",
|
|
21
|
+
"password": "password",
|
|
22
|
+
"readOnly": false,
|
|
23
|
+
"baseEntities": []
|
|
24
|
+
},
|
|
25
|
+
{
|
|
26
|
+
"username": "client-a",
|
|
27
|
+
"password": "password",
|
|
28
|
+
"readOnly": false,
|
|
29
|
+
"baseEntities": ["client-a"]
|
|
30
|
+
}
|
|
31
|
+
],
|
|
32
|
+
"bearerToken": [
|
|
33
|
+
{
|
|
34
|
+
"token": null,
|
|
35
|
+
"readOnly": false,
|
|
36
|
+
"baseEntities": []
|
|
37
|
+
}
|
|
38
|
+
],
|
|
39
|
+
"bearerJwtAzure": [
|
|
40
|
+
{
|
|
41
|
+
"tenantIdGUID": null,
|
|
42
|
+
"readOnly": false,
|
|
43
|
+
"baseEntities": []
|
|
44
|
+
}
|
|
45
|
+
],
|
|
46
|
+
"bearerJwt": [
|
|
47
|
+
{
|
|
48
|
+
"secret": null,
|
|
49
|
+
"publicKey": null,
|
|
50
|
+
"options": {
|
|
51
|
+
"issuer": null
|
|
52
|
+
},
|
|
53
|
+
"readOnly": false,
|
|
54
|
+
"baseEntities": []
|
|
55
|
+
}
|
|
56
|
+
]
|
|
57
|
+
},
|
|
58
|
+
"certificate": {
|
|
59
|
+
"key": null,
|
|
60
|
+
"cert": null,
|
|
61
|
+
"ca": null,
|
|
62
|
+
"pfx": {
|
|
63
|
+
"bundle": null,
|
|
64
|
+
"password": null
|
|
65
|
+
}
|
|
66
|
+
},
|
|
67
|
+
"ipAllowList": [],
|
|
68
|
+
"emailOnError": {
|
|
69
|
+
"smtp": {
|
|
70
|
+
"enabled": false,
|
|
71
|
+
"host": null,
|
|
72
|
+
"port": 587,
|
|
73
|
+
"proxy": null,
|
|
74
|
+
"authenticate": true,
|
|
75
|
+
"username": null,
|
|
76
|
+
"password": null,
|
|
77
|
+
"sendInterval": 15,
|
|
78
|
+
"to": null,
|
|
79
|
+
"cc": null
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
},
|
|
83
|
+
"endpoint": {
|
|
84
|
+
"entity": {
|
|
85
|
+
"undefined": {
|
|
86
|
+
"persistence": false,
|
|
87
|
+
"baseUrl": "mongodb://localhost:27017/db",
|
|
88
|
+
"database": "db",
|
|
89
|
+
"username": "admin",
|
|
90
|
+
"password": "password"
|
|
91
|
+
},
|
|
92
|
+
"client-a": {
|
|
93
|
+
"persistence": false,
|
|
94
|
+
"baseUrl": "mongodb://localhost:28017/client-a-db",
|
|
95
|
+
"database": "client-a-db",
|
|
96
|
+
"username": "admin",
|
|
97
|
+
"password": "password"
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
}
|
package/config/plugin-mssql.json
CHANGED
|
@@ -19,18 +19,22 @@
|
|
|
19
19
|
{
|
|
20
20
|
"username": "gwadmin",
|
|
21
21
|
"password": "password",
|
|
22
|
-
"readOnly": false
|
|
22
|
+
"readOnly": false,
|
|
23
|
+
"baseEntities": []
|
|
23
24
|
}
|
|
24
25
|
],
|
|
25
26
|
"bearerToken": [
|
|
26
27
|
{
|
|
27
28
|
"token": null,
|
|
28
|
-
"readOnly": false
|
|
29
|
+
"readOnly": false,
|
|
30
|
+
"baseEntities": []
|
|
29
31
|
}
|
|
30
32
|
],
|
|
31
33
|
"bearerJwtAzure": [
|
|
32
34
|
{
|
|
33
|
-
"tenantIdGUID": null
|
|
35
|
+
"tenantIdGUID": null,
|
|
36
|
+
"readOnly": false,
|
|
37
|
+
"baseEntities": []
|
|
34
38
|
}
|
|
35
39
|
],
|
|
36
40
|
"bearerJwt": [
|
|
@@ -40,7 +44,8 @@
|
|
|
40
44
|
"options": {
|
|
41
45
|
"issuer": null
|
|
42
46
|
},
|
|
43
|
-
"readOnly": false
|
|
47
|
+
"readOnly": false,
|
|
48
|
+
"baseEntities": []
|
|
44
49
|
}
|
|
45
50
|
]
|
|
46
51
|
},
|
|
@@ -19,18 +19,22 @@
|
|
|
19
19
|
{
|
|
20
20
|
"username": "gwadmin",
|
|
21
21
|
"password": "password",
|
|
22
|
-
"readOnly": false
|
|
22
|
+
"readOnly": false,
|
|
23
|
+
"baseEntities": []
|
|
23
24
|
}
|
|
24
25
|
],
|
|
25
26
|
"bearerToken": [
|
|
26
27
|
{
|
|
27
28
|
"token": null,
|
|
28
|
-
"readOnly": false
|
|
29
|
+
"readOnly": false,
|
|
30
|
+
"baseEntities": []
|
|
29
31
|
}
|
|
30
32
|
],
|
|
31
33
|
"bearerJwtAzure": [
|
|
32
34
|
{
|
|
33
|
-
"tenantIdGUID": null
|
|
35
|
+
"tenantIdGUID": null,
|
|
36
|
+
"readOnly": false,
|
|
37
|
+
"baseEntities": []
|
|
34
38
|
}
|
|
35
39
|
],
|
|
36
40
|
"bearerJwt": [
|
|
@@ -40,7 +44,8 @@
|
|
|
40
44
|
"options": {
|
|
41
45
|
"issuer": null
|
|
42
46
|
},
|
|
43
|
-
"readOnly": false
|
|
47
|
+
"readOnly": false,
|
|
48
|
+
"baseEntities": []
|
|
44
49
|
}
|
|
45
50
|
]
|
|
46
51
|
},
|
|
@@ -19,18 +19,22 @@
|
|
|
19
19
|
{
|
|
20
20
|
"username": "gwadmin",
|
|
21
21
|
"password": "password",
|
|
22
|
-
"readOnly": false
|
|
22
|
+
"readOnly": false,
|
|
23
|
+
"baseEntities": []
|
|
23
24
|
}
|
|
24
25
|
],
|
|
25
26
|
"bearerToken": [
|
|
26
27
|
{
|
|
27
28
|
"token": null,
|
|
28
|
-
"readOnly": false
|
|
29
|
+
"readOnly": false,
|
|
30
|
+
"baseEntities": []
|
|
29
31
|
}
|
|
30
32
|
],
|
|
31
33
|
"bearerJwtAzure": [
|
|
32
34
|
{
|
|
33
|
-
"tenantIdGUID": null
|
|
35
|
+
"tenantIdGUID": null,
|
|
36
|
+
"readOnly": false,
|
|
37
|
+
"baseEntities": []
|
|
34
38
|
}
|
|
35
39
|
],
|
|
36
40
|
"bearerJwt": [
|
|
@@ -40,7 +44,8 @@
|
|
|
40
44
|
"options": {
|
|
41
45
|
"issuer": null
|
|
42
46
|
},
|
|
43
|
-
"readOnly": false
|
|
47
|
+
"readOnly": false,
|
|
48
|
+
"baseEntities": []
|
|
44
49
|
}
|
|
45
50
|
]
|
|
46
51
|
},
|
package/index.js
CHANGED
|
@@ -10,6 +10,7 @@
|
|
|
10
10
|
//
|
|
11
11
|
|
|
12
12
|
const loki = require('./lib/plugin-loki')
|
|
13
|
+
// const mongodb = require('./lib/plugin-mongodb')
|
|
13
14
|
// const restful = require('./lib/plugin-restful')
|
|
14
15
|
// const forwardinc = require('./lib/plugin-forwardinc')
|
|
15
16
|
// const mssql = require('./lib/plugin-mssql')
|
package/lib/plugin-api.js
CHANGED
|
@@ -174,7 +174,7 @@ scimgateway.getApi = async (baseEntity, id, apiQuery, apiObj) => {
|
|
|
174
174
|
} else {
|
|
175
175
|
const path = '/api/Books'
|
|
176
176
|
const body = null
|
|
177
|
-
if (apiQuery) {
|
|
177
|
+
if (apiQuery) { /* some logic here */ }
|
|
178
178
|
const response = await doRequest(baseEntity, method, path, body)
|
|
179
179
|
return response.body
|
|
180
180
|
}
|