2016-01-29 00:24:12 +01:00
|
|
|
namespace Teknik.Configuration
|
|
|
|
{
|
|
|
|
public class UserConfig
|
|
|
|
{
|
|
|
|
public bool RegistrationEnabled { get; set; }
|
|
|
|
public bool LoginEnabled { get; set; }
|
2016-06-03 00:36:05 +02:00
|
|
|
public bool PasswordResetEnabled { get; set; }
|
2016-05-19 01:52:32 +02:00
|
|
|
public string UsernameFilter { get; set; }
|
2016-05-20 01:17:08 +02:00
|
|
|
public string UsernameFilterLabel { get; set; }
|
2016-05-19 01:52:32 +02:00
|
|
|
public int MinUsernameLength { get; set; }
|
|
|
|
public int MaxUsernameLength { get; set; }
|
2019-01-29 09:02:17 +01:00
|
|
|
public int MinPasswordLength { get; set; }
|
2016-05-17 06:56:17 +02:00
|
|
|
public string ReservedUsernameDefinitionFile { get; set; }
|
2017-02-20 02:50:05 +01:00
|
|
|
public decimal PremiumAccountPrice { get; set; }
|
|
|
|
public string PaymentType { get; set; }
|
2018-01-17 07:36:11 +01:00
|
|
|
public bool InviteCodeRequired { get; set; }
|
2018-10-26 07:22:53 +02:00
|
|
|
public IdentityServerConfig IdentityServerConfig { get; set; }
|
2016-01-29 00:24:12 +01:00
|
|
|
|
|
|
|
public UserConfig()
|
|
|
|
{
|
|
|
|
RegistrationEnabled = true;
|
|
|
|
LoginEnabled = true;
|
2016-06-03 00:36:05 +02:00
|
|
|
PasswordResetEnabled = true;
|
2016-05-19 01:52:32 +02:00
|
|
|
UsernameFilter = "^[a-zA-Z0-9_-]+(?:\\.[a-zA-Z0-9_-]+)*$";
|
2016-05-20 01:17:08 +02:00
|
|
|
UsernameFilterLabel = "AlphaNumeric Characters with Dashes, Underlines, and 0-1 Periods not in the beginning or end.";
|
2016-05-19 01:52:32 +02:00
|
|
|
MinUsernameLength = 1;
|
|
|
|
MaxUsernameLength = 35;
|
2019-01-29 09:02:17 +01:00
|
|
|
MinPasswordLength = 2;
|
2016-05-17 06:56:17 +02:00
|
|
|
ReservedUsernameDefinitionFile = string.Empty;
|
2017-02-20 02:50:05 +01:00
|
|
|
PremiumAccountPrice = 0;
|
|
|
|
PaymentType = "Donation";
|
2018-01-17 07:36:11 +01:00
|
|
|
InviteCodeRequired = false;
|
2018-10-26 07:22:53 +02:00
|
|
|
IdentityServerConfig = new IdentityServerConfig();
|
2016-01-29 00:24:12 +01:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|