fix: 默认启用NapCat反检测配置
This commit is contained in:
parent
e356784836
commit
8d96e3dc48
@ -29,12 +29,12 @@ type OnebotConfig = {
|
||||
|
||||
type NapcatConfig = {
|
||||
bypass: {
|
||||
container: false;
|
||||
hook: false;
|
||||
js: false;
|
||||
module: false;
|
||||
process: false;
|
||||
window: false;
|
||||
container: true;
|
||||
hook: true;
|
||||
js: true;
|
||||
module: true;
|
||||
process: true;
|
||||
window: true;
|
||||
};
|
||||
o3HookMode: 0;
|
||||
packetBackend: 'auto';
|
||||
@ -68,12 +68,12 @@ export class NapcatConfigWriterService {
|
||||
};
|
||||
const napcatConfig: NapcatConfig = {
|
||||
bypass: {
|
||||
container: false,
|
||||
hook: false,
|
||||
js: false,
|
||||
module: false,
|
||||
process: false,
|
||||
window: false,
|
||||
container: true,
|
||||
hook: true,
|
||||
js: true,
|
||||
module: true,
|
||||
process: true,
|
||||
window: true,
|
||||
},
|
||||
o3HookMode: 0,
|
||||
packetBackend: 'auto',
|
||||
|
||||
@ -253,6 +253,14 @@ describe('NapCat runtime profile generation', () => {
|
||||
reconnectInterval: 5000,
|
||||
reportSelfMessage: false,
|
||||
});
|
||||
expect(result.napcatConfig.bypass).toEqual({
|
||||
container: true,
|
||||
hook: true,
|
||||
js: true,
|
||||
module: true,
|
||||
process: true,
|
||||
window: true,
|
||||
});
|
||||
expect(result.napcatConfig.o3HookMode).toBe(0);
|
||||
expect(
|
||||
result.files.find((file) => file.path === 'webui.json')?.content,
|
||||
|
||||
Loading…
Reference in New Issue
Block a user