GetServiceProvider returns the Service Provider metadata for the service provider ID, which is typically the service provider's metadata URL. If an appropriate service provider cannot be found then the returned error must be os.ErrNotExist.
(r *http.Request, serviceProviderID string)
| 26 | // metadata URL. If an appropriate service provider cannot be found then |
| 27 | // the returned error must be os.ErrNotExist. |
| 28 | func (s *Server) GetServiceProvider(r *http.Request, serviceProviderID string) (*saml.EntityDescriptor, error) { |
| 29 | s.idpConfigMu.RLock() |
| 30 | defer s.idpConfigMu.RUnlock() |
| 31 | rv, ok := s.serviceProviders[serviceProviderID] |
| 32 | if !ok { |
| 33 | return nil, os.ErrNotExist |
| 34 | } |
| 35 | return rv, nil |
| 36 | } |
| 37 | |
| 38 | // HandleListServices handles the `GET /services/` request and responds with a JSON formatted list |
| 39 | // of service names. |
nothing calls this directly
no outgoing calls
no test coverage detected