cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
480
Views
0
Helpful
3
Replies

auth group to access NSO and API

nisheeth
Level 1
Level 1

Hi

I can create auth group in NSO.

To which service I should associate the authgroup that will enable me to access NSO API, Devices and configure them

Nisheeth

 

3 Replies 3

snovello
Cisco Employee
Cisco Employee

https://developer.cisco.com/docs/nso/guides/the-nso-device-manager/#authentication-groups

Describes authgroups, they store the credentials to access devices. They have no connection to services nor the NSO API.

If you are looking for authorization inside NSO, there is info in the admin guide, also look under AAA and NACM.

For my automation I have created two REST API endpoint 

Workflow Start  EP  http://localhost:8080/workflow/workflow-start

Workflow Status  EP  http://localhost:8080/workflow/workflow-status

ConfigUpdate Start  EP  http://localhost:8080/conf-upd/conf-upd-start

ConfigUpdate Status  EP  http://localhost:8080/conf-upd/conf-upd-status

In the workflow I include config updates and send Request to Workflow-start REST API

I need to assign the auth group to my conf-upd-start and conf-up-status so that I dont need to send not send credentials in plain text.

how can i do this with the NSO 

Nisheeth

 

 

 

 

Hi, I think you are mixing some concepts. From your reply, I have the impression you are looking how to interact with network devices sending API requests to NSO.

If so, authentication groups are used by NSO to access the devices. Authentication groups are not used by the RESTCONF API to authenticate REST API requests.

To authenticate REST API requests to NSO, you need to enable RESTCONF on NSO and then use basic HTTP authentication to authenticate your requests against NSO. If you API requests are successful, you can interact now with the network devices through NSO. NSO will use the authentication group configured to authenticate to the network devices.

See https://developer.cisco.com/docs/nso/guides/the-restconf-api/#getting-started for more details on working with the RESTCONF API. See "External token authentication/validation" if you require another HTTP authentication method in the same link.

Additionally, take a look at this example (inspired by the NSO examples built-in) that uses RESTCONF to do some changes on NSO https://developer.cisco.com/codeexchange/github/repo/jillesca/nso-restconf-dns-example/ you can run it, click on the "Run in Cloud IDE" button on the right side of the banner.