Fabriceli opened a new issue, #8686:
URL: https://github.com/apache/apisix/issues/8686

   ### Description
   
   Hi, guys
    
   I found that if enable `openid-connect` plugin in consumer, it will return 
an error: `require one auth plugin`. 
   I want to support the `openid-conenct` as an **auth** plugin, so that we can 
set up Consumer with `openid-connect` plugin.
   
   Concurrent `auth` plugins in APISIX 3.1.0 version:
   
![image](https://user-images.githubusercontent.com/13508022/212546810-fe92c230-2494-483d-835a-5815396b7c30.png)
   
   Reference APISIX `openid-connect` plugin 
[code](https://github.com/apache/apisix/blob/master/apisix/plugins/openid-connect.lua#L140):
   ```lua
   local _M = {
       version = 0.2,
       priority = 2599,
       name = plugin_name,
       schema = schema,
   }
   ```
   
    [apisix consumer reference 
code](https://github.com/apache/apisix/blob/master/apisix/admin/consumers.lua#L61):
   ```lua
   local count_auth_plugin = 0
   for name, conf in pairs(conf.plugins) do
       local plugin_obj = plugin.get(name)
       if plugin_obj.type == 'auth' then
           count_auth_plugin = count_auth_plugin + 1
       end
   end
   
   if count_auth_plugin == 0 then
       return nil, {error_msg = "require one auth plugin"}
   end
   ```
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to