deezer

package module
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 8, 2021 License: OSL-3.0 Imports: 11 Imported by: 0

README

Deezer

Listen, um, I don’t really know what’s going on here, but I’m leaving. I don’t know where exactly, but I’m gonna start over.

Come with me. Please.

Paint it Black (2016)

Download audio from Deezer

API

GetData:

Given a SNG_ID, return Results.Data

GetSource:

Given SNG_ID, Results.Data and quality, return audio URL

Decrypt:

Given SNG_ID and byte slice, decrypt byte slice in place

Thanks

AES

Used for URL Generation

Go to the "source" panel of browser debugger, to show the deezer webworker source code. pretty print the source. put a breakpoint on the latest occurrence of the "JSON" word. Play a new track, to trigger the breakpoint You see the keys in the the current scope.

[...key].map(e=>String.fromCharCode(e)).join('');

CBC

Used for track deciphering

Same method as the DZR_AES, but the CBC keys are split in 2 arrays that need to be reassembled using the following script

let a=[97, ... 103];
let b=[49, ... 52];

[].
concat(...a.map((c,i)=>[a[i],b[i]]).reverse()).
map(e=>String.fromCharCode(e)).
join(''):

Documentation

Index

Constants

View Source
const (
	FLAC    = '9'
	MP3_320 = '3'
)

Variables

This section is empty.

Functions

func Decrypt

func Decrypt(sngId string, data []byte) error

func GetData

func GetData(sngId, token string) (deezData, error)

func GetSource

func GetSource(sngId string, data deezData, format rune) (string, error)

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL