Repository navigation
v1.5.1
🚀 新增功能
- 26 维统一级联删除引擎、派生表重建与 7 大 KeepAlive 视图联动:新增
asset_cascade_service.py,实现基于显式绑定隔离的资产组、目标范围、任务、持续监控及 26 个资产维度删除接口统一级联清理(单次上限 500 条),支持 L1/L2/L3 依赖边界、孤儿 IP 回收与 CIDR 保护、端点级服务剥离及dict/str大小写不敏感指纹剥离;基于存活宿主表重建cip/asset_cip、stat_finger/asset_stat_finger与service/asset_service,并通过system_config版本号触发跨进程缓存失效;新增POST /api/stat_finger/delete/、/api/asset_overview/count可选scope_id并发 13 集合计数及POST /api/task/delete/的del_synced_asset开关;前端覆盖资产组详情、任务详情、资产搜索、资产组列表、任务列表、计划与监控任务及大盘共 7 大 KeepAlive 视图,通过assetMutationVersion、deletedScopeIdSet、跨页对象清单确认(默认展开前 20 项)与越界分页自动回退保持视图状态一致。 - Nmap 与 Python 插件服务融合为统一单端点视图:新增
service_fusion.py,在任务扫描、站点反哺、Python 插件识别与资产组派生重建链路按(ip, port_id)归一合流,优先采用协议握手结果校准unknown等弱服务名并保留product、version与多来源标签(sources);/api/service/全局模式按(ip, port_id)跨任务去重并与/api/asset_overview/count计数口径一致,新增/api/service/export/与/api/asset_service/export/;资产搜索、资产组详情、任务详情与ChainDrawer.vue统一为 12 个资产维度与单端点服务表,移除二级引擎切换栏及废弃组件ServiceDetailModal.vue。 - 统一调度中心单表胶囊视图与计划任务立即执行:重构
PlanningTasks.vue将计划任务与资产持续监控融合为统一表格,通过语义胶囊区分 6 类调度类型,对齐任务列表三段式头部(顶栏大类胶囊、4 维可点击状态指标卡、检索栏与浮动批量操作条);新增POST /api/task_schedule/run/支持任意状态手动立即派发(先派发成功后再原子递增run_number),GET /api/scheduler/补充scope_name关联字段,批量停止与恢复按状态预过滤并展示跳过数量。 - 12 维度资产发现时间与更新时间统一展示、筛选及排序:统一 26 张资产集合(13 张任务表 + 13 张资产组表)的
save_date与update_date为本地时区 BSONdatetime,全量 26 路由开放save_date区间过滤与排序(资产组接口同步支持update_date),统一带时区 ISO 8601 边界归一与全局聚合表(service、cip、stat_finger)按最早发现/最新更新时间筛选导出的一致口径;新增AssetTimeCell.vue与单日全天区间归一,覆盖资产搜索、资产组详情、任务详情与资产画像抽屉的 12 个维度。
🛠️ 性能与重构
- MongoDB 连接池治理、索引精简与幂等增量迁移加固:规范
MongoClient连接池默认参数,移除cip数组多键索引及冲突/冗余索引,全局聚合查询统一启用allowDiskUse=True;在arlupdate.py中新增基于system_config原子哨兵的三项一次性幂等迁移——统一服务表两阶段安全展开迁移(先 upsert 后清理旧分组文档、保留由_id推导的save_date,迁移未完成时跳过唯一索引创建)、存量级联与派生表自愈迁移、以及 26 张资产集合发现时间戳分批回填,并将启动期延迟后台迁移收敛为单串行线程以避开 Gunicorn 预加载分叉窗口。 - 下线失效
port_top_10配置并收敛默认端口类型:移除未被扫描链路读取的port_top_10前端设置、配置接口字段、Config.TOP_10与孤立函数/多语言键,port_scan兜底切换为 Top100 字典;内部默认port_scan_type由test收敛为top100并保留test别名向下兼容。 - 双语文档重构与界面截图刷新:以使用流程视角重构中英文
README,同步刷新仪表盘、任务创建、系统设置、威胁情报雷达与 MCP 治理中心界面截图并修复tools/make_social_preview.py预览卡片裁切;同步更新中英双语docs/API_GUIDE*.md与mcp-server/README*.md。
🐛 问题修复与加固
- 任务参数摘要过滤与目标域名来源修正:后端任务启动日志(
celerytask.py)与前端配置详情(TaskList.vue)按父开关过滤未启用阶段(domain_brute/alt_dns/port_scan/file_leak等)的附属字典与端口参数;未启用domain_brute时目标域名入库来源由domain_brute更正为target(CollectSource.TARGET)。 - 资产组删改联动、在途任务撤销与存活栅栏:资产组删除时同步终止运行中的企业测绘更新任务(
updating_icp_task_id)并解绑引用(保留原始测绘数据);资产组改名同步更新关联监控与任务显示名;监控停止与批停同步撤销在途扫描任务并重置next_run_date;在SyncAsset与监控链路提交前增加资产组/目标存活校验;加固 C 段删除畸形 IP 容错与npoc_service删除后统一服务表重算。 - 前端资产详情、搜索与调度页回归修复:修复
AssetSearch.vue批量删除缺失的 i18n 键;修复GroupAssetsDetail.vue总资产重复计入npoc_service、筛选请求覆盖总量徽标、WIHsource列与域名来源冲突、新增站点/域名后计数与变更通知未刷新及跨页勾选清理不完整;修复PlanningTasks.vue胶囊切换未清选、批量操作异常吞错与失败误清空勾选、行按钮术语统一为「停止」及 KeepAlive 返回刷新策略列表;同步修复多套历史单测夹具并补充前后端回归测试。
🛡️ 安全与配置
- 风险巡航勾选站点接口 Fail-Closed 加固:新增
POST /api/site/save_result_set/与POST /api/asset_site/save_result_set/接收 JSON_id列表,严格校验非空、ObjectId 合法性与单次 500 条上限,异常返回业务code: 400,规避空条件退化为大范围扫描;前端资产搜索、任务详情与资产组详情勾选巡航切换为 POST 提交并在非 200 响应时阻断打开弹窗。 - 外链安全属性、MCP E2E 凭据隔离与文档事实校准:
GroupAssetsDetail.vueWIH 来源链接增加isHttpUrl校验与rel="noopener noreferrer";tools/verify_mcp_e2e.py向 Stdio 子进程显式注入测试密钥以规避本地管理员凭据覆盖;校准中英文API_GUIDE与mcp-server/README中的自签名证书ARL_CA_BUNDLE配置说明、Nuclei 协议阻断边界及 RFC 5737 占位示例地址,并保持双副本mcp-server/server.py与frontend/public/mcp/server.py一致。
🚀 New Features
- Unified 26-dimension cascade deletion engine, derived rebuilds, and 7 KeepAlive view synchronization: added
asset_cascade_service.pyto unify cascade cleanup across asset groups, seed targets, tasks, continuous monitors, and all 26 asset dimension delete endpoints (500-item batch limit) with explicit-binding isolation, L1/L2/L3 dependency rules, orphan IP reclamation with CIDR protection, endpoint-level service stripping, and case-insensitivedict/strfingerprint removal; rebuiltcip/asset_cip,stat_finger/asset_stat_finger, andservice/asset_servicefrom surviving host tables with cross-process cache invalidation viasystem_configversion counters; addedPOST /api/stat_finger/delete/, optionalscope_idconcurrent 13-collection counting on/api/asset_overview/count, anddel_synced_assetonPOST /api/task/delete/; synchronized 7 KeepAlive views (Asset Group Details, Task Details, Asset Search, Asset Groups, Task List, Planning & Monitoring, and Dashboard) viaassetMutationVersion,deletedScopeIdSet, cross-page selection confirmation lists (first 20 items expandable), and empty-page clamping. - Unified per-endpoint service view fusing Nmap and Python plugin services: added
service_fusion.pyto merge Nmap port scan results, site feedback, Python plugin detections, and scope derived rebuilds per(ip, port_id)endpoint, calibrating weak labels such asunknownwith protocol handshake results while preservingproduct,version, and multi-source tags (sources); deduplicated global/api/service/queries across tasks by(ip, port_id)in parity with/api/asset_overview/countand added/api/service/export/and/api/asset_service/export/; aligned Asset Search, Asset Group Details, Task Details, andChainDrawer.vueon 12 asset dimensions and a single per-endpoint service table, removing secondary engine toggles and the retiredServiceDetailModal.vue. - Unified single-table schedule center and immediate scheduled task dispatch: refactored
PlanningTasks.vueto merge scheduled scans and continuous asset monitors into one table with semantic capsule tags for 6 schedule subtypes and a 3-tier header matching TaskList (top category capsules, 4 clickable status metric cards, filter bar, and floating batch bar); addedPOST /api/task_schedule/run/supporting manual immediate dispatch from any schedule status (atomically incrementingrun_numberonly after dispatch succeeds), enrichedGET /api/scheduler/withscope_name, and pre-filtered eligible rows for batch stop/resume with skipped-count notices. - Unified discovery and update timestamps across 12 dimensions: standardized
save_dateandupdate_dateacross all 26 asset collections (13 task + 13 asset-group collections) as local-timezone BSONdatetime, exposingsave_daterange filtering and sorting on all 26 routes (plusupdate_dateon asset-group routes), timezone-aware ISO 8601 boundary normalization, and consistent post-grouping min/max time filtering and export parity across global aggregated views (service,cip,stat_finger); addedAssetTimeCell.vueand full-day single-date range normalization across Asset Search, Asset Group Details, Task Details, and the asset profile drawer.
🛠️ Performance & Refactoring
- MongoDB connection pool tuning, lean indexing, and idempotent migration hardening: standardized
MongoClientpool defaults, removedciparray multikey indexes and conflicting/redundant indexes, and enabledallowDiskUse=Trueacross global aggregation pipelines; added threesystem_configsentinel-guarded one-time idempotent migrations inarlupdate.py—two-phase unified service expansion (upserting before removing legacy grouped documents, preserving_id-derivedsave_date, and skipping unique index creation if migration does not complete), cascade/derived self-healing, and batched discovery-timestamp backfilling—while serializing deferred startup migrations on a single delayed thread to avoid Gunicorn preload fork races. - Retirement of unused
port_top_10setting and default port type convergence: removed the unreadport_top_10setting across the UI, config API,Config.TOP_10, and orphaned helpers/i18n keys, switching theport_scanfallback to the Top100 dictionary; converged internal defaultport_scan_typefromtesttotop100while retaining thetestalias for backward compatibility. - Bilingual documentation overhaul and UI screenshot refresh: rewrote Chinese and English
READMEfiles around user workflows, refreshed Dashboard, Task Creation, System Settings, Threat Intel Radar, and MCP Center screenshots, fixed preview card cropping intools/make_social_preview.py, and updated bilingualdocs/API_GUIDE*.mdandmcp-server/README*.md.
🐛 Bug Fixes & Hardening
- Task option summary filtering and root domain source attribution: added parent-switch filtering in backend startup logging (
celerytask.py) and frontend option details (TaskList.vue) so dependent dictionary/port parameters for disabled stages (domain_brute,alt_dns,port_scan,file_leak) are hidden; corrected root domain source attribution fromdomain_brutetotarget(CollectSource.TARGET) whendomain_bruteis disabled. - Asset group lifecycle closure, in-flight task revocation, and survival guards: stopped active enterprise recon updates (
updating_icp_task_id) and cleared scope bindings upon asset group deletion while preserving raw recon records; propagated scope renames to linked monitors and tasks; revoked in-flight monitor tasks and resetnext_run_dateon single/batch stop; added pre-commit scope/target survival checks inSyncAssetand monitor pipelines; guarded malformed IP strings during CIDR cascade delete and rebuilt unifiedservicecollections cleanly onnpoc_servicedeletion. - Frontend asset views, search, and schedule center regression fixes: replaced missing batch-delete i18n keys in
AssetSearch.vue; fixedGroupAssetsDetail.vuedouble-countingnpoc_servicein totals, filtered fetches overwriting tab badge counts, WIHsourcecolumn colliding with domain sources, missing count/mutation refreshes after adding sites or domains, and incomplete selection clearing; fixedPlanningTasks.vuecategory-switch selection clearing, error swallowing and failed-selection clearing during batch actions, row stop button wording unification, and policy list refresh on KeepAlive reactivation; synchronized legacy unit test fixtures and added pre-release regression suites.
🛡️ Security & Configuration
- Fail-closed POST endpoints for selected-row risk cruising: added
POST /api/site/save_result_set/andPOST /api/asset_site/save_result_set/accepting JSON_idarrays with strict non-empty, ObjectId validity, and 500-item limit checks (returning businesscode: 400on invalid input to prevent fallback broad scans); updatedAssetSearch.vue,TaskDetail.vue, andGroupAssetsDetail.vueto submit selected rows via POST and abort opening the modal on non-200 responses. - External link hardening, MCP E2E credential isolation, and factual doc alignment: added
isHttpUrlvalidation andrel="noopener noreferrer"to WIH source links inGroupAssetsDetail.vue; explicitly injected ephemeral test keys into the Stdio subprocess intools/verify_mcp_e2e.pyto avoid local admin credential shadowing; aligned bilingualAPI_GUIDEandmcp-server/READMEdocs on self-signedARL_CA_BUNDLEconfiguration, Nuclei protocol block boundaries, and RFC 5737 placeholder examples, keeping dual copiesmcp-server/server.pyandfrontend/public/mcp/server.pyidentical.
Full Changelog: v1.5.0...v1.5.1