static JWTHelper() { string path = DirFileHelper.MapPath("SecretKey\\token.privateKey.key"); string key = DirFileHelper.ReadAllText(path); TokenPrivateKey = key; }
public static void LoadConfig() { ConfigPath = DirFileHelper.MapPath(ConfigPath); string context = DirFileHelper.ReadAllText(ConfigPath); RedisServers = context.JsonToList <RedisServerModel>(); }
static CustomActionFilterAttribute() { string path = DirFileHelper.MapPath("SecretKey\\api.privateKey.key"); PrivateKey = DirFileHelper.ReadAllText(path); path = DirFileHelper.MapPath("SecretKey\\api.publicKey.key"); PublicKey = DirFileHelper.ReadAllText(path); }