Skip to content
This repository has been archived by the owner on Nov 3, 2023. It is now read-only.

无损下载下来发现不是真正无损 #163

Open
djapple opened this issue Oct 17, 2023 · 20 comments
Open

无损下载下来发现不是真正无损 #163

djapple opened this issue Oct 17, 2023 · 20 comments

Comments

@djapple
Copy link

djapple commented Oct 17, 2023

下载下来的无损歌曲,从频谱分析只能达到了MP3 320Kbps
通过酷我下载的无损和QQFLACMUSICDOWNLOAD下载同一首歌频谱对比确实只有320Kbps
请作者修复下此问题

@QiuChenly
Copy link
Collaborator

没懂 酷我下的音源不是flac?

@djapple
Copy link
Author

djapple commented Oct 17, 2023

QQFlacMusicDownloader下载QQ音乐的歌曲下下来格式是FLAC,但是实际是MP3 320KBPS

@ggotost1990
Copy link

目前程序已经用不了了

@Huibq
Copy link

Huibq commented Oct 20, 2023

目前程序已经用不了了

没有吧,还能用

@QiuChenly
Copy link
Collaborator

谎报军情的都杀了

@ClareDuan
Copy link

目前程序已经用不了了

没有吧,还能用

今天用不了了,QQ接口已挂
错误细节:下载失败,解析服务器返回403错误代码。
下载失败,无法加载资源文件!解析歌曲下载地址失败! None

@Kev1nT
Copy link

Kev1nT commented Oct 23, 2023

目前程序已经用不了了

没有吧,还能用

今天用不了了,QQ接口已挂 错误细节:下载失败,解析服务器返回403错误代码。 下载失败,无法加载资源文件!解析歌曲下载地址失败! None

上午弄好了,下了两首歌
下午也403错误了

@Zzzz-1996
Copy link

接口的确挂了 软件真的不错 希望作者大大还能维护 感恩🥹

@QiuChenly
Copy link
Collaborator

大家可以提交其他接口 我找不到新接口了

@VoidVampire
Copy link

VoidVampire commented Oct 23, 2023

界面和UI一样吗?
所以“后端”有问题或“前端”?

@QiuChenly
Copy link
Collaborator

界面和UI一样吗? 所以“后端”有问题或“前端”?

没看懂

@VoidVampire
Copy link

啊,忘了吧
我正在使用它 Google Translate 😓

@QiuChenly
Copy link
Collaborator

sad. but u can say EnLang with me.

@VoidVampire
Copy link

VoidVampire commented Oct 23, 2023

Ah, got it.
I google translated past messages and in one of them you said there issue with "interface". So I was curious if the project backend is broken?
Also, is there any ETA for making this project work?

@haiwei1991
Copy link

Ah, got it. I google translated past messages and in one of them you said there issue with "interface". So I was curious if the project backend is broken? Also, is there any ETA for making this project work?

I think the "interface" you said should be means Api.

@QiuChenly
Copy link
Collaborator

yep. until now this project depend on use some 3rd private Server to get the VIP Permission Musics.i mean : the project not hack or other Magic code to illegal access target Server(e.g. Music163 / Tencent QQ Music), so when the 3rd private server got any error or offline, we can't got any resource of music.

so, we need any have vip permission user account's cookie or any 3rd private server to resolution VIP music file on target Music Server(like Tencent QQ Music or 163 Netease Music), otherwise the project will can't get normal work.

@lieternity
Copy link

大家可以提交其他接口 我找不到新接口了

我找到一个接口,但是无法通过mid获取

import requests


# 网站  https://music.ghxi.com/


# 1.先获取到解锁密码
# 2.再通过解锁密码给cookie权限
# 3.再通过搜索获取到songid(不知道是什么id,不像是qq音乐上的,我猜是加密的mid),再用songid获取到播放链接


# 通过小程序的接口获取到密码
def getpassworld():
    return requests.get("https://ghxcx.lovestu.com/api/index/today_secret").json()['data']


# 通过获取到的密码给cookie权限,但是权限过段时间会失效,具体多长时间我也不知道,
def unlockcookie(passwd):
    url = "https://music.ghxi.com/wp-admin/admin-ajax.php"

    payload = 'action=gh_music_ajax&type=postAuth&code={}'.format(passwd)
    headers = {
        'dnt': '1',
        'origin': 'https://music.ghxi.com',
        'referer': 'https://music.ghxi.com',
        'user-agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/108.0.0.0 Safari/537.36 Edg/108.0.1462.76',
        'Cookie': 'PHPSESSID=8q5nff3m73fo88p6ms0d907j4m',
        'content-type': 'application/x-www-form-urlencoded; charset=UTF-8',
        'Accept': '*/*',
        'Host': 'music.ghxi.com',
    }

    response = requests.request("POST", url, headers=headers, data=payload)

    print(response.text)


def guohe(musicname):
    ghheaders = {
        'content-type': 'application/x-www-form-urlencoded; charset=UTF-8',
        'cookie': 'PHPSESSID=8q5nff3m73fo88p6ms0d907j4m',
        'origin': 'https://music.ghxi.com',
        'referer': 'https://music.ghxi.com/',
        'user-agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/108.0.0.0 Safari/537.36 Edg/108.0.1462.76',
    }

    ghurl = "https://music.ghxi.com/wp-admin/admin-ajax.php"
    payload = {
        "action": "gh_music_ajax",
        "type": "search",
        "music_type": "qq",
        "search_word": musicname,
    }

    ghinfojson = requests.request("POST", ghurl, headers=ghheaders, data=payload).json()
    # 搜索到的歌曲信息
    print(ghinfojson)

    ghdata = {
        "action": "gh_music_ajax",
        "type": "getMusicUrl",
        "music_size": "flac",
        "music_type": "qq",
        "songid": ghinfojson['data'][0]['songid'],#第一首歌
    }
    ghjson = requests.post(ghurl, data=ghdata, headers=ghheaders).json()
    if ghjson['code'] == 200:
        return ghjson
    return False


if __name__ == '__main__':
    passwd = getpassworld()
    unlockcookie(passwd)
    print(guohe("周杰伦晴天"))

@VoidVampire
Copy link

@haiwei1991 @QiuChenly oh API issue, got it!!

@QiuChenly
Copy link
Collaborator

QiuChenly commented Oct 24, 2023

大家可以提交其他接口 我找不到新接口了

我找到一个接口,但是无法通过mid获取

import requests


# 网站  https://music.ghxi.com/


# 1.先获取到解锁密码
# 2.再通过解锁密码给cookie权限
# 3.再通过搜索获取到songid(不知道是什么id,不像是qq音乐上的,我猜是加密的mid),再用songid获取到播放链接


# 通过小程序的接口获取到密码
def getpassworld():
    return requests.get("https://ghxcx.lovestu.com/api/index/today_secret").json()['data']


# 通过获取到的密码给cookie权限,但是权限过段时间会失效,具体多长时间我也不知道,
def unlockcookie(passwd):
    url = "https://music.ghxi.com/wp-admin/admin-ajax.php"

    payload = 'action=gh_music_ajax&type=postAuth&code={}'.format(passwd)
    headers = {
        'dnt': '1',
        'origin': 'https://music.ghxi.com',
        'referer': 'https://music.ghxi.com',
        'user-agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/108.0.0.0 Safari/537.36 Edg/108.0.1462.76',
        'Cookie': 'PHPSESSID=8q5nff3m73fo88p6ms0d907j4m',
        'content-type': 'application/x-www-form-urlencoded; charset=UTF-8',
        'Accept': '*/*',
        'Host': 'music.ghxi.com',
    }

    response = requests.request("POST", url, headers=headers, data=payload)

    print(response.text)


def guohe(musicname):
    ghheaders = {
        'content-type': 'application/x-www-form-urlencoded; charset=UTF-8',
        'cookie': 'PHPSESSID=8q5nff3m73fo88p6ms0d907j4m',
        'origin': 'https://music.ghxi.com',
        'referer': 'https://music.ghxi.com/',
        'user-agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/108.0.0.0 Safari/537.36 Edg/108.0.1462.76',
    }

    ghurl = "https://music.ghxi.com/wp-admin/admin-ajax.php"
    payload = {
        "action": "gh_music_ajax",
        "type": "search",
        "music_type": "qq",
        "search_word": musicname,
    }

    ghinfojson = requests.request("POST", ghurl, headers=ghheaders, data=payload).json()
    # 搜索到的歌曲信息
    print(ghinfojson)

    ghdata = {
        "action": "gh_music_ajax",
        "type": "getMusicUrl",
        "music_size": "flac",
        "music_type": "qq",
        "songid": ghinfojson['data'][0]['songid'],#第一首歌
    }
    ghjson = requests.post(ghurl, data=ghdata, headers=ghheaders).json()
    if ghjson['code'] == 200:
        return ghjson
    return False


if __name__ == '__main__':
    passwd = getpassworld()
    unlockcookie(passwd)
    print(guohe("周杰伦晴天"))

哦 看错了 有别的参数信息吗 比如说 "music_size": "flac",

    "music_type": "qq",这些字段

@lieternity
Copy link

不知道了,前端的东西不多

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

10 participants