Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
季末490
dr_py
提交
cbbe21ac
dr_py
项目概览
季末490
/
dr_py
与 Fork 源项目一致
Fork自
晚风拂柳颜 / dr_py
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
dr_py
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
cbbe21ac
编写于
10月 17, 2022
作者:
H
hjdhnx
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
关闭ssl证书验证
上级
f0969be2
变更
6
隐藏空白更改
内联
并排
Showing
6 changed file
with
37 addition
and
10 deletion
+37
-10
base/rules.db
base/rules.db
+0
-0
controllers/cms.py
controllers/cms.py
+6
-6
js/version.txt
js/version.txt
+1
-1
js/快看.js
js/快看.js
+25
-0
readme.md
readme.md
+2
-0
utils/encode.py
utils/encode.py
+3
-3
未找到文件。
base/rules.db
浏览文件 @
cbbe21ac
无法预览此类型文件
controllers/cms.py
浏览文件 @
cbbe21ac
...
@@ -392,7 +392,7 @@ class CMS:
...
@@ -392,7 +392,7 @@ class CMS:
cookies_dict
=
requests
.
utils
.
dict_from_cookiejar
(
r
.
cookies
)
cookies_dict
=
requests
.
utils
.
dict_from_cookiejar
(
r
.
cookies
)
cookie_str
=
';'
.
join
([
f
'
{
k
}
=
{
cookies_dict
[
k
]
}
'
for
k
in
cookies_dict
])
cookie_str
=
';'
.
join
([
f
'
{
k
}
=
{
cookies_dict
[
k
]
}
'
for
k
in
cookies_dict
])
self
.
headers
[
'cookie'
]
=
cookie_str
self
.
headers
[
'cookie'
]
=
cookie_str
r
=
requests
.
get
(
url
,
headers
=
self
.
headers
,
timeout
=
self
.
timeout
)
r
=
requests
.
get
(
url
,
headers
=
self
.
headers
,
timeout
=
self
.
timeout
,
verify
=
False
)
r
.
encoding
=
self
.
encoding
r
.
encoding
=
self
.
encoding
html
=
r
.
text
html
=
r
.
text
if
html
.
find
(
'?btwaf='
)
<
0
:
if
html
.
find
(
'?btwaf='
)
<
0
:
...
@@ -466,7 +466,7 @@ class CMS:
...
@@ -466,7 +466,7 @@ class CMS:
pass
pass
else
:
else
:
new_classes
=
[]
new_classes
=
[]
r
=
requests
.
get
(
self
.
homeUrl
,
headers
=
self
.
headers
,
timeout
=
self
.
timeout
)
r
=
requests
.
get
(
self
.
homeUrl
,
headers
=
self
.
headers
,
timeout
=
self
.
timeout
,
verify
=
False
)
html
=
self
.
checkHtml
(
r
)
html
=
self
.
checkHtml
(
r
)
# print(html)
# print(html)
# print(self.headers)
# print(self.headers)
...
@@ -754,7 +754,7 @@ class CMS:
...
@@ -754,7 +754,7 @@ class CMS:
items
=
[]
items
=
[]
try
:
try
:
r
=
requests
.
get
(
url
,
headers
=
self
.
headers
,
timeout
=
self
.
timeout
)
r
=
requests
.
get
(
url
,
headers
=
self
.
headers
,
timeout
=
self
.
timeout
,
verify
=
False
)
html
=
self
.
checkHtml
(
r
)
html
=
self
.
checkHtml
(
r
)
print
(
self
.
headers
)
print
(
self
.
headers
)
# print(html)
# print(html)
...
@@ -831,7 +831,7 @@ class CMS:
...
@@ -831,7 +831,7 @@ class CMS:
obj
=
{}
obj
=
{}
vod_name
=
''
vod_name
=
''
if
not
html
:
# 没传递html参数接下来智能获取
if
not
html
:
# 没传递html参数接下来智能获取
r
=
requests
.
get
(
url
,
headers
=
self
.
headers
,
timeout
=
self
.
timeout
)
r
=
requests
.
get
(
url
,
headers
=
self
.
headers
,
timeout
=
self
.
timeout
,
verify
=
False
)
html
=
self
.
checkHtml
(
r
)
html
=
self
.
checkHtml
(
r
)
if
is_json
:
if
is_json
:
html
=
self
.
dealJson
(
html
)
html
=
self
.
dealJson
(
html
)
...
@@ -1136,7 +1136,7 @@ class CMS:
...
@@ -1136,7 +1136,7 @@ class CMS:
pd
=
jsp
.
pj
if
is_json
else
jsp
.
pd
pd
=
jsp
.
pj
if
is_json
else
jsp
.
pd
pq
=
jsp
.
pq
pq
=
jsp
.
pq
try
:
try
:
r
=
requests
.
get
(
url
,
headers
=
self
.
headers
,
timeout
=
self
.
timeout
)
r
=
requests
.
get
(
url
,
headers
=
self
.
headers
,
timeout
=
self
.
timeout
,
verify
=
False
)
html
=
self
.
checkHtml
(
r
)
html
=
self
.
checkHtml
(
r
)
if
is_json
:
if
is_json
:
html
=
self
.
dealJson
(
html
)
html
=
self
.
dealJson
(
html
)
...
@@ -1152,7 +1152,7 @@ class CMS:
...
@@ -1152,7 +1152,7 @@ class CMS:
}
}
self
.
saveCookie
(
cookie
)
self
.
saveCookie
(
cookie
)
self
.
headers
[
'cookie'
]
=
cookie
self
.
headers
[
'cookie'
]
=
cookie
r
=
requests
.
get
(
url
,
headers
=
self
.
headers
,
timeout
=
self
.
timeout
)
r
=
requests
.
get
(
url
,
headers
=
self
.
headers
,
timeout
=
self
.
timeout
,
verify
=
False
)
r
.
encoding
=
self
.
encoding
r
.
encoding
=
self
.
encoding
html
=
r
.
text
html
=
r
.
text
if
not
show_name
and
not
str
(
html
).
find
(
key
)
>
-
1
:
if
not
show_name
and
not
str
(
html
).
find
(
key
)
>
-
1
:
...
...
js/version.txt
浏览文件 @
cbbe21ac
3.9.8beta1
3.9.8beta2
\ No newline at end of file
\ No newline at end of file
js/快看.js
0 → 100644
浏览文件 @
cbbe21ac
var
rule
=
{
title
:
'
快看
'
,
host
:
'
https://www.kuaikanys.net
'
,
// homeUrl:'/',
url
:
'
/s/fyclass/page/fypage.html
'
,
searchUrl
:
'
/vodsearch/-------------.html?wd=**&submit=
'
,
searchable
:
2
,
//是否启用全局搜索,
quickSearch
:
1
,
//是否启用快速搜索,
filterable
:
0
,
//是否启用分类筛选,
headers
:{
//网站的请求头,完整支持所有的,常带ua和cookies
'
User-Agent
'
:
'
MOBILE_UA
'
,
// "Cookie": "searchneed=ok"
},
class_name
:
'
电影&连续剧&综艺&动漫
'
,
class_url
:
'
dianying&lianxuju&zongyi&dongman
'
,
play_parse
:
true
,
lazy
:
''
,
limit
:
6
,
推荐
:
'
.show;ul&&li;a&&title;img&&src;.score&&Text;a&&href
'
,
double
:
true
,
// 推荐内容是否双层定位
一级
:
'
.row&&li;a&&title;img&&src;.score&&Text;a&&href
'
,
二级
:{
"
title
"
:
"
h1&&Text;.info&&ul&&p&&Text
"
,
"
img
"
:
"
img&&src
"
,
"
desc
"
:
"
.info&&ul&&p:eq(-2)&&Text;.info&&ul&&p:eq(-1)&&Text;.info&&ul&&p:eq(0)&&Text;.info&&ul&&p:eq(1)&&Text;.info&&ul&&p:eq(2)&&Text;.info&&ul&&p:eq(3)&&Text
"
,
"
content
"
:
"
.text&&Text
"
,
"
tabs
"
:
"
.play&&span
"
,
"
lists
"
:
"
.playlist&&ul:eq(#id) li
"
},
搜索
:
'
.row&&li;a&&title;img&&src;.score&&Text;a&&href
'
,
}
\ No newline at end of file
readme.md
浏览文件 @
cbbe21ac
...
@@ -47,6 +47,8 @@
...
@@ -47,6 +47,8 @@
[
dockerfile教程
](
https://blog.csdn.net/qq_46158060/article/details/125718218
)
[
dockerfile教程
](
https://blog.csdn.net/qq_46158060/article/details/125718218
)
[
获取本地设备信息
](
https://blog.csdn.net/cui_yonghua/article/details/125508991
)
[
获取本地设备信息
](
https://blog.csdn.net/cui_yonghua/article/details/125508991
)
[
获取本地设备信息
](
https://m.jb51.net/article/140716.htm
)
[
获取本地设备信息
](
https://m.jb51.net/article/140716.htm
)
###### 2022/10/17
-
[X] 3.9.8beta2 全局关闭https对应的ssl证书验证
###### 2022/10/16
###### 2022/10/16
-
[X] 3.9.8 完成ddys选集播放和免嗅(可惜我刚弄完没播放俩个剧就被封ip了)
-
[X] 3.9.8 完成ddys选集播放和免嗅(可惜我刚弄完没播放俩个剧就被封ip了)
-
[X] 3.9.8beta1 增加了俩自建js解析
-
[X] 3.9.8beta1 增加了俩自建js解析
...
...
utils/encode.py
浏览文件 @
cbbe21ac
...
@@ -61,7 +61,7 @@ def requireCache(lib:str):
...
@@ -61,7 +61,7 @@ def requireCache(lib:str):
r
=
requests
.
get
(
lib
,
headers
=
{
r
=
requests
.
get
(
lib
,
headers
=
{
'Referer'
:
lib
,
'Referer'
:
lib
,
'User-Agent'
:
UC_UA
,
'User-Agent'
:
UC_UA
,
},
timeout
=
5
)
},
timeout
=
5
,
verify
=
False
)
with
open
(
lib_path
,
mode
=
'wb+'
)
as
f
:
with
open
(
lib_path
,
mode
=
'wb+'
)
as
f
:
f
.
write
(
r
.
content
)
f
.
write
(
r
.
content
)
code
=
r
.
text
code
=
r
.
text
...
@@ -86,7 +86,7 @@ class OcrApi:
...
@@ -86,7 +86,7 @@ class OcrApi:
def
classification
(
self
,
img
):
def
classification
(
self
,
img
):
try
:
try
:
code
=
requests
.
post
(
self
.
api
,
data
=
img
,
headers
=
{
'user-agent'
:
PC_UA
}).
text
code
=
requests
.
post
(
self
.
api
,
data
=
img
,
headers
=
{
'user-agent'
:
PC_UA
}
,
verify
=
False
).
text
except
Exception
as
e
:
except
Exception
as
e
:
print
(
f
'ocr识别发生错误:
{
e
}
'
)
print
(
f
'ocr识别发生错误:
{
e
}
'
)
code
=
''
code
=
''
...
@@ -106,7 +106,7 @@ def verifyCode(url,headers,timeout=5,total_cnt=3,api=None):
...
@@ -106,7 +106,7 @@ def verifyCode(url,headers,timeout=5,total_cnt=3,api=None):
while
cnt
<
total_cnt
:
while
cnt
<
total_cnt
:
s
=
requests
.
session
()
s
=
requests
.
session
()
try
:
try
:
img
=
s
.
get
(
url
=
f
"
{
host
}
/index.php/verify/index.html"
,
headers
=
headers
,
timeout
=
timeout
).
content
img
=
s
.
get
(
url
=
f
"
{
host
}
/index.php/verify/index.html"
,
headers
=
headers
,
timeout
=
timeout
,
verify
=
False
).
content
code
=
ocr
.
classification
(
img
)
code
=
ocr
.
classification
(
img
)
print
(
f
'第
{
cnt
+
1
}
次验证码识别结果:
{
code
}
'
)
print
(
f
'第
{
cnt
+
1
}
次验证码识别结果:
{
code
}
'
)
res
=
s
.
post
(
res
=
s
.
post
(
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录