Add cell id to kas cookie

As per discussion in &18384 (comment 2633450371), rails sets a cookie for browsers to authenticate when accessing kas endpoints. The cookie value needs to contain the cell id so that Cells HTTP router could route the request correctly.

This issue is to:

  • Add cell id to new cookie values. This should be similar to how other Cells-aware cookies are constructed.
  • Accept new cookie format for authentication in Rails endpoint that kas calls to validate the cookie (/api/v4/internal/kubernetes/authorize_proxy_user).
  • Make sure to keep accepting the old cookie format too! We cannot remove support for it since there are browsers out there with that cookie set.

Relevant code:

Edited by Mikhail Mazurskiy