Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement proposal to allow Pinniped custom resources to ref configmaps or secrets for CA bundles #1996

Merged
merged 99 commits into from
Aug 5, 2024

Commits on Aug 5, 2024

  1. update go templates for TLSSpec for concierge and supervisor

    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    842f14a View commit details
    Browse the repository at this point in the history
  2. run hack/update.sh

    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    19c3f2c View commit details
    Browse the repository at this point in the history
  3. add CRD validation integration tests

    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    7e6dadb View commit details
    Browse the repository at this point in the history
  4. refactor tls spec validation into its own package

    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    080c75e View commit details
    Browse the repository at this point in the history
  5. unify TLS Spec between supervisor and concierge

    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    aab1ee9 View commit details
    Browse the repository at this point in the history
  6. update supervisor controllers

    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    3a969a8 View commit details
    Browse the repository at this point in the history
  7. get all supervisor unit tests to pass

    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    199562f View commit details
    Browse the repository at this point in the history
  8. webhook cache filler

    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    207bac9 View commit details
    Browse the repository at this point in the history
  9. jwt cache filler

    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    9ab7c39 View commit details
    Browse the repository at this point in the history
  10. integration tests pass

    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    90e8cc8 View commit details
    Browse the repository at this point in the history
  11. update supervisor RBAC to allow get, list, and watch on configmaps

    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    edc327b View commit details
    Browse the repository at this point in the history
  12. more integration tests pass

    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    afcd80d View commit details
    Browse the repository at this point in the history
  13. integration tests for supervisor oidc, ldap, activedirectory IDP

    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    821a893 View commit details
    Browse the repository at this point in the history
  14. add namespace to jwt authenticator controller

    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    6a610a9 View commit details
    Browse the repository at this point in the history
  15. integration tests for supervisor oidc, ldap, activedirectory IDP

    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    8eb15a9 View commit details
    Browse the repository at this point in the history
  16. integration tests for concierge authenticators

    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    cb4b63f View commit details
    Browse the repository at this point in the history
  17. test secret and configmap filtering in concierge authenticator contro…

    …llers
    
    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    1b7a26d View commit details
    Browse the repository at this point in the history
  18. add code review todos and light refactoring

    Co-authored-by: Ryan Richard <[email protected]>
    joshuatcasey and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    6e9023e View commit details
    Browse the repository at this point in the history
  19. jwtauthenticator controller redoes validations when external CA bundl…

    …e changes
    
    Co-authored-by: Ryan Richard <[email protected]>
    joshuatcasey and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    bf1c02d View commit details
    Browse the repository at this point in the history
  20. error when CA bundle from Secret or ConfigMap is empty

    Co-authored-by: Joshua Casey <[email protected]>
    cfryanr and joshuatcasey committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    920b519 View commit details
    Browse the repository at this point in the history
  21. Configuration menu
    Copy the full SHA
    2d5943b View commit details
    Browse the repository at this point in the history
  22. Configuration menu
    Copy the full SHA
    66401b4 View commit details
    Browse the repository at this point in the history
  23. Configuration menu
    Copy the full SHA
    373713f View commit details
    Browse the repository at this point in the history
  24. Configuration menu
    Copy the full SHA
    8060e82 View commit details
    Browse the repository at this point in the history
  25. Configuration menu
    Copy the full SHA
    72745cd View commit details
    Browse the repository at this point in the history
  26. Configuration menu
    Copy the full SHA
    288e092 View commit details
    Browse the repository at this point in the history
  27. Configuration menu
    Copy the full SHA
    756966c View commit details
    Browse the repository at this point in the history
  28. Fix e2e_test.go

    Co-authored-by: Joshua Casey <[email protected]>
    cfryanr and joshuatcasey committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    30c0fd4 View commit details
    Browse the repository at this point in the history
  29. Fix *_tls_spec_test.go for old versions of Kubernetes

    Co-authored-by: Joshua Casey <[email protected]>
    cfryanr and joshuatcasey committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    a4ad5d6 View commit details
    Browse the repository at this point in the history
  30. Configuration menu
    Copy the full SHA
    d62d6a1 View commit details
    Browse the repository at this point in the history
  31. Configuration menu
    Copy the full SHA
    0f103ed View commit details
    Browse the repository at this point in the history
  32. Concierge external TLS static integration tests use the real URL of t…

    …he deployed local-user-authenticator
    joshuatcasey authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    d5e3ad9 View commit details
    Browse the repository at this point in the history
  33. Configuration menu
    Copy the full SHA
    afec420 View commit details
    Browse the repository at this point in the history
  34. Integration tests should use a helper func to infer Supervisor's down…

    …stream issuer URL
    joshuatcasey authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    0f9352d View commit details
    Browse the repository at this point in the history
  35. Supervisor TLS spec integration tests should use an OIDC issuer url f…

    …rom the test environment
    joshuatcasey authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    d74c2a6 View commit details
    Browse the repository at this point in the history
  36. Configuration menu
    Copy the full SHA
    09724cf View commit details
    Browse the repository at this point in the history
  37. Configuration menu
    Copy the full SHA
    3a303cc View commit details
    Browse the repository at this point in the history
  38. Configuration menu
    Copy the full SHA
    f381c92 View commit details
    Browse the repository at this point in the history
  39. Add GitHubIdentityProvider to the Supervisor TLS config static valida…

    …tion integration tests
    
    Co-authored-by: Ryan Richard <[email protected]>
    joshuatcasey and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    4b2ed52 View commit details
    Browse the repository at this point in the history
  40. Add LDAPIdentityProvider and ActiveDirectoryIdentityProvider to the S…

    …upervisor TLS config static validation integration tests
    
    Co-authored-by: Ryan Richard <[email protected]>
    joshuatcasey and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    b7c26c4 View commit details
    Browse the repository at this point in the history
  41. Modify Concierge/Superivsor TLS spec integration tests to allow for o…

    …lder K8s versions
    joshuatcasey authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    4ec5766 View commit details
    Browse the repository at this point in the history
  42. Configuration menu
    Copy the full SHA
    414ff50 View commit details
    Browse the repository at this point in the history
  43. Fix integration test typo

    joshuatcasey authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    60f82d2 View commit details
    Browse the repository at this point in the history
  44. refactor InferSupervisorIssuerURL() func; remove a TODO

    Co-authored-by: Joshua Casey <[email protected]>
    Co-authored-by: Ashish Amarnath <[email protected]>
    3 people committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    ca2dd2d View commit details
    Browse the repository at this point in the history
  45. Configuration menu
    Copy the full SHA
    06b47a5 View commit details
    Browse the repository at this point in the history
  46. Configuration menu
    Copy the full SHA
    adb460b View commit details
    Browse the repository at this point in the history
  47. Configuration menu
    Copy the full SHA
    9420bfd View commit details
    Browse the repository at this point in the history
  48. Fix some integration tests

    joshuatcasey authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    de86809 View commit details
    Browse the repository at this point in the history
  49. Fix another integration test

    joshuatcasey authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    9a16dc2 View commit details
    Browse the repository at this point in the history
  50. Minor refactor

    Co-authored-by: Ryan Richard <[email protected]>
    joshuatcasey and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    e3ed722 View commit details
    Browse the repository at this point in the history
  51. When reading CA bundle from a secret/configmap, return more specific err

    When the bundle does not contain any certs, make the error more
    specific.
    
    Co-authored-by: Ryan Richard <[email protected]>
    joshuatcasey and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    242fa8a View commit details
    Browse the repository at this point in the history
  52. store ca bundle hash in validated settings cache

    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    2a62bee View commit details
    Browse the repository at this point in the history
  53. add unit tests for validatedsettings cache storing ca bundle hash

    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    a1dcba4 View commit details
    Browse the repository at this point in the history
  54. refactor tlsconfigutil to return a caBundle type

    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    005dbf3 View commit details
    Browse the repository at this point in the history
  55. update jwtcachefiller to use new tlsconfigutil.CABundle type

    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    282b949 View commit details
    Browse the repository at this point in the history
  56. Configuration menu
    Copy the full SHA
    15d0006 View commit details
    Browse the repository at this point in the history
  57. Configuration menu
    Copy the full SHA
    0711093 View commit details
    Browse the repository at this point in the history
  58. Refactor tlsconfigutil.getCertPool to return a CABundle and change it…

    …s name to buildCABundle
    joshuatcasey authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    e82cb2c View commit details
    Browse the repository at this point in the history
  59. Refactor tlsconfigutil.buildCABundle to make it more clear where the …

    …bundle is coming from
    joshuatcasey authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    34eff2a View commit details
    Browse the repository at this point in the history
  60. Configuration menu
    Copy the full SHA
    4cf0e46 View commit details
    Browse the repository at this point in the history
  61. Configuration menu
    Copy the full SHA
    fcceeed View commit details
    Browse the repository at this point in the history
  62. Remove tlsconfigutil.CABundle.IsEqual and ensure that tlsconfigutil.N…

    …ewCABundle handles nil/empty input
    
    Co-authored-by: Ryan Richard <[email protected]>
    joshuatcasey and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    99cfc4f View commit details
    Browse the repository at this point in the history
  63. Introduce type alias CABundleHash for the hash of a CA bundle ([32]byte)

    Co-authored-by: Ryan Richard <[email protected]>
    Co-authored-by: Ashish Amarnath <[email protected]>
    3 people committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    a888083 View commit details
    Browse the repository at this point in the history
  64. Configuration menu
    Copy the full SHA
    f5da417 View commit details
    Browse the repository at this point in the history
  65. fix bug in webhookcachefiller caused when status update returns error

    Also refactor test assertions regarding log statements in
    jwtcachefiller_test.go and webhookcachefiller_test.go
    
    Co-authored-by: Ashish Amarnath <[email protected]>
    cfryanr and ashish-amarnath committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    dfef9f4 View commit details
    Browse the repository at this point in the history
  66. add unit tests for validatedsettings cache storing ca bundle hash

    Signed-off-by: Ashish Amarnath <[email protected]>
    
    Co-authored-by: Ryan Richard <[email protected]>
    ashish-amarnath and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    81d42cb View commit details
    Browse the repository at this point in the history
  67. Configuration menu
    Copy the full SHA
    9f17ba5 View commit details
    Browse the repository at this point in the history
  68. skip external CA bundle tests when CA bundle is empty

    Co-authored-by: Ashish Amarnath <[email protected]>
    cfryanr and ashish-amarnath committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    3891f90 View commit details
    Browse the repository at this point in the history
  69. do not make any assumption about OIDC issuer 404 page body in test

    Instead of using Dex or Okta, use a fake localhost issuer which
    does not exist. This will give a consistent connection error
    message. Needed because Dex and Okta return different 404 error
    pages, so we can't easily make a test assertion that works for both.
    
    Co-authored-by: Ashish Amarnath <[email protected]>
    cfryanr and ashish-amarnath committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    8725ab4 View commit details
    Browse the repository at this point in the history
  70. Configuration menu
    Copy the full SHA
    290676e View commit details
    Browse the repository at this point in the history
  71. Configuration menu
    Copy the full SHA
    dedd51d View commit details
    Browse the repository at this point in the history
  72. webhookcontroller now only logs the webhook authenticator name instea…

    …d of an object
    
    Co-authored-by: Ryan Richard <[email protected]>
    joshuatcasey and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    05a2fd9 View commit details
    Browse the repository at this point in the history
  73. Configuration menu
    Copy the full SHA
    ca5bb21 View commit details
    Browse the repository at this point in the history
  74. webhookcachefiller adds more detail when it chooses to update or not …

    …update status conditions
    joshuatcasey authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    1438f06 View commit details
    Browse the repository at this point in the history
  75. Configuration menu
    Copy the full SHA
    15c84fc View commit details
    Browse the repository at this point in the history
  76. jwtcachefiller now tests for exact log lines and prints when it choos…

    …es to not update the status
    joshuatcasey authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    d6d66fa View commit details
    Browse the repository at this point in the history
  77. update expectation conditions message when CA bundle is not configured

    fix a typo where we intended to use a configmap instead of a secret
    
    Signed-off-by: Ashish Amarnath <[email protected]>
    
    Co-authored-by: Ryan Richard <[email protected]>
    ashish-amarnath and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    a0c259f View commit details
    Browse the repository at this point in the history
  78. webhookcachefiller and jwtcachefiller always update status when needed

    Even when the authenticator is found in the cache, try to update its
    status. Failing to do so would mean that the actual status will not
    be overwritten by the controller's newly computed desired status.
    
    Co-authored-by: Ashish Amarnath <[email protected]>
    cfryanr and ashish-amarnath committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    ed50294 View commit details
    Browse the repository at this point in the history
  79. secret/configmap with CA bundle to be created in namespace where pinn…

    …iped is installed
    
    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    19c4acf View commit details
    Browse the repository at this point in the history
  80. update generated api docs

    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    43964ff View commit details
    Browse the repository at this point in the history
  81. Configuration menu
    Copy the full SHA
    91ef689 View commit details
    Browse the repository at this point in the history
  82. small refactors

    cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    02e41ba View commit details
    Browse the repository at this point in the history
  83. Configuration menu
    Copy the full SHA
    e0235ed View commit details
    Browse the repository at this point in the history
  84. refactor test helpers in supervisor_login_test.go

    Co-authored-by: Ashish Amarnath <[email protected]>
    cfryanr and ashish-amarnath committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    2181418 View commit details
    Browse the repository at this point in the history
  85. Add integration tests for tls spec validation in JWTAuthenticator and…

    … WebhookAuthenticator
    
    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    c340509 View commit details
    Browse the repository at this point in the history
  86. add integration test for TLS config validation in OIDCIdentityProvider

    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    59402bc View commit details
    Browse the repository at this point in the history
  87. Configuration menu
    Copy the full SHA
    23129da View commit details
    Browse the repository at this point in the history
  88. Configuration menu
    Copy the full SHA
    a40c88e View commit details
    Browse the repository at this point in the history
  89. Configuration menu
    Copy the full SHA
    67de14a View commit details
    Browse the repository at this point in the history
  90. minor test refactor

    cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    2ebf9d3 View commit details
    Browse the repository at this point in the history
  91. Configuration menu
    Copy the full SHA
    db2d7c8 View commit details
    Browse the repository at this point in the history
  92. test more condition message cases in concierge_tls_spec_test.go and s…

    …upervisor_tls_spec_test.go
    cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    4eb9a09 View commit details
    Browse the repository at this point in the history
  93. improve api docs for TLSSpec in authenticator and IDP specs

    Signed-off-by: Ashish Amarnath <[email protected]>
    Co-authored-by: Ashish Amarnath <[email protected]>
    cfryanr and ashish-amarnath committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    59c2295 View commit details
    Browse the repository at this point in the history
  94. Configuration menu
    Copy the full SHA
    d4ac69d View commit details
    Browse the repository at this point in the history
  95. refactor to use new certificateAuthorityDataSourceKind enum

    Signed-off-by: Ashish Amarnath <[email protected]>
    ashish-amarnath authored and cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    b70db9d View commit details
    Browse the repository at this point in the history
  96. Configuration menu
    Copy the full SHA
    06b7d30 View commit details
    Browse the repository at this point in the history
  97. Revert "Add integration tests for tls spec validation in JWTAuthentic…

    …ator and WebhookAuthenticator"
    
    This reverts commit c340509.
    cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    23fd15f View commit details
    Browse the repository at this point in the history
  98. Revert "add integration test for TLS config validation in OIDCIdentit…

    …yProvider"
    
    This reverts commit 59402bc.
    cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    fdeca2c View commit details
    Browse the repository at this point in the history
  99. Revert "add integration test for TLS config validation in GitHubIdent…

    …ityProvider"
    
    This reverts commit 23129da.
    cfryanr committed Aug 5, 2024
    Configuration menu
    Copy the full SHA
    2af510a View commit details
    Browse the repository at this point in the history