Experimental KiwiFlare solver which appears to work based on my one test

This commit is contained in:
barelyprofessional
2024-09-01 03:01:11 +08:00
parent e4b1821a5b
commit 2906481b27
3 changed files with 194 additions and 1 deletions

View File

@@ -46,6 +46,13 @@ public class ChatBot
{
RefreshXfToken().Wait(_cancellationToken);
}
// var kiwiflare = new KiwiFlare(settings[BuiltIn.Keys.KiwiFarmsDomain].Value,
// settings[BuiltIn.Keys.Proxy].Value, _cancellationToken);
// var challenge = kiwiflare.GetChallenge().Result;
// var solution = kiwiflare.SolveChallenge(challenge).Result;
// var token = kiwiflare.SubmitAnswer(solution).Result;
// var test = kiwiflare.CheckAuth(token).Result;
KfClient = new ChatClient(new ChatClientConfigModel
{
@@ -55,7 +62,6 @@ public class ChatBot
Proxy = settings[BuiltIn.Keys.Proxy].Value,
ReconnectTimeout = settings[BuiltIn.Keys.KiwiFarmsWsReconnectTimeout].ToType<int>()
});
_logger.Debug("Creating bot command instance");
_botCommands = new BotCommands(this, _cancellationToken);