security.toml 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105
  1. # Put this file to one of the location, with descending priority
  2. # ./security.toml
  3. # $HOME/.seaweedfs/security.toml
  4. # /etc/seaweedfs/security.toml
  5. # this file is read by master, volume server, and filer
  6. # comma separated origins allowed to make requests to the filer and s3 gateway.
  7. # enter in this format: https://domain.com, or http://localhost:port
  8. [cors.allowed_origins]
  9. values = "*"
  10. # this jwt signing key is read by master and volume server, and it is used for write operations:
  11. # - the Master server generates the JWT, which can be used to write a certain file on a volume server
  12. # - the Volume server validates the JWT on writing
  13. # the jwt defaults to expire after 10 seconds.
  14. [jwt.signing]
  15. key = ""
  16. expires_after_seconds = 10 # seconds
  17. # by default, if the signing key above is set, the Volume UI over HTTP is disabled.
  18. # by setting ui.access to true, you can re-enable the Volume UI. Despite
  19. # some information leakage (as the UI is not authenticated), this should not
  20. # pose a security risk.
  21. [access]
  22. ui = false
  23. # this jwt signing key is read by master and volume server, and it is used for read operations:
  24. # - the Master server generates the JWT, which can be used to read a certain file on a volume server
  25. # - the Volume server validates the JWT on reading
  26. # NOTE: jwt for read is only supported with master+volume setup. Filer does not support this mode.
  27. [jwt.signing.read]
  28. key = ""
  29. expires_after_seconds = 10 # seconds
  30. # If this JWT key is configured, Filer only accepts writes over HTTP if they are signed with this JWT:
  31. # - f.e. the S3 API Shim generates the JWT
  32. # - the Filer server validates the JWT on writing
  33. # the jwt defaults to expire after 10 seconds.
  34. [jwt.filer_signing]
  35. key = ""
  36. expires_after_seconds = 10 # seconds
  37. # If this JWT key is configured, Filer only accepts reads over HTTP if they are signed with this JWT:
  38. # - f.e. the S3 API Shim generates the JWT
  39. # - the Filer server validates the JWT on writing
  40. # the jwt defaults to expire after 10 seconds.
  41. [jwt.filer_signing.read]
  42. key = ""
  43. expires_after_seconds = 10 # seconds
  44. # all grpc tls authentications are mutual
  45. # the values for the following ca, cert, and key are paths to the PERM files.
  46. # the host name is not checked, so the PERM files can be shared.
  47. [grpc]
  48. ca = ""
  49. # Set wildcard domain for enable TLS authentication by common names
  50. allowed_wildcard_domain = "" # .mycompany.com
  51. [grpc.volume]
  52. cert = ""
  53. key = ""
  54. allowed_commonNames = "" # comma-separated SSL certificate common names
  55. [grpc.master]
  56. cert = ""
  57. key = ""
  58. allowed_commonNames = "" # comma-separated SSL certificate common names
  59. [grpc.filer]
  60. cert = ""
  61. key = ""
  62. allowed_commonNames = "" # comma-separated SSL certificate common names
  63. [grpc.s3]
  64. cert = ""
  65. key = ""
  66. allowed_commonNames = "" # comma-separated SSL certificate common names
  67. [grpc.msg_broker]
  68. cert = ""
  69. key = ""
  70. allowed_commonNames = "" # comma-separated SSL certificate common names
  71. # use this for any place needs a grpc client
  72. # i.e., "weed backup|benchmark|filer.copy|filer.replicate|mount|s3|upload"
  73. [grpc.client]
  74. cert = ""
  75. key = ""
  76. # volume server https options
  77. # Note: work in progress!
  78. # this does not work with other clients, e.g., "weed filer|mount" etc, yet.
  79. [https.client]
  80. enabled = true
  81. [https.volume]
  82. cert = ""
  83. key = ""
  84. ca = ""
  85. [https.master]
  86. cert = ""
  87. key = ""
  88. ca = ""