From 39a765ceefb2f2602394340d18fa8530dded1a4b Mon Sep 17 00:00:00 2001 From: Claudemirovsky <63046606+Claudemirovsky@users.noreply.github.com> Date: Sun, 26 Nov 2023 11:42:11 -0300 Subject: [PATCH 1/2] fix: Don't hardcore auth token --- .../tachiyomi/animeextension/id/kuramanime/Kuramanime.kt | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/id/kuramanime/src/eu/kanade/tachiyomi/animeextension/id/kuramanime/Kuramanime.kt b/src/id/kuramanime/src/eu/kanade/tachiyomi/animeextension/id/kuramanime/Kuramanime.kt index 32f685d4f2..ea290a28ae 100644 --- a/src/id/kuramanime/src/eu/kanade/tachiyomi/animeextension/id/kuramanime/Kuramanime.kt +++ b/src/id/kuramanime/src/eu/kanade/tachiyomi/animeextension/id/kuramanime/Kuramanime.kt @@ -171,8 +171,15 @@ class Kuramanime : ConfigurableAnimeSource, ParsedAnimeHttpSource() { } } + private val scriptToken by lazy { + client.newCall(GET("$baseUrl/assets/js/arc-signal.min.js")).execute() + .use { it.body.string() } + .substringAfter("kuramanime:\"+\"") + .substringBefore('"') + } + private fun getRequestHash(headers: Headers): String { - val auth = "kuramanime:FDWUjAg6FXZpcbyTAkWrsgS8qAJNDDXKts:${System.currentTimeMillis()}" + val auth = "kuramanime:${scriptToken}ts:${System.currentTimeMillis()}" .let { Base64.encode(it.toByteArray(), Base64.NO_WRAP) } .let { Base64.encodeToString(it, Base64.NO_WRAP) } .let { URLEncoder.encode(it, "UTF-8") } From 26d99481888aab654b184e7a5a12d8025f93e5cd Mon Sep 17 00:00:00 2001 From: Claudemirovsky <63046606+Claudemirovsky@users.noreply.github.com> Date: Sun, 26 Nov 2023 11:42:36 -0300 Subject: [PATCH 2/2] chore: Bump version --- src/id/kuramanime/build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/id/kuramanime/build.gradle b/src/id/kuramanime/build.gradle index e52e4a29a6..bdd5b83b8a 100644 --- a/src/id/kuramanime/build.gradle +++ b/src/id/kuramanime/build.gradle @@ -7,7 +7,7 @@ ext { extName = 'Kuramanime' pkgNameSuffix = 'id.kuramanime' extClass = '.Kuramanime' - extVersionCode = 9 + extVersionCode = 10 libVersion = '13' }