Commit 723c99982c

723c99982c814fc6e565e60a9b7512e80a3f8853

parent: 3427782e31

Unsigned

Wraient <wraient.911@gmail.com> · 2026-04-22 16:38 UTC

fix: allanime encryption 🫩

Layout: unified · split

internal/episode_url.go +11 −5
@@ -37,7 +37,7 @@ type result struct {
3737}
3838
3939func decodeTobeparsed(blob string) string {
40 key := []byte("SimtVuagFbGR2K7P")
40 key := []byte("Xot36i3lK3:v1")
4141 hash := sha256.Sum256(key)
4242
4343 data, err := base64.StdEncoding.DecodeString(blob)
@@ -46,13 +46,19 @@ func decodeTobeparsed(blob string) string {
4646 return ""
4747 }
4848
49 if len(data) < 28 {
50 Log(fmt.Sprint("Data too short to contain IV and ciphertext"))
49 if len(data) < 29 {
50 Log("Data too short to contain tobeparsed payload")
5151 return ""
5252 }
5353
54 iv := data[:12]
55 ct := data[12:]
54 // The payload format is: 1-byte header, 12-byte IV, ciphertext, 16-byte trailer.
55 iv := data[1:13]
56 ctLen := len(data) - 13 - 16
57 if ctLen <= 0 {
58 Log("Ciphertext length is invalid in tobeparsed payload")
59 return ""
60 }
61 ct := data[13 : 13+ctLen]
5662
5763 ctrIV := make([]byte, 16)
5864 copy(ctrIV, iv)