git.yaml 618 B

1234567891011121314151617181920
  1. - name: allow-git-clients
  2. action: ALLOW
  3. expression:
  4. all:
  5. - >
  6. (
  7. userAgent.startsWith("git/") ||
  8. userAgent.contains("libgit") ||
  9. userAgent.startsWith("go-git") ||
  10. userAgent.startsWith("JGit/") ||
  11. userAgent.startsWith("JGit-")
  12. )
  13. - '"Accept" in headers'
  14. - headers["Accept"] == "*/*"
  15. - '"Cache-Control" in headers'
  16. - headers["Cache-Control"] == "no-cache"
  17. - '"Pragma" in headers'
  18. - headers["Pragma"] == "no-cache"
  19. - '"Accept-Encoding" in headers'
  20. - headers["Accept-Encoding"].contains("gzip")