Merge pull request #40 from opencloud-eu/auth-app-rename

Rebrand auth-app
This commit is contained in:
Ralf Haferkamp
2025-01-16 15:11:48 +01:00
committed by GitHub
3 changed files with 7 additions and 7 deletions

View File

@@ -4,7 +4,7 @@ The auth-app service provides authentication for 3rd party apps.
## The `auth` Service Family
ocis uses serveral authentication services for different use cases. All services that start with `auth-` are part of the authentication service family. Each member authenticates requests with different scopes. As of now, these services exist:
OpenCloud uses serveral authentication services for different use cases. All services that start with `auth-` are part of the authentication service family. Each member authenticates requests with different scopes. As of now, these services exist:
- `auth-app` handles authentication of external 3rd party apps
- `auth-basic` handles basic authentication
- `auth-bearer` handles oidc authentication
@@ -28,16 +28,16 @@ App Tokens are used to authenticate 3rd party access via https like when using c
Replace the `user-name` with an existing user. For the `token-expiration`, you can use any time abbreviation from the following list: `h, m, s`. Examples: `72h` or `1h` or `1m` or `1s.` Default is `72h`.
```bash
ocis auth-app create --user-name={user-name} --expiration={token-expiration}
opencloud auth-app create --user-name={user-name} --expiration={token-expiration}
```
Once generated, these tokens can be used to authenticate requests to ocis. They are passed as part of the request as `Basic Auth` header.
Once generated, these tokens can be used to authenticate requests to OpenCloud. They are passed as part of the request as `Basic Auth` header.
### Via API
The `auth-app` service provides an API to create (POST), list (GET) and delete (DELETE) tokens at the `/auth-app/tokens` endpoint.
When using curl for the respective command, you need to authenticate with a header. To do so, get from the browsers developer console the currently active bearer token. Consider that this token has a short lifetime. In any example, replace `<your host[:port]>` with the URL:port of your Infinite Scale instance, and `{token}` `{value}` accordingly. Note that the active bearer token authenticates the user the token was issued for.
When using curl for the respective command, you need to authenticate with a header. To do so, get from the browsers developer console the currently active bearer token. Consider that this token has a short lifetime. In any example, replace `<your host[:port]>` with the URL:port of your OpenCloud instance, and `{token}` `{value}` accordingly. Note that the active bearer token authenticates the user the token was issued for.
* **Create a token**\
The POST request requires:

View File

@@ -23,11 +23,11 @@ func GetCommands(cfg *config.Config) cli.Commands {
}
}
// Execute is the entry point for the ocis-auth-app command.
// Execute is the entry point for the opencloud auth-app command.
func Execute(cfg *config.Config) error {
app := clihelper.DefaultApp(&cli.App{
Name: "auth-app",
Usage: "Provide app authentication for oCIS",
Usage: "Provide app authentication for OpenCloud",
Commands: GetCommands(cfg),
})

View File

@@ -7,7 +7,7 @@ import (
"github.com/opencloud-eu/opencloud/services/auth-app/pkg/config"
)
// AuthAppConfigFromStruct will adapt an oCIS config struct into a reva mapstructure to start a reva service.
// AuthAppConfigFromStruct will adapt an OpenCloud config struct into a reva mapstructure to start a reva service.
func AuthAppConfigFromStruct(cfg *config.Config) map[string]interface{} {
appAuthJSON := filepath.Join(defaults.BaseDataPath(), "appauth.json")