bluelamp 2.0.9 → 3.0.0
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.
- package/README.md +12 -25
- package/bin/bluelamp +368 -0
- package/bin/bluelamp-base +368 -0
- package/bin/bluelamp10 +368 -0
- package/bin/bluelamp100 +368 -0
- package/bin/bluelamp11 +368 -0
- package/bin/bluelamp12 +368 -0
- package/bin/bluelamp13 +368 -0
- package/bin/bluelamp14 +368 -0
- package/bin/bluelamp15 +368 -0
- package/bin/bluelamp16 +368 -0
- package/bin/bluelamp17 +368 -0
- package/bin/bluelamp18 +368 -0
- package/bin/bluelamp19 +368 -0
- package/bin/bluelamp2 +368 -0
- package/bin/bluelamp20 +368 -0
- package/bin/bluelamp21 +368 -0
- package/bin/bluelamp22 +368 -0
- package/bin/bluelamp23 +368 -0
- package/bin/bluelamp24 +368 -0
- package/bin/bluelamp25 +368 -0
- package/bin/bluelamp26 +368 -0
- package/bin/bluelamp27 +368 -0
- package/bin/bluelamp28 +368 -0
- package/bin/bluelamp29 +368 -0
- package/bin/bluelamp3 +368 -0
- package/bin/bluelamp30 +368 -0
- package/bin/bluelamp31 +368 -0
- package/bin/bluelamp32 +368 -0
- package/bin/bluelamp33 +368 -0
- package/bin/bluelamp34 +368 -0
- package/bin/bluelamp35 +368 -0
- package/bin/bluelamp36 +368 -0
- package/bin/bluelamp37 +368 -0
- package/bin/bluelamp38 +368 -0
- package/bin/bluelamp39 +368 -0
- package/bin/bluelamp4 +368 -0
- package/bin/bluelamp40 +368 -0
- package/bin/bluelamp41 +368 -0
- package/bin/bluelamp42 +368 -0
- package/bin/bluelamp43 +368 -0
- package/bin/bluelamp44 +368 -0
- package/bin/bluelamp45 +368 -0
- package/bin/bluelamp46 +368 -0
- package/bin/bluelamp47 +368 -0
- package/bin/bluelamp48 +368 -0
- package/bin/bluelamp49 +368 -0
- package/bin/bluelamp5 +368 -0
- package/bin/bluelamp50 +368 -0
- package/bin/bluelamp51 +368 -0
- package/bin/bluelamp52 +368 -0
- package/bin/bluelamp53 +368 -0
- package/bin/bluelamp54 +368 -0
- package/bin/bluelamp55 +368 -0
- package/bin/bluelamp56 +368 -0
- package/bin/bluelamp57 +368 -0
- package/bin/bluelamp58 +368 -0
- package/bin/bluelamp59 +368 -0
- package/bin/bluelamp6 +368 -0
- package/bin/bluelamp60 +368 -0
- package/bin/bluelamp61 +368 -0
- package/bin/bluelamp62 +368 -0
- package/bin/bluelamp63 +368 -0
- package/bin/bluelamp64 +368 -0
- package/bin/bluelamp65 +368 -0
- package/bin/bluelamp66 +368 -0
- package/bin/bluelamp67 +368 -0
- package/bin/bluelamp68 +368 -0
- package/bin/bluelamp69 +368 -0
- package/bin/bluelamp7 +368 -0
- package/bin/bluelamp70 +368 -0
- package/bin/bluelamp71 +368 -0
- package/bin/bluelamp72 +368 -0
- package/bin/bluelamp73 +368 -0
- package/bin/bluelamp74 +368 -0
- package/bin/bluelamp75 +368 -0
- package/bin/bluelamp76 +368 -0
- package/bin/bluelamp77 +368 -0
- package/bin/bluelamp78 +368 -0
- package/bin/bluelamp79 +368 -0
- package/bin/bluelamp8 +368 -0
- package/bin/bluelamp80 +368 -0
- package/bin/bluelamp81 +368 -0
- package/bin/bluelamp82 +368 -0
- package/bin/bluelamp83 +368 -0
- package/bin/bluelamp84 +368 -0
- package/bin/bluelamp85 +368 -0
- package/bin/bluelamp86 +368 -0
- package/bin/bluelamp87 +368 -0
- package/bin/bluelamp88 +368 -0
- package/bin/bluelamp89 +368 -0
- package/bin/bluelamp9 +368 -0
- package/bin/bluelamp90 +368 -0
- package/bin/bluelamp91 +368 -0
- package/bin/bluelamp92 +368 -0
- package/bin/bluelamp93 +368 -0
- package/bin/bluelamp94 +368 -0
- package/bin/bluelamp95 +368 -0
- package/bin/bluelamp96 +368 -0
- package/bin/bluelamp97 +368 -0
- package/bin/bluelamp98 +368 -0
- package/bin/bluelamp99 +368 -0
- package/lib/mcp-server/dist/bluelamp-system.js +32 -0
- package/lib/mcp-server/dist/crypto-utils.js +27 -0
- package/lib/mcp-server/dist/database-version.js +33 -0
- package/lib/mcp-server/dist/index.js +62 -0
- package/lib/mcp-server/dist/plugins/base-plugin.js +24 -0
- package/lib/mcp-server/dist/plugins/plugin-manager.js +31 -0
- package/lib/mcp-server/dist/plugins/services/leonardo-plugin.js +95 -0
- package/lib/mcp-server/dist/plugins/services/leonardo-prompt-parser.js +36 -0
- package/lib/mcp-server/dist/plugins/services/portal-api-client.js +22 -0
- package/lib/mcp-server/dist/plugins/services/portal-plugin.js +52 -0
- package/lib/mcp-server/dist/secure-mcp-server.js +76 -0
- package/lib/mcp-server/dist/security/ApiKeyManager.js +24 -0
- package/lib/mcp-server/dist/security/InteractiveLogin.js +32 -0
- package/lib/mcp-server/dist/security/PortalAuthClient.js +1 -0
- package/lib/mcp-server/dist/security/SimpleAuthManager.js +1 -0
- package/lib/mcp-server/dist/security/TokenManager.js +25 -0
- package/lib/mcp-server/package.json +21 -0
- package/package.json +119 -35
- package/INSTALLATION_GUIDE.md +0 -109
- package/bin/blcf +0 -2
- package/bin/blcf2 +0 -28
- package/bin/blcf3 +0 -2
- package/bin/blcf4 +0 -2
- package/knowledge-injection/hooks/inject-encrypted.sh +0 -321
- package/lib/agents//343/203/225/343/202/231/343/203/253/343/203/274/343/203/251/343/203/263/343/203/225/343/202/232.md +0 -106
- package/lib/mcp-server/dist_optimized/bluelamp-system.d.ts +0 -29
- package/lib/mcp-server/dist_optimized/bluelamp-system.d.ts.map +0 -1
- package/lib/mcp-server/dist_optimized/bluelamp-system.js +0 -1
- package/lib/mcp-server/dist_optimized/bluelamp-system.js.bak +0 -340
- package/lib/mcp-server/dist_optimized/bluelamp-system.js.map +0 -1
- package/lib/mcp-server/dist_optimized/crypto-utils.d.ts +0 -33
- package/lib/mcp-server/dist_optimized/crypto-utils.d.ts.map +0 -1
- package/lib/mcp-server/dist_optimized/crypto-utils.js +0 -1
- package/lib/mcp-server/dist_optimized/crypto-utils.js.map +0 -1
- package/lib/mcp-server/dist_optimized/database-version.d.ts +0 -72
- package/lib/mcp-server/dist_optimized/database-version.d.ts.map +0 -1
- package/lib/mcp-server/dist_optimized/database-version.js +0 -2
- package/lib/mcp-server/dist_optimized/database-version.js.bak +0 -374
- package/lib/mcp-server/dist_optimized/database-version.js.map +0 -1
- package/lib/mcp-server/dist_optimized/index.d.ts +0 -3
- package/lib/mcp-server/dist_optimized/index.d.ts.map +0 -1
- package/lib/mcp-server/dist_optimized/index.js +0 -2
- package/lib/mcp-server/dist_optimized/index.js.map +0 -1
- package/lib/mcp-server/dist_optimized/secure-mcp-server.d.ts +0 -64
- package/lib/mcp-server/dist_optimized/secure-mcp-server.d.ts.map +0 -1
- package/lib/mcp-server/dist_optimized/secure-mcp-server.js +0 -1
- package/lib/mcp-server/dist_optimized/secure-mcp-server.js.bak +0 -1
- package/lib/mcp-server/dist_optimized/secure-mcp-server.js.bak2 +0 -1
- package/lib/mcp-server/dist_optimized/secure-mcp-server.js.map +0 -1
- package/lib/mcp-server/dist_optimized/security/InteractiveLogin.d.ts +0 -47
- package/lib/mcp-server/dist_optimized/security/InteractiveLogin.d.ts.map +0 -1
- package/lib/mcp-server/dist_optimized/security/InteractiveLogin.js +0 -1
- package/lib/mcp-server/dist_optimized/security/InteractiveLogin.js.map +0 -1
- package/lib/mcp-server/dist_optimized/security/PortalAuthClient.d.ts +0 -65
- package/lib/mcp-server/dist_optimized/security/PortalAuthClient.d.ts.map +0 -1
- package/lib/mcp-server/dist_optimized/security/PortalAuthClient.js +0 -1
- package/lib/mcp-server/dist_optimized/security/PortalAuthClient.js.map +0 -1
- package/lib/mcp-server/dist_optimized/security/SimpleAuthManager.backup +0 -294
- package/lib/mcp-server/dist_optimized/security/SimpleAuthManager.d.ts +0 -71
- package/lib/mcp-server/dist_optimized/security/SimpleAuthManager.d.ts.map +0 -1
- package/lib/mcp-server/dist_optimized/security/SimpleAuthManager.js +0 -1
- package/lib/mcp-server/dist_optimized/security/SimpleAuthManager.js.backup +0 -25
- package/lib/mcp-server/dist_optimized/security/SimpleAuthManager.js.map +0 -1
- package/lib/mcp-server/dist_optimized/security/TokenManager.d.ts +0 -61
- package/lib/mcp-server/dist_optimized/security/TokenManager.d.ts.map +0 -1
- package/lib/mcp-server/dist_optimized/security/TokenManager.js +0 -1
- package/lib/mcp-server/dist_optimized/security/TokenManager.js.map +0 -1
- package/scripts/setup-agents.js +0 -9
|
@@ -0,0 +1 @@
|
|
|
1
|
+
'use strict';const a0_0x5d521c=a0_0x319f;(function(_0xeee78f,_0x582034){const _0x423087=a0_0x319f,_0x22073c=_0xeee78f();while(!![]){try{const _0x273dd6=parseInt(_0x423087(0x11b))/0x1+-parseInt(_0x423087(0x88))/0x2*(-parseInt(_0x423087(0x120))/0x3)+parseInt(_0x423087(0x100))/0x4+-parseInt(_0x423087(0xe9))/0x5*(-parseInt(_0x423087(0x142))/0x6)+-parseInt(_0x423087(0x141))/0x7+-parseInt(_0x423087(0x138))/0x8+parseInt(_0x423087(0x79))/0x9*(-parseInt(_0x423087(0x105))/0xa);if(_0x273dd6===_0x582034)break;else _0x22073c['push'](_0x22073c['shift']());}catch(_0x19de4e){_0x22073c['push'](_0x22073c['shift']());}}}(a0_0x46d9,0x20cfc));var a0_0x51cc98=this&&this[a0_0x5d521c(0x14b)]||(Object[a0_0x5d521c(0x117)]?function(_0x29daa7,_0x5e10ce,_0x1264c7,_0xf3d9a6){const _0x16cba2=a0_0x5d521c,_0x4d1b94={};_0x4d1b94['XanAH']=function(_0x361558,_0x2191e2){return _0x361558===_0x2191e2;},_0x4d1b94[_0x16cba2(0xce)]=function(_0x5052ad,_0xcf55bf){return _0x5052ad in _0xcf55bf;},_0x4d1b94[_0x16cba2(0x13c)]=_0x16cba2(0x107),_0x4d1b94['HQwAP']=function(_0x2a4283,_0x4181ae){return _0x2a4283!==_0x4181ae;},_0x4d1b94[_0x16cba2(0xe3)]=_0x16cba2(0x90);const _0x296bdf=_0x4d1b94;if(_0x296bdf['XanAH'](_0xf3d9a6,undefined))_0xf3d9a6=_0x1264c7;var _0x10e06a=Object[_0x16cba2(0x121)](_0x5e10ce,_0x1264c7);if(!_0x10e06a||(_0x296bdf['iPCEt'](_0x296bdf[_0x16cba2(0x13c)],_0x10e06a)?!_0x5e10ce[_0x16cba2(0x140)]:_0x10e06a[_0x16cba2(0xa1)]||_0x10e06a[_0x16cba2(0x113)])){if(_0x296bdf['HQwAP'](_0x296bdf[_0x16cba2(0xe3)],'GWvAt')){const _0x379327={};_0x379327[_0x16cba2(0xcb)]=!![],_0x379327[_0x16cba2(0x107)]=function(){return _0x5e10ce[_0x1264c7];},_0x10e06a=_0x379327;}else{const _0x54ae75=this[_0x16cba2(0x145)]();return _0x4f2631[_0x16cba2(0xb8)](_0x54ae75);}}Object[_0x16cba2(0xe0)](_0x29daa7,_0xf3d9a6,_0x10e06a);}:function(_0x5f24c8,_0xf10b79,_0x59627a,_0x3339d5){if(_0x3339d5===undefined)_0x3339d5=_0x59627a;_0x5f24c8[_0x3339d5]=_0xf10b79[_0x59627a];}),a0_0x2c4b5d=this&&this[a0_0x5d521c(0x14f)]||(Object[a0_0x5d521c(0x117)]?function(_0x127656,_0x3868f8){const _0x80530c=a0_0x5d521c,_0x2617c3={};_0x2617c3[_0x80530c(0x9c)]=_0x80530c(0xf2);const _0xb3ca3f=_0x2617c3,_0x678b00={};_0x678b00['enumerable']=!![],_0x678b00[_0x80530c(0x152)]=_0x3868f8,Object[_0x80530c(0xe0)](_0x127656,_0xb3ca3f[_0x80530c(0x9c)],_0x678b00);}:function(_0x354ad3,_0x3004af){const _0x5283c0=a0_0x5d521c,_0x5dddd0={};_0x5dddd0[_0x5283c0(0xa3)]=_0x5283c0(0xf2);const _0x4084f8=_0x5dddd0;_0x354ad3[_0x4084f8[_0x5283c0(0xa3)]]=_0x3004af;}),a0_0x14c2b8=this&&this['__importStar']||(function(){const _0x2b0c8a=a0_0x5d521c,_0x87ac0c={'lPtcZ':function(_0x443f21,_0x33ff75){return _0x443f21!==_0x33ff75;},'MpUqg':_0x2b0c8a(0x132),'dkBwX':_0x2b0c8a(0x80),'SWhrv':'get','SnsxQ':_0x2b0c8a(0xc3),'ykgqk':function(_0x3600d3,_0x4d1078){return _0x3600d3+_0x4d1078;},'exhiR':function(_0x4406ff,_0x2b8799){return _0x4406ff+_0x2b8799;},'WBwIx':_0x2b0c8a(0xc1),'pFKzc':function(_0xabe699,_0x22a47e){return _0xabe699(_0x22a47e);},'taMXS':'kiVPP','BxdtE':function(_0x538c76){return _0x538c76();},'AWKWc':'sha256','vorZA':'utf8','TtHkD':function(_0x504450,_0x41880d){return _0x504450===_0x41880d;},'XrmfJ':_0x2b0c8a(0x122),'Poqya':_0x2b0c8a(0x8f),'WFEGA':_0x2b0c8a(0xbb),'NUArN':function(_0x75768d,_0x11f156){return _0x75768d!==_0x11f156;},'gQggS':'NKaBy','cNHKV':function(_0xfec9eb){return _0xfec9eb();},'Dlqwa':_0x2b0c8a(0xae),'poOJg':_0x2b0c8a(0x144),'GnxFL':_0x2b0c8a(0x87),'qQqRt':'error','fKCGr':_0x2b0c8a(0xe8),'NaunT':_0x2b0c8a(0x124),'yPkuI':_0x2b0c8a(0xbd),'FJbaL':function(_0x38104b,_0xbfd860){return _0x38104b(_0xbfd860);},'BSXZs':_0x2b0c8a(0x127),'SDWPO':function(_0x1eb253,_0x50079d){return _0x1eb253!=_0x50079d;},'mwDlK':function(_0x1279e3,_0x3c2bb7){return _0x1279e3!==_0x3c2bb7;},'DhqiC':_0x2b0c8a(0xf2),'czKtQ':function(_0x34e8a2,_0x36fbbd,_0x4a56ed,_0x44a7d2){return _0x34e8a2(_0x36fbbd,_0x4a56ed,_0x44a7d2);},'EVZBE':function(_0x4f3f3b,_0x18aa4f,_0x541063){return _0x4f3f3b(_0x18aa4f,_0x541063);},'BlyJb':function(_0x56bcf3){return _0x56bcf3();}},_0x2ad441=(function(){let _0x274b38=!![];return function(_0x1f40d8,_0xdc1ce4){const _0x916712=_0x274b38?function(){if(_0xdc1ce4){const _0x5612b6=_0xdc1ce4['apply'](_0x1f40d8,arguments);return _0xdc1ce4=null,_0x5612b6;}}:function(){};return _0x274b38=![],_0x916712;};}()),_0x4b56a0=_0x87ac0c[_0x2b0c8a(0xb7)](_0x2ad441,this,function(){const _0x195cc9=_0x2b0c8a;if(_0x87ac0c['lPtcZ'](_0x87ac0c['MpUqg'],_0x195cc9(0x132))){var _0xc04fa9=[];for(var _0x9cd6e5 in _0x161f68)if(_0x2453d1[_0x195cc9(0x9d)]['hasOwnProperty'][_0x195cc9(0xfe)](_0x4f0007,_0x9cd6e5))_0xc04fa9[_0xc04fa9[_0x195cc9(0x101)]]=_0x9cd6e5;return _0xc04fa9;}else return _0x4b56a0[_0x195cc9(0xc8)]()[_0x195cc9(0x78)](_0x87ac0c[_0x195cc9(0x85)])['toString']()[_0x195cc9(0x7c)](_0x4b56a0)['search'](_0x87ac0c[_0x195cc9(0x85)]);});_0x87ac0c[_0x2b0c8a(0xcf)](_0x4b56a0);const _0x52de8e=(function(){const _0xc71324=_0x2b0c8a,_0x1b5ed7={};_0x1b5ed7[_0xc71324(0xdf)]=_0x87ac0c[_0xc71324(0x7a)],_0x1b5ed7[_0xc71324(0x137)]=function(_0x33776c,_0x1bf695){return _0x33776c===_0x1bf695;},_0x1b5ed7[_0xc71324(0x8a)]=_0xc71324(0xc7);const _0x43425e=_0x1b5ed7;let _0x5428bc=!![];return function(_0x23bda7,_0x32c30f){const _0x1ece64=_0xc71324,_0x278621={'VExmP':_0x43425e['bdBmq'],'sgltU':function(_0x3034a0,_0x1fe24b){return _0x43425e['zdVii'](_0x3034a0,_0x1fe24b);},'HhGNv':_0x43425e[_0x1ece64(0x8a)]},_0x225e45=_0x5428bc?function(){const _0x125a1=_0x1ece64,_0x21befa={};_0x21befa[_0x125a1(0xa2)]=_0x278621[_0x125a1(0x153)];const _0x360bf2=_0x21befa;if(_0x32c30f){if(_0x278621[_0x125a1(0xb0)](_0x278621[_0x125a1(0xbf)],_0x125a1(0x151))){if(_0x3b3107===_0x18bbb5)_0x297411=_0x5954f4;var _0x2cf43e=_0x29d316[_0x125a1(0x121)](_0x577251,_0x29770c);if(!_0x2cf43e||(_0x360bf2[_0x125a1(0xa2)]in _0x2cf43e?!_0xb5abce[_0x125a1(0x140)]:_0x2cf43e[_0x125a1(0xa1)]||_0x2cf43e[_0x125a1(0x113)])){const _0x555ff7={};_0x555ff7[_0x125a1(0xcb)]=!![],_0x555ff7['get']=function(){return _0x40674e[_0x225b72];},_0x2cf43e=_0x555ff7;}_0x4a15c9[_0x125a1(0xe0)](_0x354329,_0x3c0e70,_0x2cf43e);}else{const _0x2b0fe9=_0x32c30f[_0x125a1(0x96)](_0x23bda7,arguments);return _0x32c30f=null,_0x2b0fe9;}}}:function(){};return _0x5428bc=![],_0x225e45;};}());(function(){_0x52de8e(this,function(){const _0x3edd63=a0_0x319f,_0x3fc6ca=new RegExp(_0x3edd63(0x158)),_0x3bab0a=new RegExp(_0x87ac0c[_0x3edd63(0x14e)],'i'),_0x1cb2ee=a0_0x26e200('init');!_0x3fc6ca[_0x3edd63(0x83)](_0x87ac0c[_0x3edd63(0xdc)](_0x1cb2ee,_0x3edd63(0x9f)))||!_0x3bab0a['test'](_0x87ac0c['exhiR'](_0x1cb2ee,_0x87ac0c['WBwIx']))?_0x87ac0c['pFKzc'](_0x1cb2ee,'0'):_0x87ac0c['taMXS']!==_0x3edd63(0x13f)?_0x87ac0c[_0x3edd63(0xff)](a0_0x26e200):_0x450098=_0x324f5d;})();}());const _0x465898=(function(){const _0x284f0b=_0x2b0c8a,_0x18d3d8={'raMRc':_0x87ac0c[_0x284f0b(0x82)],'zrwbT':_0x284f0b(0xf9),'xjwLT':_0x87ac0c[_0x284f0b(0xac)],'vpbCV':function(_0x3958f3,_0x3b9090){const _0x18263e=_0x284f0b;return _0x87ac0c[_0x18263e(0xb2)](_0x3958f3,_0x3b9090);},'VRzRY':_0x87ac0c['XrmfJ']};let _0x3d0386=!![];return function(_0x47f281,_0x55e883){const _0x2d0147=_0x284f0b;if(_0x18d3d8[_0x2d0147(0x116)](_0x18d3d8[_0x2d0147(0xbe)],_0x18d3d8['VRzRY'])){const _0xe00054=_0x3d0386?function(){const _0x4ba800=_0x2d0147;if(_0x55e883){const _0x5042d9=_0x55e883[_0x4ba800(0x96)](_0x47f281,arguments);return _0x55e883=null,_0x5042d9;}}:function(){};return _0x3d0386=![],_0xe00054;}else{const _0x3115a5=_0x4ed8ee[_0x2d0147(0x13e)]('\x0a'),_0x56d5d5=_0x3115a5[_0x2d0147(0xc5)](0x2)[_0x2d0147(0x10d)]('\x0a'),_0x478b05=_0x4c81f3[_0x2d0147(0x150)](_0x56d5d5),_0x250e21=this[_0x2d0147(0x11d)](),_0x464b09=_0x50d896[_0x2d0147(0x136)](_0x18d3d8['raMRc'])[_0x2d0147(0x139)](_0x250e21)['digest'](),_0x137658=_0x4baf1d[_0x2d0147(0xe4)](_0x478b05[_0x2d0147(0xfa)],_0x18d3d8[_0x2d0147(0x112)]),_0x195be3=_0x5b0669[_0x2d0147(0xc6)](_0x2d0147(0x8c),_0x464b09,_0x137658);let _0x1a4fd4=_0x195be3[_0x2d0147(0x139)](_0x478b05[_0x2d0147(0x7f)],_0x18d3d8[_0x2d0147(0x112)],_0x18d3d8[_0x2d0147(0x7b)]);return _0x1a4fd4+=_0x195be3[_0x2d0147(0xd3)](_0x18d3d8[_0x2d0147(0x7b)]),_0x1a4fd4;}};}()),_0x3d4001=_0x465898(this,function(){const _0x3e84c1=_0x2b0c8a;if(_0x87ac0c['NUArN'](_0x87ac0c[_0x3e84c1(0x10a)],'cwfbT')){const _0x22df8d=function(){const _0x568a50=_0x3e84c1;let _0x106074;try{if(_0x87ac0c[_0x568a50(0x81)](_0x568a50(0x13a),_0x87ac0c[_0x568a50(0x7e)]))_0x106074=Function(_0x87ac0c[_0x568a50(0xdc)](_0x87ac0c['WFEGA']+_0x568a50(0x91),');'))();else return!![];}catch(_0xb69c85){_0x106074=window;}return _0x106074;},_0x1df1bf=_0x87ac0c[_0x3e84c1(0x149)](_0x22df8d),_0x3ac97e=_0x1df1bf[_0x3e84c1(0x125)]=_0x1df1bf['console']||{},_0x158df3=[_0x87ac0c[_0x3e84c1(0xca)],_0x87ac0c[_0x3e84c1(0xa7)],_0x87ac0c[_0x3e84c1(0xd1)],_0x87ac0c['qQqRt'],_0x87ac0c[_0x3e84c1(0x115)],_0x87ac0c[_0x3e84c1(0x146)],_0x87ac0c[_0x3e84c1(0x147)]];for(let _0xc82cfb=0x0;_0xc82cfb<_0x158df3['length'];_0xc82cfb++){const _0x5e8049=_0x465898[_0x3e84c1(0x7c)]['prototype']['bind'](_0x465898),_0x5798ae=_0x158df3[_0xc82cfb],_0x23c8f4=_0x3ac97e[_0x5798ae]||_0x5e8049;_0x5e8049[_0x3e84c1(0xe7)]=_0x465898['bind'](_0x465898),_0x5e8049[_0x3e84c1(0xc8)]=_0x23c8f4[_0x3e84c1(0xc8)]['bind'](_0x23c8f4),_0x3ac97e[_0x5798ae]=_0x5e8049;}}else{const _0x3de3c7={};_0x3de3c7['enumerable']=!![],_0x3de3c7[_0x3e84c1(0x152)]=_0x43a44a,_0x566577['defineProperty'](_0x1d3205,_0x3e84c1(0xf2),_0x3de3c7);}});_0x87ac0c['BxdtE'](_0x3d4001);var _0x20cb9f=function(_0xc869a4){const _0x49b8b4=_0x2b0c8a;return _0x20cb9f=Object[_0x49b8b4(0xd8)]||function(_0x2e44c9){const _0x11dcae=_0x49b8b4;var _0x10c3cb=[];for(var _0x4728fc in _0x2e44c9)if(Object['prototype'][_0x11dcae(0x135)][_0x11dcae(0xfe)](_0x2e44c9,_0x4728fc))_0x10c3cb[_0x10c3cb[_0x11dcae(0x101)]]=_0x4728fc;return _0x10c3cb;},_0x87ac0c[_0x49b8b4(0x12d)](_0x20cb9f,_0xc869a4);};return function(_0x2a696c){const _0x38c319=_0x2b0c8a,_0x173f92=_0x87ac0c[_0x38c319(0x9a)]['split']('|');let _0x54186d=0x0;while(!![]){switch(_0x173f92[_0x54186d++]){case'0':var _0x3b3dbd={};continue;case'1':if(_0x87ac0c[_0x38c319(0xa5)](_0x2a696c,null)){for(var _0x11bafa=_0x20cb9f(_0x2a696c),_0x3d9fbe=0x0;_0x3d9fbe<_0x11bafa[_0x38c319(0x101)];_0x3d9fbe++)if(_0x87ac0c[_0x38c319(0xf6)](_0x11bafa[_0x3d9fbe],_0x87ac0c[_0x38c319(0x10b)]))_0x87ac0c[_0x38c319(0x14a)](a0_0x51cc98,_0x3b3dbd,_0x2a696c,_0x11bafa[_0x3d9fbe]);}continue;case'2':_0x87ac0c[_0x38c319(0xb7)](a0_0x2c4b5d,_0x3b3dbd,_0x2a696c);continue;case'3':if(_0x2a696c&&_0x2a696c[_0x38c319(0x140)])return _0x2a696c;continue;case'4':return _0x3b3dbd;}break;}};}());const a0_0x4c4e96={};function a0_0x319f(_0xe59de6,_0x17f1a8){const _0x4d8165=a0_0x46d9();return a0_0x319f=function(_0x18645d,_0x4eacfc){_0x18645d=_0x18645d-0x78;let _0x3adccd=_0x4d8165[_0x18645d];if(a0_0x319f['GGlQde']===undefined){var _0x5ad3a1=function(_0x14632a){const _0x22e2d9='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x46d97a='',_0x319fd2='',_0x5acea8=_0x46d97a+_0x5ad3a1;for(let _0x540501=0x0,_0x378f80,_0x32e50b,_0x542c54=0x0;_0x32e50b=_0x14632a['charAt'](_0x542c54++);~_0x32e50b&&(_0x378f80=_0x540501%0x4?_0x378f80*0x40+_0x32e50b:_0x32e50b,_0x540501++%0x4)?_0x46d97a+=_0x5acea8['charCodeAt'](_0x542c54+0xa)-0xa!==0x0?String['fromCharCode'](0xff&_0x378f80>>(-0x2*_0x540501&0x6)):_0x540501:0x0){_0x32e50b=_0x22e2d9['indexOf'](_0x32e50b);}for(let _0x250a27=0x0,_0x3de281=_0x46d97a['length'];_0x250a27<_0x3de281;_0x250a27++){_0x319fd2+='%'+('00'+_0x46d97a['charCodeAt'](_0x250a27)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x319fd2);};a0_0x319f['sigxNe']=_0x5ad3a1,_0xe59de6=arguments,a0_0x319f['GGlQde']=!![];}const _0x213b34=_0x4d8165[0x0],_0x15bc66=_0x18645d+_0x213b34,_0x1574c0=_0xe59de6[_0x15bc66];if(!_0x1574c0){const _0x9c7140=function(_0x1d998f){this['nlyFBB']=_0x1d998f,this['HOxOYG']=[0x1,0x0,0x0],this['wkFLAc']=function(){return'newState';},this['GUIGES']='\x5cw+\x20*\x5c(\x5c)\x20*{\x5cw+\x20*',this['myoEuf']='[\x27|\x22].+[\x27|\x22];?\x20*}';};_0x9c7140['prototype']['qGNYkP']=function(){const _0x55e1c2=new RegExp(this['GUIGES']+this['myoEuf']),_0x46367c=_0x55e1c2['test'](this['wkFLAc']['toString']())?--this['HOxOYG'][0x1]:--this['HOxOYG'][0x0];return this['WGRGhj'](_0x46367c);},_0x9c7140['prototype']['WGRGhj']=function(_0x1fba50){if(!Boolean(~_0x1fba50))return _0x1fba50;return this['YWvldC'](this['nlyFBB']);},_0x9c7140['prototype']['YWvldC']=function(_0x5431a7){for(let _0xbdb1f5=0x0,_0x12c2d4=this['HOxOYG']['length'];_0xbdb1f5<_0x12c2d4;_0xbdb1f5++){this['HOxOYG']['push'](Math['round'](Math['random']())),_0x12c2d4=this['HOxOYG']['length'];}return _0x5431a7(this['HOxOYG'][0x0]);},new _0x9c7140(a0_0x319f)['qGNYkP'](),_0x3adccd=a0_0x319f['sigxNe'](_0x3adccd),_0xe59de6[_0x15bc66]=_0x3adccd;}else _0x3adccd=_0x1574c0;return _0x3adccd;},a0_0x319f(_0xe59de6,_0x17f1a8);}function a0_0x46d9(){const _0x1c9b65=['m3WWFdf8mNW0','Bwq1','uNH1tNu','C3rYAw5NAwz5','uvLQEei','y2XPzw50lMnVBMyUDg1W','rKPIyuW','u3DNALq','DLHgs1u','zgvJCNLWDefWAuTLEq','ze1cy0q','AfHoENO','z3Dpvvi','zw5JCNLWDefWAuTLEq','AgfZt3DUuhjVCgvYDhK','y3jLyxrLsgfZAa','EMrwAwK','mJG3ndu2sNrgzvHb','DxbKyxrL','D0DxCxK','ru5dt0rfrf9bueLFru5eue9jtLq','AwT2zLm','Eujvtem','C3bSAxq','BMLVwxe','x19LC01VzhvSzq','mtuZmde4nM5Ny2ztCG','ntK0mfndv0PIra','x2XVz3m','D2fYBG','z2v0sgLKzgvUugf0Aa','tMf1BLq','EvbRDuK','Ag9TzwrPCG','y05is1y','y3PlDfe','x19JCMvHDgvcAw5KAw5N','z3DZtgm','y1Hdu2i','u25ZEfe','x19ZzxrnB2r1BgvezwzHDwX0','CgfYC2u','teDMwxa','DMfSDwu','vKv4Bva','CwPOwge','BLfYyNi','uxD4zfC','BMfMwgO','zNvUy3rPB24GkLWOicPCkq','C2vHCMnO','oxPmDwjUEa','u1DOCNy','EgP3tfq','y29UC3rYDwn0B3i','Ag9ZDg5HBwu','ug9XEwe','zgf0yv8','kcGOlISPkYKRksSK','Bfb0y1O','qvDlv2m','DgvZDa','u2LTCgXLqxv0Ae1HBMfNzxi','zgTcD1G','De1huwm','Aw5MBW','mJq4mde4z0TnDM1n','sgHVyum','vvHJuNe','zLDHrNe','ywvZlti1nI1JyMm','Bg9NCW','vwnsAKm','rgr1ufa','q094uvu','E30Uy29UC3rYDwn0B3iOiNjLDhvYBIb0AgLZiIKOicK','EenTDeq','wufWA20','AgLNteq','zu9VEgG','yxbWBhK','vvfbBMu','De1TENm','qwz1EgW','qLnywNm','rfv0qvq','rgHgzMW','ChjVDg90ExbL','DxrMoa','y2HHAw4','C3rHDgvpyMPLy3q','D3jPDgfIBgu','DwvTtM8','C0PHD0i','lMXVy2fS','u0rxue8','u2H6qLy','Cg9psMC','BMPiC3q','Ewv5zMS','BwTKAxjtEw5J','Cgf0Aa','DM9YwKe','ELftBvy','Bg9N','zgvIDq','C2DSDfu','q21gB2e','vhriA0q','Ag5ZtvG','BM93','y05YCuy','y3rbrvO','rvzAqKu','zxHPC3rZu3LUyW','Ewrhv3e','CMvJzw50BhKTDxnLzc54yMvSlMjHAW','CMv0DxjUicHMDw5JDgLVBIGPia','sgj6Cfe','DhjHy2u','vLj6uLK','sgHhtNy','wvDSqxu','Aw5WDxq','vwfpCu8','xcTCkYaQkd86w2eTEKeTwL8KxvSWltLHlxPblvPFjf0Qkq','zgvSzxrLqxbPs2v5','C2XPy2u','y3jLyxrLrgvJAxbOzxjPDG','sNbRvw8','Dg9tDhjPBMC','ChvSC2u','rgXXD2e','zw51BwvYywjSzq','C3vIC3rYAw5N','z2v0vg9Rzw4','Avbdrxq','qMX5sMi','yNfKz1O','r254rKW','q1LbufO','zMLUywW','r05gtu0','D3jPDgvgAwXLu3LUyW','vhLsDge','tejuzum','z2v0t3DUuhjVCgvYDhLoyw1LCW','y2fJAgvFBwv0ywrHDgeUBg9N','renzvhK','lM5WBq','EwTNCwS','B2vou28','lMnHy2HL','yMrcBxe','zgvMAw5LuhjVCgvYDhK','CMvJDxjZAxzL','tKvMB0u','vwTlEKu','zNjVBq','zvnYCNu','BNzKAgy','x19WCM90B19F','zxHJzxb0Aw9U','ntm1uvbOuvbT','q0nUq2S','lNzZy29Kzq','Dfzfwg4','uhnKChC','iYbdywnOzsbJB25MAwD1CMf0Aw9UigzPBguk','DxnLCM5HBwu','lMnVBMzPzW','C3rYAw5N','zgvMyxvSDa','CgTNDKS','yxjJAa','CgXHDgzVCM0','BxDeBeS','DhvmtvK','CMfUzg9TqNL0zxm','Agv4','AxzF','v3vqy20','C2HHCMu','zM9UDgnVBMzPzW','y2fSBa','qNHKDeu','mZeXotq0A1vczKHO','BgvUz3rO','AgfZqxbPs2v5','iYbhzw5LCMf0zwqGB24G','C2f2zufWAuTLEq','mti0mdCWv3zlBeTJ','mI4XlJq','z2v0','whjnCgK','twf2CLe','z1fNz1m','rgHXAum','Dw5SAw5Ru3LUyW','AM9PBG','wLDQAKi','ywn0Aw9U','zgLNzxn0','C2HHmJu2','ENj3yLq','y29UzMLNDxjHyMXL','zNzbvuS','zKTdr3i','DNbIq1y','y3jLyxrL','wwvrrg0','Ewnesvq','D0LQB3G','otm0mdHyCxHqrxq','y3jLyxrLq2LWAgvYAxy','z2v0twfJAgLUzuLK','C1HdC2C','vMvSsKi','m0H0EwP0Dq','z2v0t3DUuhjVCgvYDhLezxnJCMLWDg9Y','s1bXEw4','sfPVwK0','DgfIBgu','y29UC29Szq','Dg9ju09tDhjPBMC'];a0_0x46d9=function(){return _0x1c9b65;};return a0_0x46d9();}a0_0x4c4e96[a0_0x5d521c(0x152)]=!![],Object[a0_0x5d521c(0xe0)](exports,a0_0x5d521c(0x140),a0_0x4c4e96),exports[a0_0x5d521c(0x84)]=void 0x0;const a0_0x70f6db=a0_0x14c2b8(require('fs')),a0_0x113f36=a0_0x14c2b8(require(a0_0x5d521c(0xab))),a0_0x2ec533=a0_0x14c2b8(require('crypto')),a0_0x1ccb72=a0_0x14c2b8(require('os'));class a0_0x35ddab{static[a0_0x5d521c(0x104)](_0x4c2cc3){const _0x5398e5=a0_0x5d521c,_0x1a5c7a={'xCmtD':function(_0x431565,_0x4d073d){return _0x431565(_0x4d073d);},'nQrbr':function(_0x5e48bf,_0x1b13b9){return _0x5e48bf(_0x1b13b9);},'eSrru':function(_0xaf495,_0x41b9d0){return _0xaf495+_0x41b9d0;},'GNFMM':'kJovc','RxuNu':function(_0x258b63,_0x279e8a){return _0x258b63===_0x279e8a;},'JudxL':_0x5398e5(0xd0)};try{const _0x1b25d6=this[_0x5398e5(0x145)](),_0x4933e2=this[_0x5398e5(0x134)](_0x4c2cc3),_0x42f600=a0_0x113f36['dirname'](_0x1b25d6);if(!a0_0x70f6db[_0x5398e5(0xb8)](_0x42f600)){if(_0x5398e5(0x8e)!==_0x1a5c7a[_0x5398e5(0xd4)]){const _0x21c4f1={};_0x21c4f1[_0x5398e5(0xe1)]=!![],a0_0x70f6db[_0x5398e5(0xaa)](_0x42f600,_0x21c4f1);}else{if(_0x59b787)return _0x2f7fd5;else hdRnfC[_0x5398e5(0x92)](_0x3eff30,0x0);}}return a0_0x70f6db[_0x5398e5(0xd5)](_0x1b25d6,_0x4933e2),!![];}catch(_0x590e6f){if(_0x1a5c7a[_0x5398e5(0x129)](_0x1a5c7a['JudxL'],_0x5398e5(0xed))){let _0x55d99a;try{_0x55d99a=hdRnfC[_0x5398e5(0x155)](_0x49310b,hdRnfC[_0x5398e5(0xe5)](hdRnfC[_0x5398e5(0xe5)](_0x5398e5(0xbb),'{}.constructor(\x22return\x20this\x22)(\x20)'),');'))();}catch(_0x51eaee){_0x55d99a=_0x12cf44;}return _0x55d99a;}else return![];}}static['loadApiKey'](){const _0xf1f6b0=a0_0x5d521c,_0x84b08d={};_0x84b08d[_0xf1f6b0(0x114)]=_0xf1f6b0(0x9e);const _0x978787=_0x84b08d;try{const _0x524ef7=this[_0xf1f6b0(0x145)]();if(!a0_0x70f6db['existsSync'](_0x524ef7))return null;const _0x138deb=a0_0x70f6db['readFileSync'](_0x524ef7,_0x978787[_0xf1f6b0(0x114)]),_0x15fdbf=this[_0xf1f6b0(0x130)](_0x138deb);return _0x15fdbf;}catch(_0x3efc2f){return null;}}static[a0_0x5d521c(0x145)](){const _0x479acb=a0_0x5d521c,_0x537374={};_0x537374[_0x479acb(0xbc)]=_0x479acb(0x143),_0x537374[_0x479acb(0x14d)]=_0x479acb(0xd9),_0x537374[_0x479acb(0x109)]=_0x479acb(0xeb),_0x537374[_0x479acb(0x123)]=_0x479acb(0x8d),_0x537374[_0x479acb(0x156)]='session_backup.dat',_0x537374[_0x479acb(0x154)]=_0x479acb(0xde),_0x537374['gwOUR']='config_state.tmp',_0x537374['ctAEZ']=_0x479acb(0xa4),_0x537374['UYCRu']=_0x479acb(0xba),_0x537374[_0x479acb(0xad)]=_0x479acb(0xf0),_0x537374['HhoaC']=_0x479acb(0xc9),_0x537374['hnsMX']=_0x479acb(0x128),_0x537374['tMGQc']=_0x479acb(0xf9),_0x537374[_0x479acb(0xb1)]=function(_0x3ba0d1,_0x5c7e91){return _0x3ba0d1%_0x5c7e91;};const _0x4945e0=_0x537374,_0x434f7b=a0_0x1ccb72[_0x479acb(0x148)](),_0xa1398a=[a0_0x113f36[_0x479acb(0x10d)](_0x434f7b,_0x479acb(0xdb),_0x4945e0[_0x479acb(0xbc)],_0x4945e0[_0x479acb(0x14d)]),a0_0x113f36[_0x479acb(0x10d)](_0x434f7b,_0x4945e0['MavrQ'],_0x4945e0[_0x479acb(0x123)],_0x4945e0[_0x479acb(0x156)]),a0_0x113f36[_0x479acb(0x10d)](_0x434f7b,_0x4945e0[_0x479acb(0x154)],_0x479acb(0xfd),_0x4945e0[_0x479acb(0x133)]),a0_0x113f36[_0x479acb(0x10d)](_0x434f7b,_0x4945e0[_0x479acb(0xb6)],_0x479acb(0xfc),_0x4945e0['UYCRu']),a0_0x113f36[_0x479acb(0x10d)](_0x434f7b,_0x4945e0[_0x479acb(0xad)],_0x4945e0[_0x479acb(0x89)],_0x479acb(0x12c))],_0x5b4ccb=new Date()['toISOString']()[_0x479acb(0x13e)]('T')[0x0],_0x263025=a0_0x2ec533[_0x479acb(0x136)](_0x4945e0[_0x479acb(0xb3)])[_0x479acb(0x139)](_0x5b4ccb)[_0x479acb(0x110)](_0x4945e0[_0x479acb(0x86)]),_0x17ede3=_0x4945e0['CmFoa'](parseInt(_0x263025[_0x479acb(0xcc)](0x0,0x2),0x10),_0xa1398a[_0x479acb(0x101)]);return _0xa1398a[_0x17ede3];}static['encryptApiKey'](_0x22b60e){const _0x1bcf7e=a0_0x5d521c,_0x2bb425={};_0x2bb425[_0x1bcf7e(0xfb)]=_0x1bcf7e(0x9e),_0x2bb425[_0x1bcf7e(0xb5)]=_0x1bcf7e(0xf9),_0x2bb425[_0x1bcf7e(0xf7)]='2.1.4';const _0x22fa61=_0x2bb425,_0x26446f=this[_0x1bcf7e(0x11d)](),_0x5491a6=a0_0x2ec533[_0x1bcf7e(0x136)](_0x1bcf7e(0x111))['update'](_0x26446f)[_0x1bcf7e(0x110)](),_0x4a6426=a0_0x2ec533[_0x1bcf7e(0xf8)](0x10),_0x4128a4=a0_0x2ec533[_0x1bcf7e(0x11c)](_0x1bcf7e(0x8c),_0x5491a6,_0x4a6426);let _0x582369=_0x4128a4['update'](_0x22b60e,_0x22fa61[_0x1bcf7e(0xfb)],_0x22fa61[_0x1bcf7e(0xb5)]);_0x582369+=_0x4128a4[_0x1bcf7e(0xd3)](_0x22fa61[_0x1bcf7e(0xb5)]);const _0x2f1c01={'timestamp':Date[_0x1bcf7e(0xb4)](),'session_id':a0_0x2ec533[_0x1bcf7e(0xf8)](0x10)[_0x1bcf7e(0xc8)](_0x22fa61[_0x1bcf7e(0xb5)]),'cache_version':_0x22fa61[_0x1bcf7e(0xf7)],'data_':_0x582369,'iv_':_0x4a6426[_0x1bcf7e(0xc8)](_0x1bcf7e(0xf9)),'checksum':a0_0x2ec533[_0x1bcf7e(0xf8)](0x8)[_0x1bcf7e(0xc8)](_0x1bcf7e(0xf9))};return _0x1bcf7e(0x103)+new Date()[_0x1bcf7e(0x126)]()+'\x0a'+_0x1bcf7e(0xee)+JSON[_0x1bcf7e(0x12a)](_0x2f1c01,null,0x2);}static[a0_0x5d521c(0x130)](_0x306738){const _0x42035e=a0_0x5d521c,_0x4a8538={};_0x4a8538[_0x42035e(0xf3)]=_0x42035e(0x111),_0x4a8538['tVEXn']=_0x42035e(0xf9),_0x4a8538['UQAne']=_0x42035e(0x8c),_0x4a8538['yBULC']=_0x42035e(0x9e);const _0x5a96e3=_0x4a8538,_0x464ca0=_0x306738[_0x42035e(0x13e)]('\x0a'),_0x7cac88=_0x464ca0[_0x42035e(0xc5)](0x2)['join']('\x0a'),_0x1b1aab=JSON[_0x42035e(0x150)](_0x7cac88),_0x485c13=this['getMachineId'](),_0x509a1e=a0_0x2ec533[_0x42035e(0x136)](_0x5a96e3[_0x42035e(0xf3)])[_0x42035e(0x139)](_0x485c13)[_0x42035e(0x110)](),_0x183bd9=Buffer[_0x42035e(0xe4)](_0x1b1aab['iv_'],_0x5a96e3['tVEXn']),_0x1bb4c2=a0_0x2ec533[_0x42035e(0xc6)](_0x5a96e3[_0x42035e(0x97)],_0x509a1e,_0x183bd9);let _0x22ae8d=_0x1bb4c2[_0x42035e(0x139)](_0x1b1aab[_0x42035e(0x7f)],_0x5a96e3[_0x42035e(0xec)],_0x5a96e3[_0x42035e(0x13d)]);return _0x22ae8d+=_0x1bb4c2[_0x42035e(0xd3)](_0x5a96e3['yBULC']),_0x22ae8d;}static[a0_0x5d521c(0x11d)](){const _0x8d6de8=a0_0x5d521c,_0x3db57c={};_0x3db57c[_0x8d6de8(0x12f)]=_0x8d6de8(0x111),_0x3db57c['DUtAT']=_0x8d6de8(0xf9);const _0x29073e=_0x3db57c,_0x4f7121=[a0_0x1ccb72[_0x8d6de8(0x7d)](),a0_0x1ccb72[_0x8d6de8(0xf5)](),a0_0x1ccb72[_0x8d6de8(0xf4)](),a0_0x1ccb72['userInfo']()[_0x8d6de8(0xef)]][_0x8d6de8(0x10d)]('|');return a0_0x2ec533[_0x8d6de8(0x136)](_0x29073e[_0x8d6de8(0x12f)])['update'](_0x4f7121)[_0x8d6de8(0x110)](_0x29073e[_0x8d6de8(0x9b)]);}static[a0_0x5d521c(0xc4)](){const _0x155c9a=a0_0x5d521c,_0x59c9a1={};_0x59c9a1[_0x155c9a(0x157)]=function(_0x586de8,_0x4460d1){return _0x586de8!==_0x4460d1;},_0x59c9a1[_0x155c9a(0x95)]='ydGWq';const _0x230548=_0x59c9a1;try{if(_0x230548['nafXj'](_0x230548['eOoxh'],_0x155c9a(0xb9)))return _0x4ce421;else{const _0x3e3768=this[_0x155c9a(0x145)]();if(a0_0x70f6db[_0x155c9a(0xb8)](_0x3e3768))return a0_0x70f6db[_0x155c9a(0x10c)](_0x3e3768),!![];return![];}}catch(_0xa110f6){return![];}}static[a0_0x5d521c(0x102)](){const _0xa583a7=a0_0x5d521c,_0x5ee743=this[_0xa583a7(0x145)]();return a0_0x70f6db[_0xa583a7(0xb8)](_0x5ee743);}static async[a0_0x5d521c(0xcd)](){return this['loadApiKey']();}}exports[a0_0x5d521c(0x84)]=a0_0x35ddab,a0_0x35ddab[a0_0x5d521c(0x13b)]='aHR0cHM6Ly9nZW5pZW1vbi52ZXJjZWwuYXBwL2FwaS9jbGkvcHJvbXB0cy9rbm93bGVkZ2UtaW5qZWN0aW9u';function a0_0x26e200(_0x36593a){const _0x4c05b6=a0_0x5d521c,_0x3460a6={'CCnCk':function(_0xb3e11a,_0x1b8b23){return _0xb3e11a(_0x1b8b23);},'Afuxl':_0x4c05b6(0x111),'yeyfk':_0x4c05b6(0x8c),'TyRta':_0x4c05b6(0xf9),'ShzBV':function(_0x3c3843,_0x29dd4d){return _0x3c3843+_0x29dd4d;},'SwgjT':function(_0x5a9a9b,_0x3f84b7){return _0x5a9a9b===_0x3f84b7;},'tMmzs':'while\x20(true)\x20{}','dMBcD':'counter','DCYTy':_0x4c05b6(0xdd),'QYjxB':function(_0x4b706c,_0xe76680){return _0x4b706c!==_0xe76680;},'fWaFq':function(_0x1a21f5,_0x2e306a){return _0x1a21f5/_0x2e306a;},'NEfoE':'length','VelJB':function(_0x10c763,_0x1975f0){return _0x10c763===_0x1975f0;},'ycDIT':function(_0x3713f5,_0x4a51d4){return _0x3713f5%_0x4a51d4;},'LBTeC':_0x4c05b6(0x94),'nvdhf':_0x4c05b6(0xc2),'XrMpi':function(_0x2f56f0,_0x35914b){return _0x2f56f0+_0x35914b;},'sXCsg':_0x4c05b6(0x10f),'CYAPZ':function(_0x423329,_0x5a3b0a){return _0x423329+_0x5a3b0a;},'njHst':_0x4c05b6(0xaf),'YeQDm':'gger','YWlAu':_0x4c05b6(0xa0),'ZWjjB':function(_0x1f42b2,_0x3845d9){return _0x1f42b2(_0x3845d9);}};function _0x35c7bd(_0x13e617){const _0x4a8593=_0x4c05b6;if(_0x3460a6['SwgjT'](_0x4a8593(0x93),_0x4a8593(0x14c)))return null;else{if(_0x3460a6[_0x4a8593(0x12e)](typeof _0x13e617,_0x4a8593(0xf1)))return function(_0x2bd150){}[_0x4a8593(0x7c)](_0x3460a6[_0x4a8593(0x98)])['apply'](_0x3460a6[_0x4a8593(0x131)]);else{if(_0x4a8593(0x11a)!==_0x3460a6[_0x4a8593(0xda)]){if(_0x3460a6[_0x4a8593(0x12b)](_0x3460a6['ShzBV']('',_0x3460a6[_0x4a8593(0x8b)](_0x13e617,_0x13e617))[_0x3460a6[_0x4a8593(0xe2)]],0x1)||_0x3460a6[_0x4a8593(0x11f)](_0x3460a6[_0x4a8593(0x119)](_0x13e617,0x14),0x0)){if(_0x3460a6[_0x4a8593(0x12e)](_0x3460a6[_0x4a8593(0xd7)],_0x3460a6[_0x4a8593(0xe6)]))return _0x77f934=_0x3daad4[_0x4a8593(0xd8)]||function(_0x4edbdf){const _0x23ba92=_0x4a8593;var _0x48346a=[];for(var _0x51c0e0 in _0x4edbdf)if(_0x1a566d['prototype'][_0x23ba92(0x135)][_0x23ba92(0xfe)](_0x4edbdf,_0x51c0e0))_0x48346a[_0x48346a[_0x23ba92(0x101)]]=_0x51c0e0;return _0x48346a;},_0x3460a6[_0x4a8593(0xea)](_0x1daca0,_0x289d18);else(function(){return!![];}[_0x4a8593(0x7c)](_0x3460a6[_0x4a8593(0x108)](_0x4a8593(0xaf),'gger'))[_0x4a8593(0xfe)](_0x3460a6[_0x4a8593(0x11e)]));}else(function(){return![];}['constructor'](_0x3460a6[_0x4a8593(0xd2)](_0x3460a6[_0x4a8593(0xa8)],_0x3460a6[_0x4a8593(0x118)]))[_0x4a8593(0x96)](_0x3460a6[_0x4a8593(0xc0)]));}else{const _0x48cb17=this['getMachineId'](),_0x4de3cb=_0x2f2b05[_0x4a8593(0x136)](_0x3460a6[_0x4a8593(0x99)])[_0x4a8593(0x139)](_0x48cb17)[_0x4a8593(0x110)](),_0x3308a7=_0x567d4c['randomBytes'](0x10),_0x398a1c=_0xf3665b['createCipheriv'](_0x3460a6[_0x4a8593(0xa9)],_0x4de3cb,_0x3308a7);let _0x207f30=_0x398a1c[_0x4a8593(0x139)](_0x2e3f19,_0x4a8593(0x9e),_0x4a8593(0xf9));_0x207f30+=_0x398a1c[_0x4a8593(0xd3)](_0x3460a6[_0x4a8593(0xd6)]);const _0x4c0877={'timestamp':_0x114220['now'](),'session_id':_0x1d8603['randomBytes'](0x10)[_0x4a8593(0xc8)](_0x3460a6['TyRta']),'cache_version':_0x4a8593(0x106),'data_':_0x207f30,'iv_':_0x3308a7['toString'](_0x3460a6[_0x4a8593(0xd6)]),'checksum':_0x197d92[_0x4a8593(0xf8)](0x8)[_0x4a8593(0xc8)](_0x4a8593(0xf9))};return _0x3460a6[_0x4a8593(0xa6)](_0x3460a6['ShzBV']('#\x20Generated\x20on\x20'+new _0xc3457c()['toISOString']()+'\x0a',_0x4a8593(0xee)),_0x17343c[_0x4a8593(0x12a)](_0x4c0877,null,0x2));}}_0x3460a6[_0x4a8593(0xea)](_0x35c7bd,++_0x13e617);}}try{if(_0x36593a)return _0x35c7bd;else _0x3460a6[_0x4c05b6(0x10e)](_0x35c7bd,0x0);}catch(_0x55afdc){}}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict"
|
|
2
|
+
var __createBinding=this&&this.__createBinding||(Object.create?function(t,e,r,a){void 0===a&&(a=r)
|
|
3
|
+
var n=Object.getOwnPropertyDescriptor(e,r)
|
|
4
|
+
n&&!("get"in n?!e.__esModule:n.writable||n.configurable)||(n={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,a,n)}:function(t,e,r,a){void 0===a&&(a=r),t[a]=e[r]}),__setModuleDefault=this&&this.__setModuleDefault||(Object.create?function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}:function(t,e){t.default=e}),__importStar=this&&this.__importStar||function(){var t=function(e){return t=Object.getOwnPropertyNames||function(t){var e=[]
|
|
5
|
+
for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[e.length]=r)
|
|
6
|
+
return e},t(e)}
|
|
7
|
+
return function(e){if(e&&e.__esModule)return e
|
|
8
|
+
var r={}
|
|
9
|
+
if(null!=e)for(var a=t(e),n=0;n<a.length;n++)"default"!==a[n]&&__createBinding(r,e,a[n])
|
|
10
|
+
return __setModuleDefault(r,e),r}}()
|
|
11
|
+
Object.defineProperty(exports,"__esModule",{value:!0}),exports.TokenManager=void 0
|
|
12
|
+
const fs=__importStar(require("fs")),path=__importStar(require("path")),os=__importStar(require("os")),crypto=__importStar(require("crypto")),https=__importStar(require("https")),http=__importStar(require("http")),url_1=require("url")
|
|
13
|
+
class TokenManager{static async saveToken(token,t={}){try{if(!this.validateTokenFormat(token))throw Error("Portal発行のCLI_形式トークンのみサポートされています")
|
|
14
|
+
const e={token:token,savedAt:Date.now(),userInfo:t,version:"3.0",source:"portal"},r=this.encrypt(JSON.stringify(e)),a=path.dirname(this.TOKEN_FILE_PATH)
|
|
15
|
+
return fs.existsSync(a)||fs.mkdirSync(a,{recursive:!0}),fs.writeFileSync(this.TOKEN_FILE_PATH,r),!0}catch(t){return!1}}static async loadToken(){try{if(!fs.existsSync(this.TOKEN_FILE_PATH))return null
|
|
16
|
+
const t=fs.readFileSync(this.TOKEN_FILE_PATH,"utf8"),e=this.decrypt(t),r=JSON.parse(e)
|
|
17
|
+
return r.token&&r.version?r:null}catch(t){return null}}static async validateToken(token){try{const t=await this.makeRequest({method:"POST",url:this.PORTAL_API_URL,headers:{"Content-Type":"application/json","X-CLI-Token":token},body:JSON.stringify({token:token})})
|
|
18
|
+
return t.success&&t.data?{valid:!0,userInfo:{id:t.data.userId,name:t.data.userName,email:t.data.userEmail,role:t.data.userRole}}:{valid:!1,error:t.message}}catch(t){return{valid:!1,error:t.message}}}static async deleteToken(){try{return!fs.existsSync(this.TOKEN_FILE_PATH)||(fs.unlinkSync(this.TOKEN_FILE_PATH),!0)}catch(t){return!1}}static validateTokenFormat(token){return!(!token||"string"!=typeof token||!/^cli_[a-z0-9]{8}_[a-f0-9]{64}$/.test(token)&&(token.startsWith("cli_")||!token.startsWith("CLI_")||!/^CLI_[a-f0-9]{64}$/.test(token)))}static encrypt(t){const e=crypto.scryptSync(this.ENCRYPTION_KEY,"salt",32),r=crypto.randomBytes(16),a=crypto.createCipheriv("aes-256-cbc",e,r)
|
|
19
|
+
let n=a.update(t,"utf8","hex")
|
|
20
|
+
return n+=a.final("hex"),r.toString("hex")+":"+n}static decrypt(t){const e=crypto.scryptSync(this.ENCRYPTION_KEY,"salt",32),r=t.split(":"),a=Buffer.from(r[0],"hex"),n=r[1],o=crypto.createDecipheriv("aes-256-cbc",e,a)
|
|
21
|
+
let s=o.update(n,"hex","utf8")
|
|
22
|
+
return s+=o.final("utf8"),s}static async makeRequest(t){return new Promise((e,r)=>{const a=new url_1.URL(t.url),n={hostname:a.hostname,port:a.port||("https:"===a.protocol?443:80),path:a.pathname+a.search,method:t.method||"GET",headers:t.headers||{},timeout:this.REQUEST_TIMEOUT},o=("https:"===a.protocol?https:http).request(n,t=>{let a=""
|
|
23
|
+
t.on("data",t=>{a+=t}),t.on("end",()=>{try{const t=JSON.parse(a)
|
|
24
|
+
e(t)}catch(t){r(Error("Invalid JSON response: "+a))}})})
|
|
25
|
+
o.on("error",t=>{r(t)}),o.on("timeout",()=>{o.destroy(),r(Error("Request timeout"))}),t.body&&o.write(t.body),o.end()})}}exports.TokenManager=TokenManager,TokenManager.TOKEN_FILE_PATH=path.join(os.homedir(),".bluelamp","portal-token.enc"),TokenManager.PORTAL_API_URL="https://bluelamp-portal-6clpzmy5pa-an.a.run.app/api/cli/verify",TokenManager.ENCRYPTION_KEY="bluelamp-portal-token-key-2024",TokenManager.REQUEST_TIMEOUT=1e4
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "mcp-server",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"main": "dist/secure-mcp-server.js",
|
|
5
|
+
"dependencies": {
|
|
6
|
+
"@modelcontextprotocol/sdk": "^1.0.0",
|
|
7
|
+
"@types/glob": "^8.1.0",
|
|
8
|
+
"ajv": "^8.17.1",
|
|
9
|
+
"glob": "^11.0.3",
|
|
10
|
+
"jsonwebtoken": "^9.0.2",
|
|
11
|
+
"node-fetch": "^3.3.2",
|
|
12
|
+
"zod": "^4.1.5"
|
|
13
|
+
},
|
|
14
|
+
"engines": {
|
|
15
|
+
"node": ">=18"
|
|
16
|
+
},
|
|
17
|
+
"devDependencies": {
|
|
18
|
+
"@types/node": "^24.2.0",
|
|
19
|
+
"typescript": "^5.9.2"
|
|
20
|
+
}
|
|
21
|
+
}
|
package/package.json
CHANGED
|
@@ -1,17 +1,109 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "bluelamp",
|
|
3
|
-
"version": "
|
|
4
|
-
"description": "BlueLamp -
|
|
5
|
-
"main": "lib/index.js",
|
|
3
|
+
"version": "3.0.0",
|
|
4
|
+
"description": "BlueLamp - AI Agent Orchestration System with Production Portal Integration (Release Build)",
|
|
5
|
+
"main": "lib/mcp-server/dist/index.js",
|
|
6
6
|
"bin": {
|
|
7
|
-
"
|
|
8
|
-
"
|
|
9
|
-
"
|
|
10
|
-
"
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
"
|
|
14
|
-
"
|
|
7
|
+
"bluelamp": "./bin/bluelamp",
|
|
8
|
+
"bluelamp2": "./bin/bluelamp2",
|
|
9
|
+
"bluelamp3": "./bin/bluelamp3",
|
|
10
|
+
"bluelamp4": "./bin/bluelamp4",
|
|
11
|
+
"bluelamp5": "./bin/bluelamp5",
|
|
12
|
+
"bluelamp6": "./bin/bluelamp6",
|
|
13
|
+
"bluelamp7": "./bin/bluelamp7",
|
|
14
|
+
"bluelamp8": "./bin/bluelamp8",
|
|
15
|
+
"bluelamp9": "./bin/bluelamp9",
|
|
16
|
+
"bluelamp10": "./bin/bluelamp10",
|
|
17
|
+
"bluelamp11": "./bin/bluelamp11",
|
|
18
|
+
"bluelamp12": "./bin/bluelamp12",
|
|
19
|
+
"bluelamp13": "./bin/bluelamp13",
|
|
20
|
+
"bluelamp14": "./bin/bluelamp14",
|
|
21
|
+
"bluelamp15": "./bin/bluelamp15",
|
|
22
|
+
"bluelamp16": "./bin/bluelamp16",
|
|
23
|
+
"bluelamp17": "./bin/bluelamp17",
|
|
24
|
+
"bluelamp18": "./bin/bluelamp18",
|
|
25
|
+
"bluelamp19": "./bin/bluelamp19",
|
|
26
|
+
"bluelamp20": "./bin/bluelamp20",
|
|
27
|
+
"bluelamp21": "./bin/bluelamp21",
|
|
28
|
+
"bluelamp22": "./bin/bluelamp22",
|
|
29
|
+
"bluelamp23": "./bin/bluelamp23",
|
|
30
|
+
"bluelamp24": "./bin/bluelamp24",
|
|
31
|
+
"bluelamp25": "./bin/bluelamp25",
|
|
32
|
+
"bluelamp26": "./bin/bluelamp26",
|
|
33
|
+
"bluelamp27": "./bin/bluelamp27",
|
|
34
|
+
"bluelamp28": "./bin/bluelamp28",
|
|
35
|
+
"bluelamp29": "./bin/bluelamp29",
|
|
36
|
+
"bluelamp30": "./bin/bluelamp30",
|
|
37
|
+
"bluelamp31": "./bin/bluelamp31",
|
|
38
|
+
"bluelamp32": "./bin/bluelamp32",
|
|
39
|
+
"bluelamp33": "./bin/bluelamp33",
|
|
40
|
+
"bluelamp34": "./bin/bluelamp34",
|
|
41
|
+
"bluelamp35": "./bin/bluelamp35",
|
|
42
|
+
"bluelamp36": "./bin/bluelamp36",
|
|
43
|
+
"bluelamp37": "./bin/bluelamp37",
|
|
44
|
+
"bluelamp38": "./bin/bluelamp38",
|
|
45
|
+
"bluelamp39": "./bin/bluelamp39",
|
|
46
|
+
"bluelamp40": "./bin/bluelamp40",
|
|
47
|
+
"bluelamp41": "./bin/bluelamp41",
|
|
48
|
+
"bluelamp42": "./bin/bluelamp42",
|
|
49
|
+
"bluelamp43": "./bin/bluelamp43",
|
|
50
|
+
"bluelamp44": "./bin/bluelamp44",
|
|
51
|
+
"bluelamp45": "./bin/bluelamp45",
|
|
52
|
+
"bluelamp46": "./bin/bluelamp46",
|
|
53
|
+
"bluelamp47": "./bin/bluelamp47",
|
|
54
|
+
"bluelamp48": "./bin/bluelamp48",
|
|
55
|
+
"bluelamp49": "./bin/bluelamp49",
|
|
56
|
+
"bluelamp50": "./bin/bluelamp50",
|
|
57
|
+
"bluelamp51": "./bin/bluelamp51",
|
|
58
|
+
"bluelamp52": "./bin/bluelamp52",
|
|
59
|
+
"bluelamp53": "./bin/bluelamp53",
|
|
60
|
+
"bluelamp54": "./bin/bluelamp54",
|
|
61
|
+
"bluelamp55": "./bin/bluelamp55",
|
|
62
|
+
"bluelamp56": "./bin/bluelamp56",
|
|
63
|
+
"bluelamp57": "./bin/bluelamp57",
|
|
64
|
+
"bluelamp58": "./bin/bluelamp58",
|
|
65
|
+
"bluelamp59": "./bin/bluelamp59",
|
|
66
|
+
"bluelamp60": "./bin/bluelamp60",
|
|
67
|
+
"bluelamp61": "./bin/bluelamp61",
|
|
68
|
+
"bluelamp62": "./bin/bluelamp62",
|
|
69
|
+
"bluelamp63": "./bin/bluelamp63",
|
|
70
|
+
"bluelamp64": "./bin/bluelamp64",
|
|
71
|
+
"bluelamp65": "./bin/bluelamp65",
|
|
72
|
+
"bluelamp66": "./bin/bluelamp66",
|
|
73
|
+
"bluelamp67": "./bin/bluelamp67",
|
|
74
|
+
"bluelamp68": "./bin/bluelamp68",
|
|
75
|
+
"bluelamp69": "./bin/bluelamp69",
|
|
76
|
+
"bluelamp70": "./bin/bluelamp70",
|
|
77
|
+
"bluelamp71": "./bin/bluelamp71",
|
|
78
|
+
"bluelamp72": "./bin/bluelamp72",
|
|
79
|
+
"bluelamp73": "./bin/bluelamp73",
|
|
80
|
+
"bluelamp74": "./bin/bluelamp74",
|
|
81
|
+
"bluelamp75": "./bin/bluelamp75",
|
|
82
|
+
"bluelamp76": "./bin/bluelamp76",
|
|
83
|
+
"bluelamp77": "./bin/bluelamp77",
|
|
84
|
+
"bluelamp78": "./bin/bluelamp78",
|
|
85
|
+
"bluelamp79": "./bin/bluelamp79",
|
|
86
|
+
"bluelamp80": "./bin/bluelamp80",
|
|
87
|
+
"bluelamp81": "./bin/bluelamp81",
|
|
88
|
+
"bluelamp82": "./bin/bluelamp82",
|
|
89
|
+
"bluelamp83": "./bin/bluelamp83",
|
|
90
|
+
"bluelamp84": "./bin/bluelamp84",
|
|
91
|
+
"bluelamp85": "./bin/bluelamp85",
|
|
92
|
+
"bluelamp86": "./bin/bluelamp86",
|
|
93
|
+
"bluelamp87": "./bin/bluelamp87",
|
|
94
|
+
"bluelamp88": "./bin/bluelamp88",
|
|
95
|
+
"bluelamp89": "./bin/bluelamp89",
|
|
96
|
+
"bluelamp90": "./bin/bluelamp90",
|
|
97
|
+
"bluelamp91": "./bin/bluelamp91",
|
|
98
|
+
"bluelamp92": "./bin/bluelamp92",
|
|
99
|
+
"bluelamp93": "./bin/bluelamp93",
|
|
100
|
+
"bluelamp94": "./bin/bluelamp94",
|
|
101
|
+
"bluelamp95": "./bin/bluelamp95",
|
|
102
|
+
"bluelamp96": "./bin/bluelamp96",
|
|
103
|
+
"bluelamp97": "./bin/bluelamp97",
|
|
104
|
+
"bluelamp98": "./bin/bluelamp98",
|
|
105
|
+
"bluelamp99": "./bin/bluelamp99",
|
|
106
|
+
"bluelamp100": "./bin/bluelamp100"
|
|
15
107
|
},
|
|
16
108
|
"keywords": [
|
|
17
109
|
"ai",
|
|
@@ -23,31 +115,17 @@
|
|
|
23
115
|
],
|
|
24
116
|
"author": "BlueLamp Team",
|
|
25
117
|
"license": "MIT",
|
|
26
|
-
"dependencies": {
|
|
27
|
-
"@modelcontextprotocol/sdk": "^1.0.0"
|
|
28
|
-
},
|
|
29
|
-
"devDependencies": {
|
|
30
|
-
"@types/node": "^18.0.0",
|
|
31
|
-
"javascript-obfuscator": "^4.1.1",
|
|
32
|
-
"terser": "^5.43.1",
|
|
33
|
-
"typescript": "^5.9.2"
|
|
34
|
-
},
|
|
35
118
|
"engines": {
|
|
36
119
|
"node": ">=18"
|
|
37
120
|
},
|
|
38
|
-
"
|
|
39
|
-
"
|
|
40
|
-
"
|
|
41
|
-
"
|
|
42
|
-
"
|
|
43
|
-
"
|
|
44
|
-
"
|
|
45
|
-
|
|
46
|
-
"scripts/",
|
|
47
|
-
"knowledge-injection/",
|
|
48
|
-
"README.md",
|
|
49
|
-
"INSTALLATION_GUIDE.md"
|
|
50
|
-
],
|
|
121
|
+
"dependencies": {
|
|
122
|
+
"@leonardo-ai/sdk": "^4.20.0",
|
|
123
|
+
"@modelcontextprotocol/sdk": "^1.0.0",
|
|
124
|
+
"jsonwebtoken": "^9.0.2",
|
|
125
|
+
"node-fetch": "^3.3.2",
|
|
126
|
+
"sharp": "^0.33.0",
|
|
127
|
+
"zod": "^3.22.4"
|
|
128
|
+
},
|
|
51
129
|
"preferGlobal": true,
|
|
52
130
|
"repository": {
|
|
53
131
|
"type": "git",
|
|
@@ -56,5 +134,11 @@
|
|
|
56
134
|
"bugs": {
|
|
57
135
|
"url": "https://github.com/bluelamp/bluelamp/issues"
|
|
58
136
|
},
|
|
59
|
-
"homepage": "https://github.com/bluelamp/bluelamp#readme"
|
|
60
|
-
|
|
137
|
+
"homepage": "https://github.com/bluelamp/bluelamp#readme",
|
|
138
|
+
"files": [
|
|
139
|
+
"bin/",
|
|
140
|
+
"lib/",
|
|
141
|
+
"config/",
|
|
142
|
+
"README.md"
|
|
143
|
+
]
|
|
144
|
+
}
|
package/INSTALLATION_GUIDE.md
DELETED
|
@@ -1,109 +0,0 @@
|
|
|
1
|
-
# 🔵 BlueLamp インストールガイド
|
|
2
|
-
|
|
3
|
-
## 📦 インストール方法
|
|
4
|
-
|
|
5
|
-
### 1. npmからのインストール(推奨)
|
|
6
|
-
```bash
|
|
7
|
-
npm install -g bluelamp
|
|
8
|
-
```
|
|
9
|
-
|
|
10
|
-
### 2. ローカルからのインストール(開発者向け)
|
|
11
|
-
```bash
|
|
12
|
-
# このディレクトリで実行
|
|
13
|
-
npm install -g .
|
|
14
|
-
```
|
|
15
|
-
|
|
16
|
-
## ✅ インストール確認
|
|
17
|
-
|
|
18
|
-
### 1. コマンドの確認
|
|
19
|
-
```bash
|
|
20
|
-
which ブルーランプ
|
|
21
|
-
# 出力例: /usr/local/bin/ブルーランプ または /opt/homebrew/bin/ブルーランプ
|
|
22
|
-
```
|
|
23
|
-
|
|
24
|
-
### 2. エージェントファイルの確認
|
|
25
|
-
```bash
|
|
26
|
-
ls ~/.claude/commands/
|
|
27
|
-
# 出力例:
|
|
28
|
-
# orchestrator.md
|
|
29
|
-
# requirements-engineer.md
|
|
30
|
-
# mockup-queen.md
|
|
31
|
-
# implementation-x.md
|
|
32
|
-
# data-modeling.md
|
|
33
|
-
# debug-agent.md
|
|
34
|
-
# prototype-queen.md
|
|
35
|
-
```
|
|
36
|
-
|
|
37
|
-
## 🚀 使用方法
|
|
38
|
-
|
|
39
|
-
### 1. BlueLamp起動
|
|
40
|
-
```bash
|
|
41
|
-
blcf
|
|
42
|
-
```
|
|
43
|
-
|
|
44
|
-
これにより以下が自動実行されます:
|
|
45
|
-
- ✅ bypassmode=true(`--dangerously-skip-permissions`)
|
|
46
|
-
- ✅ MCP Server自動起動
|
|
47
|
-
- ✅ オーケストレーターKnowledge Injection
|
|
48
|
-
- ✅ 24種類のサブエージェント利用可能
|
|
49
|
-
|
|
50
|
-
### 2. Claude Code内でのエージェント呼び出し
|
|
51
|
-
```
|
|
52
|
-
@orchestrator プロジェクトを開始したいです
|
|
53
|
-
@requirements-engineer 要件定義を作成してください
|
|
54
|
-
@mockup-queen UIデザインを作成してください
|
|
55
|
-
@implementation-x 実装計画を策定してください
|
|
56
|
-
```
|
|
57
|
-
|
|
58
|
-
## 🔧 トラブルシューティング
|
|
59
|
-
|
|
60
|
-
### Claude Codeが見つからない場合
|
|
61
|
-
```bash
|
|
62
|
-
# Claude Codeのインストール確認
|
|
63
|
-
which claude
|
|
64
|
-
|
|
65
|
-
# PATHの確認
|
|
66
|
-
echo $PATH
|
|
67
|
-
```
|
|
68
|
-
|
|
69
|
-
### エージェントが表示されない場合
|
|
70
|
-
```bash
|
|
71
|
-
# 手動でエージェントファイルを確認
|
|
72
|
-
ls ~/.claude/commands/
|
|
73
|
-
|
|
74
|
-
# 手動セットアップ実行
|
|
75
|
-
node /usr/local/lib/node_modules/bluelamp/scripts/setup-agents.js
|
|
76
|
-
```
|
|
77
|
-
|
|
78
|
-
### MCP Serverエラーの場合
|
|
79
|
-
```bash
|
|
80
|
-
# 環境変数の設定
|
|
81
|
-
export BLUELAMP_ENCRYPTION_KEY="your-encryption-key"
|
|
82
|
-
export BLUELAMP_TOKEN="your-secure-token"
|
|
83
|
-
|
|
84
|
-
# 再起動
|
|
85
|
-
blcf
|
|
86
|
-
```
|
|
87
|
-
|
|
88
|
-
## 🔄 アンインストール
|
|
89
|
-
|
|
90
|
-
```bash
|
|
91
|
-
# パッケージのアンインストール
|
|
92
|
-
npm uninstall -g bluelamp
|
|
93
|
-
|
|
94
|
-
# エージェントファイルの削除(オプション)
|
|
95
|
-
rm -rf ~/.claude/commands/
|
|
96
|
-
```
|
|
97
|
-
|
|
98
|
-
## 📋 システム要件
|
|
99
|
-
|
|
100
|
-
- **Node.js**: 18.0.0以上
|
|
101
|
-
- **Claude Code**: 最新版
|
|
102
|
-
- **OS**: macOS, Linux, Windows(WSL)
|
|
103
|
-
|
|
104
|
-
## 🆘 サポート
|
|
105
|
-
|
|
106
|
-
問題が発生した場合:
|
|
107
|
-
1. [GitHub Issues](https://github.com/bluelamp/bluelamp/issues)で報告
|
|
108
|
-
2. ログファイルの確認: `~/.claude/logs/`
|
|
109
|
-
3. 環境変数の確認: `env | grep BLUELAMP`
|
package/bin/blcf
DELETED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
const{spawn:e}=require("child_process"),o=require("path"),s=require("fs"),n=require("os"),r=o.dirname(__dirname),c=o.join(r,"lib/mcp-server/dist_optimized/secure-mcp-server.js"),l=o.join(r,"lib/mcp-server/dist_optimized/security");console.log("🔵 BlueLamp - AIエージェント統合システム"),console.log(" ポータル統合認証 + 知識注入 + 24種類のAIエージェント"),console.log(""),async function(){const t=process.argv.slice(2);if(t.includes("--logout"))try{const{InteractiveLogin:e}=await import(`file://${l}/InteractiveLogin.js`);await e.logout(),process.exit(0)}catch(e){console.error("❌ ログアウトエラー:",e.message),process.exit(1)}if(t.includes("--status"))try{const{InteractiveLogin:e}=await import(`file://${l}/InteractiveLogin.js`);await e.checkLoginStatus(),process.exit(0)}catch(e){console.error("❌ ステータス確認エラー:",e.message),process.exit(1)}!function(){const e=o.join(n.homedir(),".claude/agents"),c=o.join(e,"ブルーランプ.md");if(!s.existsSync(c)){console.log("🔧 エージェントセットアップが必要です...");try{const e=o.join(r,"scripts/setup-agents.js");require(e),console.log("✅ エージェントセットアップ完了")}catch(e){console.warn("⚠️ エージェント自動セットアップに失敗しました:",e.message),console.warn("手動でセットアップを実行してください: npm run postinstall")}}}();const i=await async function(){try{const{InteractiveLogin:e}=await import(`file://${l}/InteractiveLogin.js`);console.log("🔐 Portal認証を開始します...");const o=await e.performLogin();return e.displayLoginSuccess(o),o.token}catch(e){console.error("❌ Portal認証エラー:",e.message),console.error(""),console.error("解決方法:"),console.error("1. インターネット接続を確認してください"),console.error("2. Portal認証情報が正しいか確認してください"),console.error("3. https://geniemon.vercel.app にアクセスできるか確認してください"),process.exit(1)}}();console.log("🔒 APIキーを保存中...");const a=await async function(e){try{const{SimpleAuthManager:o}=await import(`file://${l}/SimpleAuthManager.js`);console.log("🔒 APIキーを安全に保存中...");const s=o.saveApiKey(e);return s&&(console.log("✅ APIキー保存完了"),console.log("🛡️ セキュリティレベル: 高")),{success:s,distributionTime:1}}catch(e){return console.error("❌ APIキー保存エラー:",e.message),{success:!1,error:e.message}}}(i);a.success||(console.error("❌ APIキー保存に失敗しました:",a.error),console.error("フォールバックモードで起動します...")),process.stdout.isTTY&&process.stdin.isTTY||console.warn("⚠️ TTY環境が検出されませんでした。互換モードで起動します。");const m={...process.env,BLUELAMP_ENCRYPTION_KEY:process.env.BLUELAMP_ENCRYPTION_KEY||"bluelamp-default-key-2024",BLUELAMP_TOKEN:i,BLUELAMP_DISTRIBUTED:a.success?"true":"false",NODE_ENV:"production"},p=o.join(n.tmpdir(),`bluelamp-mcp-${Date.now()}.json`),u={mcpServers:{"bluelamp-secure":{command:"node",args:[c],env:{BLUELAMP_ENCRYPTION_KEY:m.BLUELAMP_ENCRYPTION_KEY,BLUELAMP_TOKEN:m.BLUELAMP_TOKEN}}}};s.writeFileSync(p,JSON.stringify(u,null,2));const g='> オーケストレーターモードで起動\n\n🔵 BlueLamp 統合認証システム が有効化されました\n\n[34m╭─────────────────────────────────────────────────────────────────╮[0m\n[34m│ │[0m\n[34m│ B l u e L a m p │[0m\n[34m│ ───────────────── │[0m\n[34m│ さあ始めましょう │[0m\n[34m│ │[0m\n[34m╰─────────────────────────────────────────────────────────────────╯[0m\n\n**最初に必ずオーケストレーター専門知識を注入してください**\ninject_knowledge ツールで "オーケストレーター" を実行してから開始してください。(初回必須)\n\n準備完了です。まず知識注入を実行してから、何を実装するか教えてください。',d=o.join(n.tmpdir(),`bluelamp-prompt-${Date.now()}.txt`);s.writeFileSync(d,g),console.log("🚀 Claude Code起動中..."),console.log(" - Portal認証: ON"),console.log(" - 単一ファイル保存: ON"),console.log(" - bypassmode: ON (--dangerously-skip-permissions)"),console.log(" - Knowledge Injection: ON"),console.log(" - MCP Server: BlueLamp Secure"),console.log(" - TTY互換モード: ON"),console.log("");const L=e("claude",[g,"--dangerously-skip-permissions","--mcp-config",p],{stdio:"inherit",env:m,detached:!1,windowsHide:!1,shell:!1});L.on("error",e=>{console.error("❌ Claude Code起動エラー:",e.message),console.error(""),console.error("解決方法:"),console.error("1. Claude Codeがインストールされているか確認"),console.error("2. PATHにclaudeコマンドが含まれているか確認"),console.error("3. Claude Codeのバージョンが最新か確認");try{s.unlinkSync(p),s.unlinkSync(d)}catch(e){}process.exit(1)}),L.on("exit",e=>{console.log(""),console.log("🔵 BlueLamp セッション終了");try{s.unlinkSync(p),s.unlinkSync(d)}catch(e){}process.exit(e||0)}),process.on("SIGINT",()=>{console.log("\n🔵 BlueLamp を終了しています..."),L.kill("SIGINT")})}().catch(e=>{console.error("❌ 予期しないエラーが発生しました:",e.message),process.exit(1)});
|
package/bin/blcf2
DELETED
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
const{spawn:spawn}=require("child_process"),path=require("path"),fs=require("fs"),os=require("os"),packageRoot=path.dirname(__dirname),mcpServerPath=path.join(packageRoot,"lib/mcp-server/dist_optimized/secure-mcp-server.js"),securityPath=path.join(packageRoot,"lib/mcp-server/dist_optimized/security")
|
|
3
|
-
async function performPortalAuth(){try{const{createRequire:e}=require("module"),o=(e(securityPath+"/"),require(path.join(securityPath,"InteractiveLogin.js"))),s=o.InteractiveLogin||o.default||o
|
|
4
|
-
console.log("🔐 Portal認証を開始します...")
|
|
5
|
-
const r=await s.performLogin()
|
|
6
|
-
return s.displayLoginSuccess(r),r.token}catch(e){console.error("❌ Portal認証エラー:",e.message),console.error(""),console.error("解決方法:"),console.error("1. インターネット接続を確認してください"),console.error("2. Portal認証情報が正しいか確認してください"),console.error("3. https://geniemon.vercel.app にアクセスできるか確認してください"),process.exit(1)}}async function performDistributedStorage(e){try{const o=require(path.join(securityPath,"SimpleAuthManager.js")),s=o.SimpleAuthManager||o.default||o
|
|
7
|
-
console.log("🔒 APIキーを安全に保存中...")
|
|
8
|
-
const r=s.saveApiKey(e)
|
|
9
|
-
return r&&(console.log("✅ APIキー保存完了"),console.log("🛡️ セキュリティレベル: 高")),{success:r,distributionTime:1}}catch(e){return console.error("❌ APIキー保存エラー:",e.message),{success:!1,error:e.message}}}function ensureAgentsSetup(){const e=path.join(os.homedir(),".claude/agents"),o=path.join(e,"ブルーランプ.md")
|
|
10
|
-
if(!fs.existsSync(o)){console.log("🔧 エージェントセットアップが必要です...")
|
|
11
|
-
try{const e=path.join(packageRoot,"scripts/setup-agents.js")
|
|
12
|
-
require(e),console.log("✅ エージェントセットアップ完了")}catch(e){console.warn("⚠️ エージェント自動セットアップに失敗しました:",e.message),console.warn("手動でセットアップを実行してください: npm run postinstall")}}}async function main(){const e=process.argv.slice(2)
|
|
13
|
-
if(e.includes("--logout"))try{const e=require(path.join(securityPath,"InteractiveLogin.js")),o=e.InteractiveLogin||e.default||e
|
|
14
|
-
await o.logout(),process.exit(0)}catch(e){console.error("❌ ログアウトエラー:",e.message),process.exit(1)}if(e.includes("--status"))try{const e=require(path.join(securityPath,"InteractiveLogin.js")),o=e.InteractiveLogin||e.default||e
|
|
15
|
-
await o.checkLoginStatus(),process.exit(0)}catch(e){console.error("❌ ステータス確認エラー:",e.message),process.exit(1)}ensureAgentsSetup()
|
|
16
|
-
const o=await performPortalAuth()
|
|
17
|
-
console.log("🔒 APIキーを保存中...")
|
|
18
|
-
const s=await performDistributedStorage(o)
|
|
19
|
-
s.success||(console.error("❌ APIキー保存に失敗しました:",s.error),console.error("フォールバックモードで起動します..."))
|
|
20
|
-
process.stdout.isTTY&&process.stdin.isTTY||console.warn("⚠️ TTY環境が検出されませんでした。互換モードで起動します。")
|
|
21
|
-
const r={...process.env,BLUELAMP_ENCRYPTION_KEY:process.env.BLUELAMP_ENCRYPTION_KEY||"bluelamp-default-key-2024",BLUELAMP_TOKEN:o,BLUELAMP_DISTRIBUTED:s.success?"true":"false",NODE_ENV:"production"},n=path.join(os.tmpdir(),`bluelamp-mcp-${Date.now()}.json`),t={mcpServers:{"bluelamp-secure":{command:"node",args:[mcpServerPath],env:{BLUELAMP_ENCRYPTION_KEY:r.BLUELAMP_ENCRYPTION_KEY,BLUELAMP_TOKEN:r.BLUELAMP_TOKEN}}}}
|
|
22
|
-
fs.writeFileSync(n,JSON.stringify(t,null,2))
|
|
23
|
-
const c='> オーケストレーターモードで起動\n\n🔵 BlueLamp 統合認証システム が有効化されました\n\n[34m╭─────────────────────────────────────────────────────────────────╮[0m\n[34m│ │[0m\n[34m│ B l u e L a m p │[0m\n[34m│ ───────────────── │[0m\n[34m│ さあ始めましょう │[0m\n[34m│ │[0m\n[34m╰─────────────────────────────────────────────────────────────────╯[0m\n\n**最初に必ずオーケストレーター専門知識を注入してください**\ninject_knowledge ツールで "オーケストレーター" を実行してから開始してください。(初回必須)\n\n準備完了です。まず知識注入を実行してから、何を実装するか教えてください。',a=path.join(os.tmpdir(),`bluelamp-prompt-${Date.now()}.txt`)
|
|
24
|
-
fs.writeFileSync(a,c),console.log("🚀 Claude Code起動中..."),console.log(" - Portal認証: ON"),console.log(" - 単一ファイル保存: ON"),console.log(" - bypassmode: OFF (通常モード)"),console.log(" - Knowledge Injection: ON"),console.log(" - MCP Server: BlueLamp Secure"),console.log(" - TTY互換モード: ON"),console.log("")
|
|
25
|
-
const l=spawn("claude",[c,"--mcp-config",n],{stdio:"inherit",env:r,detached:!1,windowsHide:!1,shell:!1})
|
|
26
|
-
l.on("error",e=>{console.error("❌ Claude Code起動エラー:",e.message),console.error(""),console.error("解決方法:"),console.error("1. Claude Codeがインストールされているか確認"),console.error("2. PATHにclaudeコマンドが含まれているか確認"),console.error("3. Claude Codeのバージョンが最新か確認")
|
|
27
|
-
try{fs.unlinkSync(n),fs.unlinkSync(a)}catch(e){}process.exit(1)}),l.on("exit",e=>{console.log(""),console.log("🔵 BlueLamp セッション終了")
|
|
28
|
-
try{fs.unlinkSync(n),fs.unlinkSync(a)}catch(e){}process.exit(e||0)}),process.on("SIGINT",()=>{console.log("\n🔵 BlueLamp を終了しています..."),l.kill("SIGINT")})}console.log("🔵 BlueLamp - AIエージェント統合システム"),console.log(" ポータル統合認証 + 知識注入 + 24種類のAIエージェント"),console.log(""),main().catch(e=>{console.error("❌ 予期しないエラーが発生しました:",e.message),process.exit(1)})
|
package/bin/blcf3
DELETED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
const{spawn:spawn}=require("child_process"),path=require("path"),fs=require("fs"),os=require("os"),packageRoot=path.dirname(__dirname),mcpServerPath=path.join(packageRoot,"lib/mcp-server/dist/secure-mcp-server.js"),securityPath=path.join(packageRoot,"lib/mcp-server/dist/security");async function performPortalAuth(){try{const{InteractiveLogin:e}=await import(`file://${securityPath}/InteractiveLogin.js`);console.log("🔐 Portal認証を開始します...");const o=await e.performLogin();return e.displayLoginSuccess(o),o.token}catch(e){console.error("❌ Portal認証エラー:",e.message),console.error(""),console.error("解決方法:"),console.error("1. インターネット接続を確認してください"),console.error("2. Portal認証情報が正しいか確認してください"),console.error("3. https://geniemon.vercel.app にアクセスできるか確認してください"),process.exit(1)}}async function performDistributedStorage(e){try{const{SimpleAuthManager:o}=await import(`file://${securityPath}/SimpleAuthManager.js`);console.log("🔒 APIキーを安全に保存中...");const s=o.saveApiKey(e);return s&&(console.log("✅ APIキー保存完了"),console.log("🛡️ セキュリティレベル: 高")),{success:s,distributionTime:1}}catch(e){return console.error("❌ APIキー保存エラー:",e.message),{success:!1,error:e.message}}}function ensureAgentsSetup(){const e=path.join(os.homedir(),".claude/agents"),o=path.join(e,"ブルーランプ.md");if(!fs.existsSync(o)){console.log("🔧 エージェントセットアップが必要です...");try{const e=path.join(packageRoot,"scripts/setup-agents.js");require(e),console.log("✅ エージェントセットアップ完了")}catch(e){console.warn("⚠️ エージェント自動セットアップに失敗しました:",e.message),console.warn("手動でセットアップを実行してください: npm run postinstall")}}}async function main(){const e=process.argv.slice(2);if(e.includes("--logout"))try{const{InteractiveLogin:e}=await import(`file://${securityPath}/InteractiveLogin.js`);await e.logout(),process.exit(0)}catch(e){console.error("❌ ログアウトエラー:",e.message),process.exit(1)}if(e.includes("--status"))try{const{InteractiveLogin:e}=await import(`file://${securityPath}/InteractiveLogin.js`);await e.checkLoginStatus(),process.exit(0)}catch(e){console.error("❌ ステータス確認エラー:",e.message),process.exit(1)}ensureAgentsSetup();const o=await performPortalAuth();console.log("🔒 APIキーを保存中...");const s=await performDistributedStorage(o);s.success||(console.error("❌ APIキー保存に失敗しました:",s.error),console.error("フォールバックモードで起動します..."));process.stdout.isTTY&&process.stdin.isTTY||console.warn("⚠️ TTY環境が検出されませんでした。互換モードで起動します。");const n={...process.env,BLUELAMP_ENCRYPTION_KEY:process.env.BLUELAMP_ENCRYPTION_KEY||"bluelamp-default-key-2024",BLUELAMP_TOKEN:o,BLUELAMP_DISTRIBUTED:s.success?"true":"false",NODE_ENV:"production"},t=path.join(os.tmpdir(),`bluelamp-mcp-${Date.now()}.json`),c={mcpServers:{"bluelamp-secure":{command:"node",args:[mcpServerPath],env:{BLUELAMP_ENCRYPTION_KEY:n.BLUELAMP_ENCRYPTION_KEY,BLUELAMP_TOKEN:n.BLUELAMP_TOKEN}}}};fs.writeFileSync(t,JSON.stringify(c,null,2));const r='> 拡張モードで起動\n\n🔵 BlueLamp 統合認証システム が有効化されました\n\n[34m╭─────────────────────────────────────────────────────────────────╮[0m\n[34m│ │[0m\n[34m│ B l u e L a m p │[0m\n[34m│ ───────────────── │[0m\n[34m│ さあ始めましょう │[0m\n[34m│ │[0m\n[34m╰─────────────────────────────────────────────────────────────────╯[0m\n\n**最初に必ず拡張専門知識を注入してください**\ninject_knowledge ツールで "拡張" を実行してから開始してください。(初回必須)\n\n準備完了です。まず知識注入を実行してから、何を実装するか教えてください。',a=path.join(os.tmpdir(),`bluelamp-prompt-${Date.now()}.txt`);fs.writeFileSync(a,r),console.log("🚀 Claude Code起動中..."),console.log(" - Portal認証: ON"),console.log(" - 単一ファイル保存: ON"),console.log(" - bypassmode: ON (--dangerously-skip-permissions)"),console.log(" - Knowledge Injection: ON"),console.log(" - MCP Server: BlueLamp Secure"),console.log(" - TTY互換モード: ON"),console.log("");const l=spawn("claude",[r,"--dangerously-skip-permissions","--mcp-config",t],{stdio:"inherit",env:n,detached:!1,windowsHide:!1,shell:!1});l.on("error",e=>{console.error("❌ Claude Code起動エラー:",e.message),console.error(""),console.error("解決方法:"),console.error("1. Claude Codeがインストールされているか確認"),console.error("2. PATHにclaudeコマンドが含まれているか確認"),console.error("3. Claude Codeのバージョンが最新か確認");try{fs.unlinkSync(t),fs.unlinkSync(a)}catch(e){}process.exit(1)}),l.on("exit",e=>{console.log(""),console.log("🔵 BlueLamp セッション終了");try{fs.unlinkSync(t),fs.unlinkSync(a)}catch(e){}process.exit(e||0)}),process.on("SIGINT",()=>{console.log("\n🔵 BlueLamp を終了しています..."),l.kill("SIGINT")})}console.log("🔵 BlueLamp - AIエージェント統合システム"),console.log(" ポータル統合認証 + 知識注入 + 24種類のAIエージェント"),console.log(""),main().catch(e=>{console.error("❌ 予期しないエラーが発生しました:",e.message),process.exit(1)});
|
package/bin/blcf4
DELETED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
const{spawn:spawn}=require("child_process"),path=require("path"),fs=require("fs"),os=require("os"),packageRoot=path.dirname(__dirname),mcpServerPath=path.join(packageRoot,"lib/mcp-server/dist/secure-mcp-server.js"),securityPath=path.join(packageRoot,"lib/mcp-server/dist/security");async function performPortalAuth(){try{const{InteractiveLogin:e}=await import(`file://${securityPath}/InteractiveLogin.js`);console.log("🔐 Portal認証を開始します...");const o=await e.performLogin();return e.displayLoginSuccess(o),o.token}catch(e){console.error("❌ Portal認証エラー:",e.message),console.error(""),console.error("解決方法:"),console.error("1. インターネット接続を確認してください"),console.error("2. Portal認証情報が正しいか確認してください"),console.error("3. https://geniemon.vercel.app にアクセスできるか確認してください"),process.exit(1)}}async function performDistributedStorage(e){try{const{SimpleAuthManager:o}=await import(`file://${securityPath}/SimpleAuthManager.js`);console.log("🔒 APIキーを安全に保存中...");const s=o.saveApiKey(e);return s&&(console.log("✅ APIキー保存完了"),console.log("🛡️ セキュリティレベル: 高")),{success:s,distributionTime:1}}catch(e){return console.error("❌ APIキー保存エラー:",e.message),{success:!1,error:e.message}}}function ensureAgentsSetup(){const e=path.join(os.homedir(),".claude/agents"),o=path.join(e,"ブルーランプ.md");if(!fs.existsSync(o)){console.log("🔧 エージェントセットアップが必要です...");try{const e=path.join(packageRoot,"scripts/setup-agents.js");require(e),console.log("✅ エージェントセットアップ完了")}catch(e){console.warn("⚠️ エージェント自動セットアップに失敗しました:",e.message),console.warn("手動でセットアップを実行してください: npm run postinstall")}}}async function main(){const e=process.argv.slice(2);if(e.includes("--logout"))try{const{InteractiveLogin:e}=await import(`file://${securityPath}/InteractiveLogin.js`);await e.logout(),process.exit(0)}catch(e){console.error("❌ ログアウトエラー:",e.message),process.exit(1)}if(e.includes("--status"))try{const{InteractiveLogin:e}=await import(`file://${securityPath}/InteractiveLogin.js`);await e.checkLoginStatus(),process.exit(0)}catch(e){console.error("❌ ステータス確認エラー:",e.message),process.exit(1)}ensureAgentsSetup();const o=await performPortalAuth();console.log("🔒 APIキーを保存中...");const s=await performDistributedStorage(o);s.success||(console.error("❌ APIキー保存に失敗しました:",s.error),console.error("フォールバックモードで起動します..."));process.stdout.isTTY&&process.stdin.isTTY||console.warn("⚠️ TTY環境が検出されませんでした。互換モードで起動します。");const t={...process.env,BLUELAMP_ENCRYPTION_KEY:process.env.BLUELAMP_ENCRYPTION_KEY||"bluelamp-default-key-2024",BLUELAMP_TOKEN:o,BLUELAMP_DISTRIBUTED:s.success?"true":"false",NODE_ENV:"production"},c=path.join(os.tmpdir(),`bluelamp-mcp-${Date.now()}.json`),n={mcpServers:{"bluelamp-secure":{command:"node",args:[mcpServerPath],env:{BLUELAMP_ENCRYPTION_KEY:t.BLUELAMP_ENCRYPTION_KEY,BLUELAMP_TOKEN:t.BLUELAMP_TOKEN}}}};fs.writeFileSync(c,JSON.stringify(n,null,2));const r='> 拡張モードで起動\n\n🔵 BlueLamp 統合認証システム が有効化されました\n\n[34m╭─────────────────────────────────────────────────────────────────╮[0m\n[34m│ │[0m\n[34m│ B l u e L a m p │[0m\n[34m│ ───────────────── │[0m\n[34m│ さあ始めましょう │[0m\n[34m│ │[0m\n[34m╰─────────────────────────────────────────────────────────────────╯[0m\n\n**最初に必ず拡張専門知識を注入してください**\ninject_knowledge ツールで "拡張" を実行してから開始してください。(初回必須)\n\n準備完了です。まず知識注入を実行してから、何を実装するか教えてください。',a=path.join(os.tmpdir(),`bluelamp-prompt-${Date.now()}.txt`);fs.writeFileSync(a,r),console.log("🚀 Claude Code起動中..."),console.log(" - Portal認証: ON"),console.log(" - 単一ファイル保存: ON"),console.log(" - bypassmode: OFF (通常モード)"),console.log(" - Knowledge Injection: ON"),console.log(" - MCP Server: BlueLamp Secure"),console.log(" - TTY互換モード: ON"),console.log("");const l=spawn("claude",[r,"--mcp-config",c],{stdio:"inherit",env:t,detached:!1,windowsHide:!1,shell:!1});l.on("error",e=>{console.error("❌ Claude Code起動エラー:",e.message),console.error(""),console.error("解決方法:"),console.error("1. Claude Codeがインストールされているか確認"),console.error("2. PATHにclaudeコマンドが含まれているか確認"),console.error("3. Claude Codeのバージョンが最新か確認");try{fs.unlinkSync(c),fs.unlinkSync(a)}catch(e){}process.exit(1)}),l.on("exit",e=>{console.log(""),console.log("🔵 BlueLamp セッション終了");try{fs.unlinkSync(c),fs.unlinkSync(a)}catch(e){}process.exit(e||0)}),process.on("SIGINT",()=>{console.log("\n🔵 BlueLamp を終了しています..."),l.kill("SIGINT")})}console.log("🔵 BlueLamp - AIエージェント統合システム"),console.log(" ポータル統合認証 + 知識注入 + 24種類のAIエージェント"),console.log(""),main().catch(e=>{console.error("❌ 予期しないエラーが発生しました:",e.message),process.exit(1)});
|