-
Notifications
You must be signed in to change notification settings - Fork 76
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add ssl #794
Merged
Merged
add ssl #794
Changes from all commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
# SSL encryption | ||
|
||
Nebula Graph supports data transmission with SSL encryption between clients, the Graph service, the Meta service, and the Storage service. This topic describes how to enable SSL encryption. | ||
|
||
## Precaution | ||
|
||
Enabling SSL encryption will slightly affect the performance, such as causing operation latency. | ||
|
||
## Parameters | ||
|
||
| Parameter | Default value | Description | | ||
| ------------------ | ------- | ------------------------------| | ||
| `cert_path` | - | The path to the PEM certification. | | ||
| `key_path` | - | The path to the key certification. | | ||
| `password_path` | - | The path to the password file certification. | | ||
| `ca_path` | - | The path to the trusted CA file. | | ||
| `enable_ssl` | `false` | Whether to enable SSL encryption. | | ||
| `enable_graph_ssl` | `false` | Whether to enable SSL encryption in the Graph service only. | | ||
| `enable_meta_ssl` | `false` | Whether to enable SSL encryption in the Meta service only. | | ||
|
||
## Certificate modes | ||
|
||
To use SSL encryption, SSL certificates are required. Nebula Graph supports two certificate modes. | ||
|
||
- Self-signed certificate mode | ||
|
||
In this mode, users need to make the signed certificate by themselves and set `cert_path`, `key_path`, and `password_path` in the corresponding file according to encryption policies. | ||
|
||
- CA-signed certificate mode | ||
|
||
In this mode, users need to apply for the signed certificate from a certificate authority and set `cert_path`, `key_path`, and `password_path` in the corresponding file according to encryption policies. | ||
|
||
## Encryption policies | ||
|
||
Nebula Graph supports three encryption policies. For details, see [Usage explanation](https://github.com/vesoft-inc/nebula/blob/a67d166b284cae1b534bf8d19c936ee38bf12e29/docs/rfcs/0001-ssl-transportation.md#usage-explanation). | ||
|
||
- Encrypt the data transmission between clients, the Graph service, the Meta service, and the Storage service. | ||
|
||
Add `enable_ssl = true` to the configuration files of `nebula-graphd.conf`, `nebula-metad.conf`, and `nebula-storaged.conf`. | ||
|
||
- Encrypt the data transmission between clients and the Graph service. | ||
|
||
This policy applies to the case that the clusters are set in the same server room. Only the port of the Graph service is open to the outside because other services can communicate over the internal network without encryption. Add `enable_graph_ssl = true` to the configuration file of `nebula-graphd.conf`. | ||
|
||
- Encrypt the data transmission related to the Meta service in the cluster. | ||
|
||
This policy applies to transporting classified information to the Meta service. Add `enable_meta_ssl = true` to the configuration files of `nebula-graphd.conf`, `nebula-metad.conf`, and `nebula-storaged.conf`. | ||
|
||
## Steps | ||
|
||
1. Ensure the certificate mode and the encryption policy. | ||
|
||
2. Add the certificate configuration and the policy configuration in corresponding files. | ||
|
||
For example, the three configuration files need to be set as follows when using a self-signed certificate and encrypt data transmission between clients, the Graph service, the Meta service, and the Storage service. | ||
|
||
```bash | ||
--cert_path=xxxxxx | ||
--key_path=xxxxx | ||
--password_path=xxxxxx | ||
--enable_ssl=true | ||
``` | ||
|
||
3. Set the SSL and the trusted CA in clients. For code examples, see [nebula-test-run.py](https://github.com/vesoft-inc/nebula/blob/{{nebula.branch}}/tests/nebula-test-run.py). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
just a question
when do we use users instead of you? I saw many “you” with the same meaning of users existing in previous docs.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it's about document style. no final conclusion yet.