You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Authorino will reject (with 404 Not Found) any request for which there is no matching authconfig object. Exposing the hosts in the spec.authScheme object can lead to unwanted scenarios for the end user and it is, at the very least, error prone. One example to illustrate:
The route allows traffic for *.company.com, but the authconfig object have rules only for api.petstore.company.com, then a request for other.company.com will hit authorino and authorino will reject that traffic. Something clearly unwanted.
Kuadrant core should provide means to configure automatically the authorization process to only protect the wanted domains and pass through the remaining ones.
What
Regarding managed AuthConfig
The proposal is to remove hosts from spec.authScheme. The Authconfig object still needs a hosts field, so it will be the kuadrant core, the owner of the authconfig object, who will be filling the hosts field.
The hosts field will be computed in the following way:
When there are no rules, authconfig's hosts field will be read from the network resource (HTTPRoute or Gateway).
When there is at least one rule with the hosts field empty/missing, authconfig's hosts field will be read from the network resource (HTTPRoute or Gateway).
authconfig's hosts field will be the list of hosts appearing in the authpolicy rules
in this example, there is a rule with the hosts missing. Then the authconfig's hosts field will be [api.petstore.com, admin.petstore.com]
Regarding managed Istio's AuthorizationPolicy
If there is a rule in the kuadrant's auth that does not have hosts specified, kuadrant will add the hostnames from the network resource when reconciling the AuthorizationPolicy.
For example:
kind: AuthPolicyspec:
rules:
- paths: ["/toy*"]
The reconciled Istio's AuthorizationPolicy will include the network resource's (route) hostnames
The Istio's authorization policies configure a common (shared) envoy's authorization filter. The rules coming from a kuadrant's policy targeting a given route should all be scoped to the route's traffic workloads.
The text was updated successfully, but these errors were encountered:
I know there's already a PR ready for review, but wanted to ask whether would make sense or not to reflect the list of hosts targeted by the AuthPolicy within its Status ?
Motivation
Authorino will reject (with
404 Not Found
) any request for which there is no matching authconfig object. Exposing thehosts
in thespec.authScheme
object can lead to unwanted scenarios for the end user and it is, at the very least, error prone. One example to illustrate:The route allows traffic for
*.company.com
, but the authconfig object have rules only forapi.petstore.company.com
, then a request forother.company.com
will hit authorino and authorino will reject that traffic. Something clearly unwanted.Kuadrant core should provide means to configure automatically the authorization process to only protect the wanted domains and pass through the remaining ones.
What
AuthConfig
The proposal is to remove
hosts
fromspec.authScheme
. The Authconfig object still needs ahosts
field, so it will be the kuadrant core, the owner of the authconfig object, who will be filling thehosts
field.The
hosts
field will be computed in the following way:hosts
field will be read from the network resource (HTTPRoute or Gateway).hosts
field empty/missing, authconfig'shosts
field will be read from the network resource (HTTPRoute or Gateway).hosts
field will be the list of hosts appearing in the authpolicy rulesFor example:
in this example, there is a rule with the
hosts
missing. Then the authconfig'shosts
field will be[*.petstore.com]
For example:
in this example, there is a rule with the
hosts
missing. Then the authconfig'shosts
field will be[api.petstore.com, admin.petstore.com]
If there is a rule in the kuadrant's auth that does not have
hosts
specified, kuadrant will add the hostnames from the network resource when reconciling the AuthorizationPolicy.For example:
The reconciled Istio's AuthorizationPolicy will include the network resource's (route) hostnames
The Istio's authorization policies configure a common (shared) envoy's authorization filter. The rules coming from a kuadrant's policy targeting a given route should all be scoped to the route's traffic workloads.
The text was updated successfully, but these errors were encountered: