acp-ts 1.1.3 → 1.1.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -163,7 +163,14 @@ class CertAndKeyStore {
163
163
  return [];
164
164
  }
165
165
  const entries = fs.readdirSync(aidsDir, { withFileTypes: true });
166
- return entries.filter(e => e.isDirectory()).map(e => e.name);
166
+ return entries.filter(e => {
167
+ if (!e.isDirectory())
168
+ return false;
169
+ const aidName = e.name;
170
+ const keyPath = path.join(aidsDir, aidName, 'private', `${aidName}.key`);
171
+ const crtPath = path.join(aidsDir, aidName, 'public', `${aidName}.crt`);
172
+ return fs.existsSync(keyPath) && fs.existsSync(crtPath);
173
+ }).map(e => e.name);
167
174
  }
168
175
  catch (e) {
169
176
  console.error('扫描 AIDs 目录失败:', e);
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "acp-ts",
3
- "version": "1.1.3",
4
- "description": "基于 WebSocket 的智能体通信库,提供智能体身份管理和实时通信功能",
3
+ "version": "1.1.4",
4
+ "description": "基于 ACP智能体通信协议 的智能体通信库,提供智能体身份管理和实时通信功能",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
7
7
  "bin": {