- Administering Oracle Identity Cloud Service
- Manage Oracle Identity Cloud Service Components
- Manage Linux Authentication using the Linux-PAM Module
- Configure Groups and Users for the Linux-PAM
- Create a User with POSIX Attributes and Add to Group
Create a User with POSIX Attributes and Add to Group
Create a user with POSIX attributes and add the user to the group previously created.
- Create a
user.json
file with the following request body:user.json
{ "password": "Securepasswd@1", "userName": "userPosix", "Name.givenName": "user", "Name.familyName": "Posix", "userType": "Employee", "emails": [ { "value": "user.posix@example.com", "type": "work", "primary": true }, { "value": "posix@example.com", "type": "home" } ], "addresses": [ { "type": "work", "primary": true, "streetAddress": "401 Island Parkway", "locality": "Redwood Shores", "region": "California", "postalCode": "94065", "country": "US", "formatted": "userPosix" } ], "urn:ietf:params:scim:schemas:oracle:idcs:extension:posix:User": { "homeDirectory": "/home/userPosix", "loginShell": "/bin/bash", "gecos": "userPosix 24855", "uidNumber": 12001, "gidNumber": 11010 }, "meta": { "resourceType": "User" }, "schemas": [ "urn:ietf:params:scim:schemas:core:2.0:User", "urn:ietf:params:scim:schemas:oracle:idcs:extension:posix:User" ] }
where:
userName
is set to the username of the user you wish to createhomeDirectory
is set to the location of the user's home directoryloginShell
is set to the default shellgecos
is set to general information about the user, for example the user's username and phone numberuidNumber
must be set to a unique user id (uid) number in Linux. Use thegetent passwd
command on Linux to see existing users and their uid'sgidNumber
must be set to the group id (gid) number created previously
- Run the following curl command to create the user and add it to the group:
user.json
curl -k -X POST -H "Content-Type: application/json" -H "Authorization: Bearer <token-string>" "https://identity-cloud-service-instance-url/admin/v1/Users" -d '@user.json'
where:
token-string
is the OAuth access token that you obtainedidentity-cloud-service-instance-url
is your Oracle Identity Cloud Service Instance URL
Note:
It is not possible to create a user with POSIX attributes using the Oracle Identity Cloud Service Administration Console.Once the user is created, the user will be sent a notification email to activate their account and set a new password. The user must activate their account before testing authentication in Linux.