Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenDocCN
BiliDriveEx
提交
a0079905
B
BiliDriveEx
项目概览
OpenDocCN
/
BiliDriveEx
通知
3
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
B
BiliDriveEx
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
a0079905
编写于
12月 22, 2019
作者:
H
Hsury
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
更新登录组件
上级
2518097b
变更
4
显示空白变更内容
内联
并排
Showing
4 changed file
with
5 addition
and
5 deletion
+5
-5
.travis.yml
.travis.yml
+1
-1
BiliDrive/__init__.py
BiliDrive/__init__.py
+1
-1
BiliDrive/bilibili.py
BiliDrive/bilibili.py
+2
-2
README.md
README.md
+1
-1
未找到文件。
.travis.yml
浏览文件 @
a0079905
if
:
'
tag
IS
blank'
env
:
global
:
-
TRAVIS_TAG=v1.
7
-
TRAVIS_TAG=v1.
8
jobs
:
include
:
-
...
...
BiliDrive/__init__.py
浏览文件 @
a0079905
...
...
@@ -7,4 +7,4 @@ https://github.com/Hsury/BiliDrive"""
__author__
=
"Hsury"
__email__
=
"i@hsury.com"
__license__
=
"SATA"
__version__
=
"2019.12.
16
"
__version__
=
"2019.12.
22
"
BiliDrive/bilibili.py
浏览文件 @
a0079905
...
...
@@ -14,7 +14,7 @@ class Bilibili:
def
__init__
(
self
):
self
.
_session
=
requests
.
Session
()
self
.
_session
.
headers
.
update
({
'User-Agent'
:
"Mozilla/5.0
(Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.79 Safari/537.36
"
})
self
.
_session
.
headers
.
update
({
'User-Agent'
:
"Mozilla/5.0
BiliDroid/5.51.1 (bbcallen@gmail.com)
"
})
self
.
get_cookies
=
lambda
:
self
.
_session
.
cookies
.
get_dict
(
domain
=
".bilibili.com"
)
self
.
get_uid
=
lambda
:
self
.
get_cookies
().
get
(
"DedeUserID"
,
""
)
self
.
username
=
""
...
...
@@ -82,7 +82,7 @@ class Bilibili:
while
True
:
key
=
get_key
()
key_hash
,
pub_key
=
key
[
'key_hash'
],
key
[
'pub_key'
]
url
=
f
"https://passport.bilibili.com/api/v
3
/oauth2/login"
url
=
f
"https://passport.bilibili.com/api/v
2
/oauth2/login"
param
=
f
"appkey=
{
Bilibili
.
app_key
}
&password=
{
parse
.
quote_plus
(
base64
.
b64encode
(
rsa
.
encrypt
(
f
'
{
key_hash
}{
self
.
password
}
'.encode(), pub_key)))
}
&username=
{
parse
.
quote_plus
(
self
.
username
)
}
"
payload
=
f
"
{
param
}
&sign=
{
self
.
calc_sign
(
param
)
}
"
headers
=
{
'Content-type'
:
"application/x-www-form-urlencoded"
}
...
...
README.md
浏览文件 @
a0079905
...
...
@@ -7,7 +7,7 @@
<h4
align=
"center"
>
☁️ 哔哩哔哩云,支持任意文件的全速上传与下载 ☁️
</h4>
<p
align=
"center"
>
<img
src=
"https://img.shields.io/badge/version-2019.12.
16
-green.svg?longCache=true&style=for-the-badge"
>
<img
src=
"https://img.shields.io/badge/version-2019.12.
22
-green.svg?longCache=true&style=for-the-badge"
>
<img
src=
"https://img.shields.io/badge/license-SATA-blue.svg?longCache=true&style=for-the-badge"
>
<img
src=
"https://img.shields.io/travis/com/Hsury/BiliDrive?style=for-the-badge"
>
</p>
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录