You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: modules/ROOT/pages/database-administration/aliases/remote-database-alias-configuration.adoc
+25-20Lines changed: 25 additions & 20 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -48,7 +48,7 @@ image::remote-alias-overview.svg[title="Overview of the required remote database
48
48
A remote database alias is only accessible to users with appropriate privileges.
49
49
In this example, _Bob_ is the administrator responsible for deciding which database (`db1` or `db2`) the remote aliases can write and/or read.
50
50
Meanwhile, _Alice_ is the administrator that assigns who has access to the privileges set by _Bob_.
51
-
In the example, _Alice_ will assign that access to _Carol_.
51
+
In the example, _Alice_ assigns that access to _Carol_.
52
52
53
53
See xref:authentication-authorization/dbms-administration/index.adoc[DBMS privileges] for more information.
54
54
@@ -75,15 +75,15 @@ CREATE USER alias_user SET PASSWORD 'secretpassword'
75
75
+
76
76
[source, Cypher]
77
77
----
78
-
CREATE ROLE remote
78
+
CREATE ROLE remote_access
79
79
----
80
80
. Grant the necessary privileges on `db1` to the custom role and assign the role to the user profile created for the remote database alias:
81
81
+
82
82
[source, Cypher]
83
83
----
84
-
GRANT ACCESS ON DATABASE db1 TO remote
85
-
GRANT MATCH {*} ON GRAPH db1 TO remote
86
-
GRANT ROLE remote TO alias_user
84
+
GRANT ACCESS ON DATABASE db1 TO remote_access
85
+
GRANT MATCH {*} ON GRAPH db1 TO remote_access
86
+
GRANT ROLE remote_access TO alias_user
87
87
----
88
88
. Set up the link:https://neo4j.com/docs/operations-manual/current/security/ssl-framework/[SSL framework] and check whether the database accepts non-local connections if required.
89
89
+
@@ -109,7 +109,7 @@ It is recommended to create a custom role to track all users shared on a remote
109
109
=== Configure the local DBMS A and grant access to Carol (_Alice_)
110
110
111
111
As _Alice_, you are responsible for setting up *DBMS А*.
112
-
You can create and delete the database aliases and grant or deny users' access to them.
112
+
You can create and delete database aliases and grant or deny users' access to them.
113
113
114
114
In this example, you create a remote database alias, called `db1-remote-alias`, which connects to `db1` on *DBMS B* using the credentials shared by _Bob_.
==== Create the remote database alias and grant access to Carol
182
182
183
-
Finally, you create the remote database alias using xref:database-administration/aliases/manage-aliases-standard-databases.adoc[alias administrative commands].
183
+
You create the remote database alias using xref:database-administration/aliases/manage-aliases-standard-databases.adoc[alias administrative commands] and grant _Carol_ access to it.
184
184
185
185
[NOTE]
186
186
====
@@ -190,18 +190,18 @@ By default, remote aliases require a secured URI scheme such as `neo4j+s`.
190
190
However, if you want to disable the secure URL scheme, you can set the driver setting `ssl_enforced` to `false`.
191
191
====
192
192
193
-
For example, you can use the following command to create a remote database alias with stored native credentials shared by _Bob_:
194
-
193
+
. Use the following command to create a remote database alias with the stored native credentials shared by _Bob_:
194
+
+
195
195
[source, Cypher]
196
196
----
197
197
CREATE ALIAS `db1-remote-alias` FOR DATABASE `db1` AT "neo4j+s://location:7687" USER alias_user PASSWORD 'secretpassword'
198
198
----
199
199
200
-
Then, you can grant the xref:authentication-authorization/database-administration.adoc#access-control-database-administration-access[`ACCESS` privileges] to use the remote database alias to _Carol_:
201
-
200
+
. Grant access to the remote database alias to the `remote_access` role and assign it to _Carol_.
201
+
See xref:authentication-authorization/database-administration.adoc#access-control-database-administration-access[`ACCESS` privileges] for more information.
202
+
+
202
203
[source, Cypher]
203
204
----
204
-
CREATE ROLE remote_access
205
205
GRANT ACCESS ON DATABASE `db1-remote-alias` TO remote_access
206
206
GRANT ROLE remote_access TO Carol
207
207
----
@@ -236,7 +236,7 @@ image::remote-alias-credential-forwarding-overview.svg[title="Overview of the re
236
236
_Carol_ logs into the local *DBMS A* through an OIDC-compliant identity provider by offering a token from the provider.
237
237
The token is used to set the username and determine the identity provider groups to which the user belongs.
238
238
239
-
_Alice_ is the administrator of the local *DBMS A* and has set up SSO for the identity provider and configured the mapping of the identity provider groups to the Neo4j roles, such that _Carol_ can use the remote database alias, `db1-remote-alias`, to connect to the remote database `db1`.
239
+
_Alice_ is the administrator of the local *DBMS A* and sets up SSO for the identity provider and configures the mapping of the identity provider groups to the Neo4j roles, such that _Carol_ can use the remote database alias, `db1-remote-alias`, to connect to the remote database `db1`.
240
240
241
241
_Bob_ configures the remote *DBMS B* to support SSO with the same identity provider used by _Carol_ to log in to *DBMS A*.
242
242
He also configures the mapping of the identity provider groups to the Neo4j roles such that the _Carol's_ identity provider groups grant the appropriate privileges to access `db1` on the *DBMS B*.
@@ -258,9 +258,9 @@ You can create and delete users and grant or deny privileges on the databases ma
258
258
259
259
In this example, you need to ensure that _Carol_ can access `db1` on *DBMS B* using OIDC credential forwarding.
260
260
261
-
. Set up SSO and support for the identity provider and map the identity provider groups to the Neo4j roles.
261
+
. Set up SSO for the identity provider _Carol_ uses and map the identity provider groups to the Neo4j roles as done on the local *DBMS A*.
262
262
For details, see the xref:tutorial/tutorial-sso-configuration.adoc[SSO configuration tutorial] and xref:authentication-authorization/sso-integration.adoc#auth-sso-map-idp-roles[Map the identity provider groups to the Neo4j roles].
263
-
If you do not want specific users to access `db2`, here is where you set it.
263
+
//If you do not want specific users to access `db2`, here is where you set it.
=== Configure the local DBMS A and grant access to Carol (_Alice_)
295
295
296
296
As _Alice_, you are responsible for setting up the local *DBMS A*.
297
-
You can create and delete the database aliases and grant or deny users' access to them.
297
+
You can create and delete database aliases and grant or deny users' access to them.
298
298
299
299
In this case, you need to set up a remote database alias that connects to `db1` on *DBMS B* using OIDC credential forwarding and grant _Carol_ access to it.
300
300
@@ -320,29 +320,34 @@ See the xref:tutorial/tutorial-sso-configuration.adoc[SSO configuration tutorial
320
320
321
321
==== Create the remote database alias and grant access to Carol
322
322
323
-
Finally, you create the remote database alias using xref:database-administration/aliases/manage-aliases-standard-databases.adoc[alias administrative commands].
323
+
You create the remote database alias using xref:database-administration/aliases/manage-aliases-standard-databases.adoc[alias administrative commands].
324
324
325
-
. Create the remote database alias using OIDC credential forwarding:
326
-
+
327
325
[NOTE]
328
326
====
329
327
It is strongly recommended to connect to a remote database alias with a secured connection.
330
328
Note that only client-side SSL is supported.
331
329
By default, remote aliases require a secured URI scheme such as `neo4j+s`.
332
330
However, if you want to disable the secure URL scheme, you can set the driver setting `ssl_enforced` to `false`.
333
331
====
332
+
333
+
. Use the following command to create a remote database alias using OIDC credential forwarding:
334
334
+
335
335
[source, Cypher]
336
336
----
337
337
CREATE ALIAS `db1-remote-alias` FOR DATABASE `db1` AT "neo4j+s://location:7687" OIDC CREDENTIAL FORWARDING
338
338
----
339
339
340
-
. Create a role to grant access to the remote database alias and assign it to _Carol_.
340
+
. Create a custom role to track all users shared on a remote connection, so that they remain trackable:
341
341
See the xref:authentication-authorization/database-administration.adoc#access-control-database-administration-access[`ACCESS` privileges] for more information.
342
342
+
343
343
[source, Cypher]
344
344
----
345
345
CREATE ROLE remote_access
346
+
----
347
+
. Grant access to the remote database alias to the `remote_access` role and assign it to _Carol_.
348
+
+
349
+
[source, Cypher]
350
+
----
346
351
GRANT ACCESS ON DATABASE `db1-remote-alias` TO remote_access
0 commit comments