Skip to content

Latest commit

 

History

History
420 lines (198 loc) · 4.76 KB

File metadata and controls

420 lines (198 loc) · 4.76 KB

login

smctl login

Authenticates user against a SAP Service Manager instance.

smctl login [flags]

login, l

Required

Global Flag

-a, --url

Base URL for SAP Service Manager.

No

--param

Use it to add more parameters. Parameters are specified as key=value pairs.

Note:

The subdomain parameter is mandatory for login.

No

Optional

Global Flag

-h, --help

Help for the login command.

No

-p, --password

User password

No

--skip-ssl-validation

Skip verification of the OAuth endpoint. Not recommended.

No

-u, --user

User ID

No

--config

Set the path for the smctl config.json file (default is $HOME/.sm/config.json).

Yes

-v, --verbose

Use the verbose mode.

Yes

–-auth-flow

Specify the authorization flow.

You have the following two options:

  • password

  • client-credentials

If not specified, password flow is used.

No

--client-id

--client-secret

You specify these parameters if you chose the client-credentials authorization flow and if you created the binding object with the default credentials type.

See the example of a binding object created with the default credentials type: Create a SAP Service Manager Instance and Binding.

No

--cert

–-key

You specify these parameters if you chose the client-credentials authorization flow and if you created the binding object with the X.509 credentials type.

Their values are paths to files that contain public and private keys respectively that were generated upon the creation of the binding object with X.509 credentials type.

See the example of a binding object created with X.509 credentials type: Create a SAP Service Manager Instance and Binding.

No

> smctl login -a https://service-management-url.com

User: user                # entering username
Password:                 # entering password (password visibility is disabled)
Logged in successfully.
> smctl login -a https://service-management-url.com -u user -p pass

Logged in successfully.

Client Credentials with the Default Type

> smctl login -a https://service-manager-url.com --auth-flow=client-credentials --client-id=id --client-secret=secret

          Logged in successfully.

Client Credentials with the X.509 Type

smctl login -a https://service-manager-url.com --auth-flow=client-credentials --client-id=id --cert=cert.pem --key=key.pem

        Logged in successfully.

Note:

SAP Service Manager Control (SMCTL) command-line also supports the explicit logout command and session timeout period of 30 minutes to better secure users' data and avoid malicious access.

Related Information

Logging in to SAP Service Manager