Enable Basic Auth in the Dev Portal
Basic Authentication for the Dev Portal can be enabled using any of the following ways:
Warnings:
Enabling authentication in the Dev Portal requires use of the Sessions plugin. Developers will not be able to log in if this is not properly set. For more information, see Sessions in the Dev Portal.
If using HTTP while testing, include "cookie_secure": false
in the config:
Or, if you have different subdomains for the portal_api_url
and portal_gui_host
, set the and cookie_samesite
properties as follows:
For more information about portal session configuration, see .
For more information about domains and cookies in Dev Portal sessions, see Domains.
- Navigate to the Dev Portal’s Settings page.
- Find Authentication plugin under the Authentication tab.
- Click Save Changes.
To patch a Dev Portal’s authentication property directly, run:
Kong allows for a default authentication plugin to be set in the Kong configuration file with the portal_auth
property.
In your kong.conf
file, set the property as follows:
This sets all Dev Portals to use Basic Authentication by default when initialized.