2023-12-17 14:19:05 +00:00
|
|
|
package config
|
|
|
|
|
2024-01-15 10:33:24 +00:00
|
|
|
import (
|
2024-01-25 11:43:39 +00:00
|
|
|
authservice "git.gocasts.ir/ebhomengo/niki/service/auth"
|
2024-01-15 10:33:24 +00:00
|
|
|
benefactorservice "git.gocasts.ir/ebhomengo/niki/service/benefactor/benefactor"
|
|
|
|
)
|
|
|
|
|
2023-12-17 14:19:05 +00:00
|
|
|
func Default() Config {
|
2024-01-15 10:33:24 +00:00
|
|
|
cfx := Config{
|
|
|
|
Auth: authservice.Config{
|
|
|
|
AccessExpirationTime: AccessTokenExpireDuration,
|
|
|
|
RefreshExpirationTime: RefreshTokenExpireDuration,
|
|
|
|
AccessSubject: AccessTokenSubject,
|
|
|
|
RefreshSubject: RefreshTokenSubject,
|
|
|
|
},
|
2024-01-25 11:43:39 +00:00
|
|
|
AdminAuth: authservice.Config{
|
|
|
|
AccessExpirationTime: AccessTokenExpireDuration,
|
|
|
|
RefreshExpirationTime: RefreshTokenExpireDuration,
|
|
|
|
AccessSubject: AccessTokenSubject,
|
|
|
|
RefreshSubject: RefreshTokenSubject,
|
|
|
|
},
|
2024-01-15 10:33:24 +00:00
|
|
|
|
|
|
|
BenefactorSvc: benefactorservice.Config{
|
|
|
|
OtpChars: OtpChars,
|
|
|
|
OtpExpireTime: OtpExpireTime,
|
|
|
|
},
|
|
|
|
}
|
|
|
|
|
|
|
|
return cfx
|
2023-12-17 14:19:05 +00:00
|
|
|
}
|