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: docs/pages/advanced-usage/server.mdx
+46-11Lines changed: 46 additions & 11 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,22 +1,28 @@
1
-
# Advanced Usage - Servers
1
+
# Managing Administrator Credentials
2
2
3
-
This page documents advanced usage of Pelican servers. Features listed below are for server admins familiar with Pelican Servers.
3
+
Pelican services maintain multiple types of credentials:
4
+
- The *admin password* provides access to the server's web interface.
5
+
- The *namespace private key* can create arbitrary new credentials (user tokens) for a portion of the federation's namespace.
4
6
5
-
## Pre-generate Server Credentials
7
+
This page covers various topics in managing these credentials.
6
8
7
-
### Server Private Key
9
+
##Pre-generate Credentials
8
10
9
-
> **Note**: The server private key should be treated as a **secret** and never shared with the public.
11
+
### Namespace Private Key
10
12
11
-
Pelican servers rely on an ECDSA key-pair for signing and verifying tokens used in API requests and object accesses. Pelican servers automatically generate a private key in ECDSA form at the server start, and provide the public key through the OIDC-style discovery endpoint at `/.well-known/openid-configuration`. The public key is useful for various things including Origin namespace prefix registration at the registry (see details [here](../federating-your-data.mdx#obtain-the-public-key-of-the-origin)).
13
+
> **Note**: The namespace private key is a **powerful secret** and should never be shared with others. With the private key, one can create user credentials the can arbitrary read or write into your namespace.
12
14
13
-
In deployment, it can be convenient to generate the key-pair in advance and mount the private key file to the Pelican server via configuration variable, especially in a container environment. The Pelican CLI comes with a command `pelican generate keygen` for generating private/public key pairs:
15
+
Pelican services rely on a private/public key pair for creating (signing) and verifying the user credentials (tokens) used to read or write objects. When a new prefix in the data federation is created, an associated public key must be provided; the corresponding private key can generate any arbitrary permissions (including delete!) within the namespace. For more information about namespace registration, see details [here](../federating-your-data.mdx#obtain-the-public-key-of-the-origin).
16
+
17
+
When a Pelican origin or other service is started, the server automatically generates a new private key if one is not present. However, if someone is running the origin on your behalf, you will need to generate the keypair on your own and send the public portion to the operator. If you're doing the deployment, it can also be convenient to generate the key-pair in advance and mount the private key file to the Pelican server via configuration variable, especially in a container environment.
18
+
19
+
The Pelican binary ships with a `pelican generate keygen` for generating a private/public key pairs:
14
20
15
21
```bash copy
16
22
pelican generate keygen
17
23
```
18
24
19
-
and Pelican will generate both the private key and the public key under the current working directory:
25
+
Pelican will generate both the private key and the public key under the current working directory:
20
26
21
27
```console
22
28
Successfully generated keys at:
@@ -31,17 +37,46 @@ You can change the location of the generated keys by passing in arguments `priv
The generated *private key* can be passed to a Pelican server via `IssuerKey`configuration parameter so that the server will take advantage of the generated key instead of generating a new key.
40
+
For operators, the generated *private key* can be specified in the a Pelican server configuration via the `IssuerKey` parameter so that the server will use the newly-generated key:
35
41
36
42
37
43
```yaml filename="pelican.yaml" copy
38
44
IssuerKey: /path/to/generated/issuer.jwk
39
45
```
40
46
47
+
If there is a remote operator for your origin, email them the **public key** portion. Never send anyone your private key. A sample public key looks like the following:
By default, Pelican's administrator web interface requires a username/password to be setup to access. This password can be enabled by a one-time passcode the server writes into the log file. However, by pre-generating the credential, Pelican server administrators can skip the initial setup and automate installation.
43
78
44
-
The `pelican generate` command generates the [htpasswd](https://httpd.apache.org/docs/2.4/programs/htpasswd.html) password file for storing the admin website login password. By pre-generating the htpasswd file, Pelican server admin can skip the initial website setup with the one-time passcode. To generate a password file, run:
79
+
The `pelican generate` command generates the [htpasswd](https://httpd.apache.org/docs/2.4/programs/htpasswd.html)-formatted password file for storing the web interface administrator login password. To generate a password file, run:
0 commit comments