Skip to content

Commit 1bde2a0

Browse files
author
freedom-introvert
committed
250409
1 parent f8c6a33 commit 1bde2a0

14 files changed

Lines changed: 133 additions & 88 deletions

File tree

IMG_20230326_210311.jpg

-572 KB
Binary file not shown.

IMG_20230326_210709.jpg

-364 KB
Binary file not shown.

README.md

Lines changed: 6 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818

1919
自动获取哔哩哔哩客户端的cookie,检查时自动添加对应的账号到用户列表,无需手动添加账号。
2020

21-
**cookie来源于webview中的cookies数据库**,若该cookie无法使用可关闭该功能。
21+
cookie来源于webview中的cookies数据库,**若该cookie无法使用请关闭该功能**
2222

2323
如果一定要使用自动获取cookie,但是cookie无效,可以尝试打开b站APP内依赖webview的地方,例如“客服”
2424

@@ -42,21 +42,21 @@
4242

4343
## 随机评论列表
4444

45-
默认三首诗,建议自行修改以避免被针对。不建议设置“测试”、“加油UP”,有时候戒严评论区都能直接过
45+
默认三首诗,建议自行修改以避免被针对。不建议设置“测试”、“加油UP”等你认为的白名单词语,有时候戒严评论区都能直接过
4646

4747
### 随机生成测试评论
4848

4949
随机生成中文字符串,这些评论读起来几乎没有任何意义,因此能避免类似“加油UP”这样的白名单评论。
5050

51-
当然,因为它是随机的,就会有概率抽到敏感词,所以,生成了就发送到正常评论区来试,正常显示才保存使用。为啥做此功能?因为我发现列如“测试”这样的词语在某些戒严的评论区发送后可正常显示,造成检查结果不准确。鼓励UP主的更别说了,那几首诗特征也有点明显了。
51+
当然,因为它是随机的,就会有概率抽到敏感词,所以,软件生成后就自动发送到正常评论区来试,正常显示才保存使用。为啥做此功能?因为我发现列如“测试”这样的词语在某些戒严的评论区发送后可正常显示,造成检查结果不准确,鼓励UP主的更别说了。那几首诗特征也有点明显了,到手马上改!(想让叔叔阿姨·知道你在用反诈吗?😁)
5252

5353
## 被转发动态
5454

5555
敏感词扫描所使用,因为转发动态不用审核,可以快速获得一个干净评论区进行敏感词的扫描。强烈建议设置各种UP的抽奖动态。具体参见敏感词扫描
5656

5757
# 使用方法
5858

59-
### 手动发送检查
59+
### 首页的手动发送检查
6060

6161
先输入BV号、cv号或者链接,支持bilibili\.com 标准链接和 b23\.tv 短链接。支持视频、专栏、动态类型的评论区。
6262

@@ -66,9 +66,7 @@
6666

6767
### Xposed劫持APP评论发送
6868

69-
在Xposed模块里启用并勾选哔哩哔哩,在哔哩哔哩APP里评论发送成功后,会调起本发评反诈进行检查,方便快捷!支持对评论回复的检查!
70-
(图中评论区为戒严评论区)
71-
![](Screenshot_2024-03-10-00-33-33-106_icu.freedomIntrovert.biliSendCommAntifraud.jpg)
69+
在Xposed模块里启用并勾选哔哩哔哩,在哔哩哔哩APP里评论发送成功后,会调起本发评反诈进行检查,方便快捷!支持对评论回复的检查! ![](Screenshot_2024-03-10-00-33-33-106_icu.freedomIntrovert.biliSendCommAntifraud.jpg)
7270

7371
### 测试用例,若发现失效(指不被ShadowBan或删)请发issues
7472

@@ -205,7 +203,7 @@ graph TB
205203

206204
- 红色:评论仅在此评论区被ban
207205

208-
### 被ban评论列表
206+
### 被ban评论列表
209207

210208
5.0.0版本及之前存在被ban评论列表与历史评论列表,由于功能相似且存在同步问题,以及数据库统计不全(缺少评论parent、root等信息),被ban评论列表已被移除,此列表的评论将在版本更新后合并至历史评论列表。
211209

@@ -282,10 +280,6 @@ graph TB
282280
250--找到了--> 280[评论被shadowBan]
283281
```
284282

285-
## 统计戒严评论区
286-
287-
![IMG_20230326_210311](IMG_20230326_210311.jpg)
288-
289283
## 定位评论
290284

291285
> 哔哩哔哩APP在私信、评论点赞的消息,点击可直接去评论区定位到目标评论。

biliSendCommAntifraud/.idea/.name

Lines changed: 0 additions & 1 deletion
This file was deleted.

biliSendCommAntifraud/.idea/gradle.xml

Lines changed: 0 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

biliSendCommAntifraud/.idea/inspectionProfiles/Project_Default.xml

Lines changed: 0 additions & 13 deletions
This file was deleted.

biliSendCommAntifraud/.idea/misc.xml

Lines changed: 9 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

biliSendCommAntifraud/app/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ def currentTimeMillis = System.currentTimeMillis();
66

77
android {
88
namespace 'icu.freedomIntrovert.biliSendCommAntifraud'
9-
compileSdk 33
9+
compileSdk 35
1010
lint {
1111
baseline = file("lint-baseline.xml")
1212
}

biliSendCommAntifraud/app/src/main/AndroidManifest.xml

Lines changed: 16 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,12 @@
55
<uses-permission android:name="android.permission.INTERNET" />
66
<uses-permission android:name="android.permission.POST_NOTIFICATIONS" />
77
<uses-permission android:name="android.permission.FOREGROUND_SERVICE" />
8+
9+
<uses-permission android:name="android.permission.FOREGROUND_SERVICE_DATA_SYNC"
10+
android:minSdkVersion="34"/>
11+
812
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
13+
<uses-permission android:name="android.permission.WAKE_LOCK" />
914

1015
<application
1116
android:allowBackup="true"
@@ -14,17 +19,17 @@
1419
android:networkSecurityConfig="@xml/network_security_config"
1520
android:supportsRtl="true"
1621
android:theme="@style/Theme.BiliSendCommAntifraud.HasActionBar"
17-
tools:targetApi="33">
18-
22+
android:windowTranslucentStatus="false"
23+
tools:targetApi="35">
24+
1925
<activity
2026
android:name=".PendingCheckCommentsActivity"
2127
android:exported="false"
2228
android:label="待检查评论列表" />
2329

2430
<service
2531
android:name=".WaitService"
26-
android:enabled="true"
27-
android:exported="true" />
32+
android:foregroundServiceType="dataSync" />
2833

2934
<activity
3035
android:name=".HistoryCommentActivity"
@@ -41,7 +46,7 @@
4146
android:value="true" />
4247
<meta-data
4348
android:name="xposedsharedprefs"
44-
android:value="true"/>
49+
android:value="true" />
4550
<meta-data
4651
android:name="xposeddescription"
4752
android:value="发送评论自动检测,解放双手&amp;你的评论记录器" />
@@ -54,11 +59,11 @@
5459

5560
<activity
5661
android:name=".ByXposedLaunchedActivity"
57-
android:exported="true"
58-
android:theme="@style/dialog_activity"
5962
android:clearTaskOnLaunch="true"
63+
android:excludeFromRecents="true"
64+
android:exported="true"
6065
android:noHistory="true"
61-
android:excludeFromRecents="true">
66+
android:theme="@style/dialog_activity">
6267

6368
<meta-data
6469
android:name="android.app.lib_name"
@@ -99,9 +104,9 @@
99104

100105
<service
101106
android:name=".CommentMonitoringService"
102-
android:enabled="true"
103-
android:exported="true" />
104-
<receiver android:name=".CancelMonitorReceiver"/>
107+
android:foregroundServiceType="dataSync"/>
108+
109+
<receiver android:name=".CancelMonitorReceiver" />
105110
</application>
106111

107112
</manifest>

biliSendCommAntifraud/app/src/main/java/icu/freedomIntrovert/biliSendCommAntifraud/CommentLocator.java

Lines changed: 40 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,65 @@
11
package icu.freedomIntrovert.biliSendCommAntifraud;
22

33
import android.app.AlertDialog;
4+
import android.content.ActivityNotFoundException;
45
import android.content.Context;
56
import android.content.Intent;
7+
import android.net.Uri;
68
import android.os.Bundle;
9+
import android.widget.Toast;
710

811
import java.util.concurrent.atomic.AtomicInteger;
912

1013
import icu.freedomIntrovert.biliSendCommAntifraud.comment.bean.CommentArea;
1114

1215
public class CommentLocator {
13-
public static void lunch(Context context,int areaType,long oid,long rpid,long root,String sourceId) {
16+
public static void lunch(Context context, int areaType, long oid, long rpid, long root, String sourceId) {
1417
AtomicInteger selected = new AtomicInteger(0);
1518
new AlertDialog.Builder(context)
16-
.setTitle("选择b站版本(需要挂载XP/LSP)")
17-
.setSingleChoiceItems(new String[]{"国内版" ,"国际版"}, 0, (dialog, which) -> selected.set(which))
18-
.setNegativeButton(R.string.cancel,null)
19+
.setTitle("选择打开方式")
20+
.setSingleChoiceItems(new String[]{"URL Scheme", "国内版(需要挂载XP/LSP)", "国际版(需要挂载XP/LSP)"}, 0, (dialog, which) -> selected.set(which))
21+
.setNegativeButton(R.string.cancel, null)
1922
.setPositiveButton(R.string.ok, (dialog, which) -> {
20-
if (selected.get() == 0){
23+
if (selected.get() == 0) {
24+
lunchByUrlScheme(context, areaType, oid, rpid, root, sourceId);
25+
} else if (selected.get() == 1) {
2126
lunchMaster(context, areaType, oid, rpid, root, sourceId);
22-
} else {
27+
} else if (selected.get() == 2){
2328
lunchGlobal(context, areaType, oid, rpid, root, sourceId);
2429
}
2530
})
2631
.show();
2732

2833
}
2934

30-
public static void lunchMaster(Context context,int areaType,long oid,long rpid,long root,String sourceId){
35+
public static void lunchByUrlScheme(Context context, int areaType, long oid, long rpid, long root, String sourceId) {
36+
String urlScheme;
37+
38+
if (areaType == CommentArea.AREA_TYPE_VIDEO) {
39+
if (root != 0) {
40+
urlScheme = String.format("bilibili://video/%s/?comment_root_id=%s&comment_secondary_id=%s", oid, root, rpid);
41+
} else {
42+
urlScheme = String.format("bilibili://video/%s/?comment_root_id=%s", oid, rpid);
43+
}
44+
} else {
45+
if (root != 0) {
46+
urlScheme = String.format("bilibili://comment/detail/%s/%s/%s?anchor=%s", areaType, oid, root, rpid);
47+
} else {
48+
urlScheme = String.format("bilibili://comment/detail/%s/%s/%s", areaType, oid, rpid);
49+
}
50+
}
51+
52+
Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse(urlScheme));
53+
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
54+
try {
55+
context.startActivity(intent);
56+
} catch (ActivityNotFoundException e) {
57+
Toast.makeText(context, "无法打开B站App,请确认是否已安装", Toast.LENGTH_SHORT).show();
58+
}
59+
}
60+
61+
62+
public static void lunchMaster(Context context, int areaType, long oid, long rpid, long root, String sourceId) {
3163
Intent intent = new Intent();
3264
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_DOCUMENT);
3365
Bundle extras = new Bundle();
@@ -81,7 +113,7 @@ public static void lunchMaster(Context context,int areaType,long oid,long rpid,l
81113
context.startActivity(intent);
82114
}
83115

84-
public static void lunchGlobal(Context context,int areaType,long oid,long rpid,long root,String sourceId){
116+
public static void lunchGlobal(Context context, int areaType, long oid, long rpid, long root, String sourceId) {
85117
Intent intent = new Intent();
86118
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_DOCUMENT);
87119
Bundle extras = new Bundle();

0 commit comments

Comments
 (0)