Compare commits

..

2 Commits

Author SHA1 Message Date
RamiBerm
5d36d9184d fix enterprise cors (#592) 2022-01-06 12:39:03 +02:00
RamiBerm
63122cb0a7 TRA-4147 simpler kratos password policy (#590) 2022-01-06 12:15:46 +02:00
3 changed files with 4 additions and 4 deletions

View File

@@ -1,4 +1,4 @@
FROM oryd/kratos:v0.8.0-sqlite
FROM gcr.io/up9-docker-hub/mizu-kratos-base/simple-password-policy:latest
USER root

View File

@@ -6,7 +6,7 @@ func CORSMiddleware() gin.HandlerFunc {
return func(c *gin.Context) {
c.Writer.Header().Set("Access-Control-Allow-Origin", "*")
c.Writer.Header().Set("Access-Control-Allow-Credentials", "true")
c.Writer.Header().Set("Access-Control-Allow-Headers", "Content-Type, Content-Length, Accept-Encoding, X-CSRF-Token, Authorization, accept, origin, Cache-Control, X-Requested-With")
c.Writer.Header().Set("Access-Control-Allow-Headers", "Content-Type, Content-Length, Accept-Encoding, X-CSRF-Token, Authorization, accept, origin, Cache-Control, X-Requested-With, x-session-token")
c.Writer.Header().Set("Access-Control-Allow-Methods", "POST, OPTIONS, GET, PUT")
if c.Request.Method == "OPTIONS" {

View File

@@ -17,8 +17,8 @@ export const InstallPage: React.FC = () => {
const {setPage} = useContext(MizuContext);
const onFormSubmit = async () => {
if (password.length < 8) {
toast.error("Password must be at least 8 characters long");
if (password.length < 4) {
toast.error("Password must be at least 4 characters long");
return;
} else if (password !== passwordConfirm) {
toast.error("Passwords do not match");