Skip to content

Commit

Permalink
feat(modules): sgmodule arguments
Browse files Browse the repository at this point in the history
Update DualSubs.Netflix.beta.sgmodule
Update DualSubs.Netflix.sgmodule
  • Loading branch information
VirgilClyne committed Mar 9, 2024
1 parent 931cc41 commit d5b58fe
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 4 deletions.
6 changes: 3 additions & 3 deletions modules/DualSubs.Netflix.beta.sgmodule
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
#!manual=https://github.com/DualSubs/Netflix/wiki/🍿-DualSubs:-🇳-Netflix
#!icon=https://github.com/DualSubs/Netflix/raw/main/database/icon_rounded.png
#!category=🍿️ DualSubs
#!arguments=SourceLanguage:AUTO,TargetLanguage:ZH,ShowOnly:false
#!arguments-desc=SourceLanguage: 主字幕语言(源语言)\nTargetLanguage: 副字幕语言(目标语言)\nShowOnly: 只显示翻译后字幕
#!arguments=Switch:true,Languages[0]:AUTO,Languages[1]:ZH,ShowOnly:false
#!arguments-desc=Switch: 功能开关\n └ 是否启用此平台修改功能\nLanguages[0]: 主字幕语言(源语言)\n └ 当“主语言”字幕存在时,将生成“主语言/副语言(翻译)”与“主语言(外挂)”的字幕或字幕选项\nLanguages[1]: 副字幕语言(目标语言)\n └ 当“副语言”字幕存在时,将生成“副语言/主语言(官方)”的字幕或字幕选项\nShowOnly: 只显示翻译后字幕

[Rule]
URL-REGEX,^https?:\/\/(ios|tvos|win10)(-anycast)?\.prod\.(ftl|http1|cloud)\.netflix\.com\/msl\/playapi\/(ios|cadmium)\/(manifest|logblob|event)$,REJECT-DROP

[Script]
DualSubs.Netflix.Manifest.response.json = type=http-response, pattern=^https?:\/\/(ios|tvos|win10)\.prod\.(ftl|http1|cloud)\.netflix\.com\/playapi\/(ios|cadmium)\/manifest$, requires-body=1, debug=1, script-path=https://raw.githubusercontent.com/DualSubs/Netflix/beta/js/DualSubs.Netflix.Manifest.response.beta.js
DualSubs.Netflix.Translate.Subtitles.response = type=http-response, pattern=^https?:\/\/(.+)\.oca\.nflxvideo\.net\/\?o=\d+&v=\d+&e=\d+&t=.+, requires-body=1, debug=1, script-path=https://raw.githubusercontent.com/DualSubs/Universal/beta/js/Translate.response.beta.js, argument=Languages="{{{SourceLanguage}}},{{{TargetLanguage}}}"&ShowOnly={{{ShowOnly}}}
DualSubs.Netflix.Translate.Subtitles.response = type=http-response, pattern=^https?:\/\/(.+)\.oca\.nflxvideo\.net\/\?o=\d+&v=\d+&e=\d+&t=.+, requires-body=1, debug=1, script-path=https://raw.githubusercontent.com/DualSubs/Universal/beta/js/Translate.response.beta.js, argument=Switch={{{Switch}}}&Languages[0]={{{Languages[0]}}}&Languages[1]={{{Languages[1]}}}&ShowOnly={{{ShowOnly}}}

[MITM]
hostname = %APPEND% anycast.ftl.netflix.com, oca-api.netflix.com, *.prod.cloud.netflix.com, *.prod.ftl.netflix.com, *.prod.http1.netflix.com, *.oca.nflxvideo.net
Expand Down
4 changes: 3 additions & 1 deletion modules/DualSubs.Netflix.sgmodule
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,11 @@
#!manual=https://github.com/DualSubs/Netflix/wiki/🍿-DualSubs:-🇳-Netflix
#!icon=https://github.com/DualSubs/Netflix/raw/main/database/icon_rounded.png
#!category=🍿️ DualSubs
#!arguments=Switch:true,Languages[0]:AUTO,Languages[1]:ZH,ShowOnly:false
#!arguments-desc=Switch: 功能开关\n └ 是否启用此平台修改功能\nLanguages[0]: 主字幕语言(源语言)\n └ 当“主语言”字幕存在时,将生成“主语言/副语言(翻译)”与“主语言(外挂)”的字幕或字幕选项\nLanguages[1]: 副字幕语言(目标语言)\n └ 当“副语言”字幕存在时,将生成“副语言/主语言(官方)”的字幕或字幕选项\nShowOnly: 只显示翻译后字幕

[Script]
DualSubs.Netflix.Translate.Subtitles.response = type=http-response, pattern=^https?:\/\/(.+)\.oca\.nflxvideo\.net\/\?o=\d+&v=\d+&e=\d+&t=.+, requires-body=1, script-path=https://raw.githubusercontent.com/DualSubs/Universal/main/js/Translate.response.js
DualSubs.Netflix.Translate.Subtitles.response = type=http-response, pattern=^https?:\/\/(.+)\.oca\.nflxvideo\.net\/\?o=\d+&v=\d+&e=\d+&t=.+, requires-body=1, script-path=https://raw.githubusercontent.com/DualSubs/Universal/main/js/Translate.response.js, argument=Switch={{{Switch}}}&Languages[0]={{{Languages[0]}}}&Languages[1]={{{Languages[1]}}}&ShowOnly={{{ShowOnly}}}

[MITM]
hostname = %APPEND% *.oca.nflxvideo.net
Expand Down
15 changes: 15 additions & 0 deletions modules/DualSubs.Netflix.srmodule
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#!name=🍿️ DualSubs: 🇳 Netflix
#!desc=Netflix字幕增强及双语模块
#!openUrl=http://boxjs.com/#/app/DualSubs.Netflix
#!author=VirgilClyne
#!homepage=https://github.com/DualSubs
#!manual=https://github.com/DualSubs/Netflix/wiki/🍿-DualSubs:-🇳-Netflix
#!icon=https://github.com/DualSubs/Netflix/raw/main/database/icon_rounded.png
#!category=🍿️ DualSubs

[Script]
DualSubs.Netflix.Translate.Subtitles.response = type=http-response, pattern=^https?:\/\/(.+)\.oca\.nflxvideo\.net\/\?o=\d+&v=\d+&e=\d+&t=.+, requires-body=1, script-path=https://raw.githubusercontent.com/DualSubs/Universal/main/js/Translate.response.js

[MITM]
hostname = %APPEND% *.oca.nflxvideo.net
tcp-connection = true

0 comments on commit d5b58fe

Please sign in to comment.