1
0
mirror of https://github.com/chris124567/hulu synced 2024-11-22 08:07:30 +00:00

fix bug in random UUID generation for Hulu /playlist endpoint

This commit is contained in:
Christopher Tarry 2021-11-21 14:31:38 -05:00
parent ff25377cf1
commit 0bf67413d4
2 changed files with 2 additions and 1 deletions

View File

@ -167,7 +167,7 @@ func (c Client) Playlist(sessionKey int, eabID string) (p Playlist, err error) {
randUUID := func() string {
randChars := func(n int) (s string) {
c := []byte("ABCDEF0123456789")
for i := 0; i < 4; i++ {
for i := 0; i < n; i++ {
s += string(c[frand.Intn(len(c))])
}
return

View File

@ -5,6 +5,7 @@ import (
"time"
)
// These are constants taken from https://player.hulu.com/site/dash/308343-site-curiosity/js/app.js
var (
deejayKey = []byte{110, 191, 200, 79, 60, 48, 66, 23, 178, 15, 217, 166, 108, 181, 149, 127}
)