code: func (cli *DaemonCli) initMiddlewares(s *apiserver.Server, cfg *apiserver.Config, pluginStore plugingetter.PluginGetter) error {
  	v := cfg.Version
  
  	exp := middleware.NewExperimentalMiddleware(cli.Config.Experimental)
  	s.UseMiddleware(exp)
  
  	vm := middleware.NewVersionMiddleware(v, api.DefaultVersion, api.MinVersion)
  	s.UseMiddleware(vm)
  
  	if cfg.CorsHeaders != "" {
  		c := middleware.NewCORSMiddleware(cfg.CorsHeaders)
  		s.UseMiddleware(c)
  	}
  
  	cli.authzMiddleware = authorization.NewMiddleware(cli.Config.AuthorizationPlugins, pluginStore)
  	cli.Config.AuthzMiddleware = cli.authzMiddleware
  	s.UseMiddleware(cli.authzMiddleware)
  	return nil
  }
docs: // TODO: remove this from cli and return the authzMiddleware