@interopio/iocd-cli 0.0.1

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.
Files changed (297) hide show
  1. package/README.md +40 -0
  2. package/dist/cli.d.ts +3 -0
  3. package/dist/cli.d.ts.map +1 -0
  4. package/dist/cli.js +96 -0
  5. package/dist/cli.js.map +1 -0
  6. package/dist/commands/apps.command.d.ts +3 -0
  7. package/dist/commands/apps.command.d.ts.map +1 -0
  8. package/dist/commands/apps.command.js +110 -0
  9. package/dist/commands/apps.command.js.map +1 -0
  10. package/dist/commands/components.command.d.ts +3 -0
  11. package/dist/commands/components.command.d.ts.map +1 -0
  12. package/dist/commands/components.command.js +116 -0
  13. package/dist/commands/components.command.js.map +1 -0
  14. package/dist/commands/create.command.d.ts +3 -0
  15. package/dist/commands/create.command.d.ts.map +1 -0
  16. package/dist/commands/create.command.js +19 -0
  17. package/dist/commands/create.command.js.map +1 -0
  18. package/dist/commands/dev.command.d.ts +4 -0
  19. package/dist/commands/dev.command.d.ts.map +1 -0
  20. package/dist/commands/dev.command.js +25 -0
  21. package/dist/commands/dev.command.js.map +1 -0
  22. package/dist/commands/installer.command.d.ts +3 -0
  23. package/dist/commands/installer.command.d.ts.map +1 -0
  24. package/dist/commands/installer.command.js +19 -0
  25. package/dist/commands/installer.command.js.map +1 -0
  26. package/dist/commands/license.command.d.ts +3 -0
  27. package/dist/commands/license.command.d.ts.map +1 -0
  28. package/dist/commands/license.command.js +23 -0
  29. package/dist/commands/license.command.js.map +1 -0
  30. package/dist/commands/modifications.command.d.ts +3 -0
  31. package/dist/commands/modifications.command.d.ts.map +1 -0
  32. package/dist/commands/modifications.command.js +28 -0
  33. package/dist/commands/modifications.command.js.map +1 -0
  34. package/dist/commands/setup.command.d.ts +4 -0
  35. package/dist/commands/setup.command.d.ts.map +1 -0
  36. package/dist/commands/setup.command.js +34 -0
  37. package/dist/commands/setup.command.js.map +1 -0
  38. package/dist/services/app-builder.service.d.ts +2 -0
  39. package/dist/services/app-builder.service.d.ts.map +1 -0
  40. package/dist/services/app-builder.service.js +3 -0
  41. package/dist/services/app-builder.service.js.map +1 -0
  42. package/dist/services/app.service.d.ts +74 -0
  43. package/dist/services/app.service.d.ts.map +1 -0
  44. package/dist/services/app.service.js +328 -0
  45. package/dist/services/app.service.js.map +1 -0
  46. package/dist/services/components/component.config.d.ts +11 -0
  47. package/dist/services/components/component.config.d.ts.map +1 -0
  48. package/dist/services/components/component.config.js +101 -0
  49. package/dist/services/components/component.config.js.map +1 -0
  50. package/dist/services/components/component.d.ts +12 -0
  51. package/dist/services/components/component.d.ts.map +1 -0
  52. package/dist/services/components/component.js +3 -0
  53. package/dist/services/components/component.js.map +1 -0
  54. package/dist/services/components/components.registry.d.ts +40 -0
  55. package/dist/services/components/components.registry.d.ts.map +1 -0
  56. package/dist/services/components/components.registry.js +72 -0
  57. package/dist/services/components/components.registry.js.map +1 -0
  58. package/dist/services/components/components.service.d.ts +20 -0
  59. package/dist/services/components/components.service.d.ts.map +1 -0
  60. package/dist/services/components/components.service.js +171 -0
  61. package/dist/services/components/components.service.js.map +1 -0
  62. package/dist/services/components/file.helper.d.ts +12 -0
  63. package/dist/services/components/file.helper.d.ts.map +1 -0
  64. package/dist/services/components/file.helper.js +124 -0
  65. package/dist/services/components/file.helper.js.map +1 -0
  66. package/dist/services/components/platform.utils.d.ts +72 -0
  67. package/dist/services/components/platform.utils.d.ts.map +1 -0
  68. package/dist/services/components/platform.utils.js +156 -0
  69. package/dist/services/components/platform.utils.js.map +1 -0
  70. package/dist/services/components/stores/github.store.d.ts +35 -0
  71. package/dist/services/components/stores/github.store.d.ts.map +1 -0
  72. package/dist/services/components/stores/github.store.js +157 -0
  73. package/dist/services/components/stores/github.store.js.map +1 -0
  74. package/dist/services/components/stores/local.store.d.ts +69 -0
  75. package/dist/services/components/stores/local.store.d.ts.map +1 -0
  76. package/dist/services/components/stores/local.store.js +300 -0
  77. package/dist/services/components/stores/local.store.js.map +1 -0
  78. package/dist/services/components/stores/s3.store.d.ts +98 -0
  79. package/dist/services/components/stores/s3.store.d.ts.map +1 -0
  80. package/dist/services/components/stores/s3.store.js +368 -0
  81. package/dist/services/components/stores/s3.store.js.map +1 -0
  82. package/dist/services/components/stores/store.d.ts +11 -0
  83. package/dist/services/components/stores/store.d.ts.map +1 -0
  84. package/dist/services/components/stores/store.js +3 -0
  85. package/dist/services/components/stores/store.js.map +1 -0
  86. package/dist/services/config/cli.config.d.ts +57 -0
  87. package/dist/services/config/cli.config.d.ts.map +1 -0
  88. package/dist/services/config/cli.config.js +3 -0
  89. package/dist/services/config/cli.config.js.map +1 -0
  90. package/dist/services/config/config.service.d.ts +14 -0
  91. package/dist/services/config/config.service.d.ts.map +1 -0
  92. package/dist/services/config/config.service.js +170 -0
  93. package/dist/services/config/config.service.js.map +1 -0
  94. package/dist/services/create.service.d.ts +58 -0
  95. package/dist/services/create.service.d.ts.map +1 -0
  96. package/dist/services/create.service.js +318 -0
  97. package/dist/services/create.service.js.map +1 -0
  98. package/dist/services/dev.service.d.ts +2 -0
  99. package/dist/services/dev.service.d.ts.map +1 -0
  100. package/dist/services/dev.service.js +78 -0
  101. package/dist/services/dev.service.js.map +1 -0
  102. package/dist/services/installer/electronBuilder.d.ts +2 -0
  103. package/dist/services/installer/electronBuilder.d.ts.map +1 -0
  104. package/dist/services/installer/electronBuilder.js +3 -0
  105. package/dist/services/installer/electronBuilder.js.map +1 -0
  106. package/dist/services/installer/electronForge.d.ts +2 -0
  107. package/dist/services/installer/electronForge.d.ts.map +1 -0
  108. package/dist/services/installer/electronForge.js +248 -0
  109. package/dist/services/installer/electronForge.js.map +1 -0
  110. package/dist/services/installer/installer.service.d.ts +5 -0
  111. package/dist/services/installer/installer.service.d.ts.map +1 -0
  112. package/dist/services/installer/installer.service.js +101 -0
  113. package/dist/services/installer/installer.service.js.map +1 -0
  114. package/dist/services/installer/macOS.helper.d.ts +3 -0
  115. package/dist/services/installer/macOS.helper.d.ts.map +1 -0
  116. package/dist/services/installer/macOS.helper.js +244 -0
  117. package/dist/services/installer/macOS.helper.js.map +1 -0
  118. package/dist/services/installer/prerequisites.d.ts +2 -0
  119. package/dist/services/installer/prerequisites.d.ts.map +1 -0
  120. package/dist/services/installer/prerequisites.js +73 -0
  121. package/dist/services/installer/prerequisites.js.map +1 -0
  122. package/dist/services/installer/windows.helper.d.ts +10 -0
  123. package/dist/services/installer/windows.helper.d.ts.map +1 -0
  124. package/dist/services/installer/windows.helper.js +394 -0
  125. package/dist/services/installer/windows.helper.js.map +1 -0
  126. package/dist/services/license.service.d.ts +7 -0
  127. package/dist/services/license.service.d.ts.map +1 -0
  128. package/dist/services/license.service.js +14 -0
  129. package/dist/services/license.service.js.map +1 -0
  130. package/dist/services/modifications/macOS.helper.d.ts +13 -0
  131. package/dist/services/modifications/macOS.helper.d.ts.map +1 -0
  132. package/dist/services/modifications/macOS.helper.js +274 -0
  133. package/dist/services/modifications/macOS.helper.js.map +1 -0
  134. package/dist/services/modifications/modifications.service.d.ts +2 -0
  135. package/dist/services/modifications/modifications.service.d.ts.map +1 -0
  136. package/dist/services/modifications/modifications.service.js +376 -0
  137. package/dist/services/modifications/modifications.service.js.map +1 -0
  138. package/dist/services/modifications/windows.helper.d.ts +2 -0
  139. package/dist/services/modifications/windows.helper.d.ts.map +1 -0
  140. package/dist/services/modifications/windows.helper.js +83 -0
  141. package/dist/services/modifications/windows.helper.js.map +1 -0
  142. package/dist/services/template.service.d.ts +116 -0
  143. package/dist/services/template.service.d.ts.map +1 -0
  144. package/dist/services/template.service.js +354 -0
  145. package/dist/services/template.service.js.map +1 -0
  146. package/dist/templates/auto-tests/README.md +31 -0
  147. package/dist/templates/auto-tests/playwright.config.js +19 -0
  148. package/dist/templates/auto-tests/template.json +12 -0
  149. package/dist/templates/auto-tests/tests/basic.test.js +15 -0
  150. package/dist/templates/ioconnect-desktop/.env.example +29 -0
  151. package/dist/templates/ioconnect-desktop/.github/workflows/build-installers.yml +170 -0
  152. package/dist/templates/ioconnect-desktop/LICENSE +0 -0
  153. package/dist/templates/ioconnect-desktop/README.md +0 -0
  154. package/dist/templates/ioconnect-desktop/config/mac-build/entitlements.mac.plist +44 -0
  155. package/dist/templates/ioconnect-desktop/config/win-build/template.nuspectemplate +33 -0
  156. package/dist/templates/ioconnect-desktop/forge.config.js +47 -0
  157. package/dist/templates/ioconnect-desktop/iocd.cli.config.json +45 -0
  158. package/dist/templates/ioconnect-desktop/modifications/iocd/assets/images/logo.icns +0 -0
  159. package/dist/templates/ioconnect-desktop/modifications/iocd/assets/images/logo.ico +0 -0
  160. package/dist/templates/ioconnect-desktop/modifications/iocd/assets/images/logo.png +0 -0
  161. package/dist/templates/ioconnect-desktop/modifications/iocd/config/system.json.merge +3 -0
  162. package/dist/templates/ioconnect-desktop/package.json +43 -0
  163. package/dist/templates/ioconnect-desktop/template.json +7 -0
  164. package/dist/templates/launchpad/apps/launchpad/.eslintrc.json +3 -0
  165. package/dist/templates/launchpad/apps/launchpad/config/iocd.app.def.dev.json +57 -0
  166. package/dist/templates/launchpad/apps/launchpad/config/iocd.app.def.prod.json +2 -0
  167. package/dist/templates/launchpad/apps/launchpad/config/iocd.system.dev.json +3 -0
  168. package/dist/templates/launchpad/apps/launchpad/config/iocd.system.prod.json +3 -0
  169. package/dist/templates/launchpad/apps/launchpad/index.html +16 -0
  170. package/dist/templates/launchpad/apps/launchpad/iocd.app.json +32 -0
  171. package/dist/templates/launchpad/apps/launchpad/package-lock.json +2778 -0
  172. package/dist/templates/launchpad/apps/launchpad/package.json +21 -0
  173. package/dist/templates/launchpad/apps/launchpad/public/favicon.ico +0 -0
  174. package/dist/templates/launchpad/apps/launchpad/src/app/app.tsx +39 -0
  175. package/dist/templates/launchpad/apps/launchpad/src/app/constants.ts +27 -0
  176. package/dist/templates/launchpad/apps/launchpad/src/components/logo.tsx +11 -0
  177. package/dist/templates/launchpad/apps/launchpad/src/components/main-context-menu.tsx +162 -0
  178. package/dist/templates/launchpad/apps/launchpad/src/components/notifications-button.tsx +44 -0
  179. package/dist/templates/launchpad/apps/launchpad/src/main.tsx +6 -0
  180. package/dist/templates/launchpad/apps/launchpad/src/styles.css +17 -0
  181. package/dist/templates/launchpad/apps/launchpad/tsconfig.json +10 -0
  182. package/dist/templates/launchpad/apps/launchpad/vite.config.ts +13 -0
  183. package/dist/templates/launchpad/template.json +12 -0
  184. package/dist/templates/splash-screen/apps/splash-screen/README.md +119 -0
  185. package/dist/templates/splash-screen/apps/splash-screen/config/system-dev.json +9 -0
  186. package/dist/templates/splash-screen/apps/splash-screen/config/system-prod.json +8 -0
  187. package/dist/templates/splash-screen/apps/splash-screen/index.html +55 -0
  188. package/dist/templates/splash-screen/apps/splash-screen/iocd.app.json +20 -0
  189. package/dist/templates/splash-screen/apps/splash-screen/package-lock.json +1059 -0
  190. package/dist/templates/splash-screen/apps/splash-screen/package.json +17 -0
  191. package/dist/templates/splash-screen/apps/splash-screen/public/assets/fonts/PTSans-Regular.ttf +0 -0
  192. package/dist/templates/splash-screen/apps/splash-screen/public/assets/images/logo-light.svg +85 -0
  193. package/dist/templates/splash-screen/apps/splash-screen/public/assets/images/splash-bg.png +0 -0
  194. package/dist/templates/splash-screen/apps/splash-screen/public/assets/styles/style.css +149 -0
  195. package/dist/templates/splash-screen/apps/splash-screen/public/assets/styles/style.css.map +1 -0
  196. package/dist/templates/splash-screen/apps/splash-screen/public/assets/styles/style.scss +90 -0
  197. package/dist/templates/splash-screen/apps/splash-screen/src/main.ts +93 -0
  198. package/dist/templates/splash-screen/apps/splash-screen/src/types.ts +28 -0
  199. package/dist/templates/splash-screen/apps/splash-screen/tsconfig.json +25 -0
  200. package/dist/templates/splash-screen/apps/splash-screen/vite.config.ts +27 -0
  201. package/dist/templates/splash-screen/template.json +12 -0
  202. package/dist/templates/web-groups/apps/web-groups/README.md +15 -0
  203. package/dist/templates/web-groups/apps/web-groups/config/web-group-dev.json +13 -0
  204. package/dist/templates/web-groups/apps/web-groups/config/web-group-prod.json +12 -0
  205. package/dist/templates/web-groups/apps/web-groups/index.html +18 -0
  206. package/dist/templates/web-groups/apps/web-groups/iocd.app.json +24 -0
  207. package/dist/templates/web-groups/apps/web-groups/package.json +28 -0
  208. package/dist/templates/web-groups/apps/web-groups/public/favicon.ico +0 -0
  209. package/dist/templates/web-groups/apps/web-groups/public/logo192.png +0 -0
  210. package/dist/templates/web-groups/apps/web-groups/public/logo512.png +0 -0
  211. package/dist/templates/web-groups/apps/web-groups/public/manifest.json +25 -0
  212. package/dist/templates/web-groups/apps/web-groups/public/robots.txt +3 -0
  213. package/dist/templates/web-groups/apps/web-groups/src/App.css +38 -0
  214. package/dist/templates/web-groups/apps/web-groups/src/App.tsx +11 -0
  215. package/dist/templates/web-groups/apps/web-groups/src/index.css +13 -0
  216. package/dist/templates/web-groups/apps/web-groups/src/index.tsx +25 -0
  217. package/dist/templates/web-groups/apps/web-groups/src/logo.svg +1 -0
  218. package/dist/templates/web-groups/apps/web-groups/src/reportWebVitals.ts +15 -0
  219. package/dist/templates/web-groups/apps/web-groups/tsconfig.json +26 -0
  220. package/dist/templates/web-groups/apps/web-groups/vite.config.ts +8 -0
  221. package/dist/templates/web-groups/template.json +12 -0
  222. package/dist/templates/workspaces/apps/workspaces/README.md +15 -0
  223. package/dist/templates/workspaces/apps/workspaces/config/workspaces-dev.json +21 -0
  224. package/dist/templates/workspaces/apps/workspaces/config/workspaces-prod.json +20 -0
  225. package/dist/templates/workspaces/apps/workspaces/index.html +17 -0
  226. package/dist/templates/workspaces/apps/workspaces/iocd.app.json +24 -0
  227. package/dist/templates/workspaces/apps/workspaces/package.json +29 -0
  228. package/dist/templates/workspaces/apps/workspaces/public/favicon.ico +0 -0
  229. package/dist/templates/workspaces/apps/workspaces/public/logo192.png +0 -0
  230. package/dist/templates/workspaces/apps/workspaces/public/logo512.png +0 -0
  231. package/dist/templates/workspaces/apps/workspaces/public/manifest.json +25 -0
  232. package/dist/templates/workspaces/apps/workspaces/public/robots.txt +3 -0
  233. package/dist/templates/workspaces/apps/workspaces/src/AddWindowButton.tsx +33 -0
  234. package/dist/templates/workspaces/apps/workspaces/src/AfterTabs.tsx +27 -0
  235. package/dist/templates/workspaces/apps/workspaces/src/App.css +38 -0
  236. package/dist/templates/workspaces/apps/workspaces/src/App.tsx +103 -0
  237. package/dist/templates/workspaces/apps/workspaces/src/GroupHeaderButtons.tsx +9 -0
  238. package/dist/templates/workspaces/apps/workspaces/src/index.css +4 -0
  239. package/dist/templates/workspaces/apps/workspaces/src/index.tsx +28 -0
  240. package/dist/templates/workspaces/apps/workspaces/src/logo.svg +7 -0
  241. package/dist/templates/workspaces/apps/workspaces/src/reportWebVitals.ts +15 -0
  242. package/dist/templates/workspaces/apps/workspaces/src/setupTests.ts +5 -0
  243. package/dist/templates/workspaces/apps/workspaces/src/useAddWindowButtonVisible.tsx +30 -0
  244. package/dist/templates/workspaces/apps/workspaces/tsconfig.json +26 -0
  245. package/dist/templates/workspaces/apps/workspaces/vite.config.ts +8 -0
  246. package/dist/templates/workspaces/template.json +12 -0
  247. package/dist/tools/rcedit-x64.exe +0 -0
  248. package/dist/utils/colors.d.ts +57 -0
  249. package/dist/utils/colors.d.ts.map +1 -0
  250. package/dist/utils/colors.js +151 -0
  251. package/dist/utils/colors.js.map +1 -0
  252. package/dist/utils/deep.merge.d.ts +5 -0
  253. package/dist/utils/deep.merge.d.ts.map +1 -0
  254. package/dist/utils/deep.merge.js +27 -0
  255. package/dist/utils/deep.merge.js.map +1 -0
  256. package/dist/utils/electron.builder.config.helper.d.ts +6 -0
  257. package/dist/utils/electron.builder.config.helper.d.ts.map +1 -0
  258. package/dist/utils/electron.builder.config.helper.js +25 -0
  259. package/dist/utils/electron.builder.config.helper.js.map +1 -0
  260. package/dist/utils/ensure.iocd.exists.d.ts +2 -0
  261. package/dist/utils/ensure.iocd.exists.d.ts.map +1 -0
  262. package/dist/utils/ensure.iocd.exists.js +27 -0
  263. package/dist/utils/ensure.iocd.exists.js.map +1 -0
  264. package/dist/utils/error.handler.d.ts +30 -0
  265. package/dist/utils/error.handler.d.ts.map +1 -0
  266. package/dist/utils/error.handler.js +104 -0
  267. package/dist/utils/error.handler.js.map +1 -0
  268. package/dist/utils/file.d.ts +10 -0
  269. package/dist/utils/file.d.ts.map +1 -0
  270. package/dist/utils/file.js +40 -0
  271. package/dist/utils/file.js.map +1 -0
  272. package/dist/utils/find.package.dir.d.ts +2 -0
  273. package/dist/utils/find.package.dir.d.ts.map +1 -0
  274. package/dist/utils/find.package.dir.js +23 -0
  275. package/dist/utils/find.package.dir.js.map +1 -0
  276. package/dist/utils/logger.d.ts +19 -0
  277. package/dist/utils/logger.d.ts.map +1 -0
  278. package/dist/utils/logger.js +184 -0
  279. package/dist/utils/logger.js.map +1 -0
  280. package/dist/utils/nextSteps.d.ts +2 -0
  281. package/dist/utils/nextSteps.d.ts.map +1 -0
  282. package/dist/utils/nextSteps.js +44 -0
  283. package/dist/utils/nextSteps.js.map +1 -0
  284. package/dist/utils/pacakge.json.helper.d.ts +9 -0
  285. package/dist/utils/pacakge.json.helper.d.ts.map +1 -0
  286. package/dist/utils/pacakge.json.helper.js +71 -0
  287. package/dist/utils/pacakge.json.helper.js.map +1 -0
  288. package/dist/utils/path.d.ts +19 -0
  289. package/dist/utils/path.d.ts.map +1 -0
  290. package/dist/utils/path.js +81 -0
  291. package/dist/utils/path.js.map +1 -0
  292. package/dist/utils/version.d.ts +2 -0
  293. package/dist/utils/version.d.ts.map +1 -0
  294. package/dist/utils/version.js +16 -0
  295. package/dist/utils/version.js.map +1 -0
  296. package/package.json +69 -0
  297. package/tools/rcedit-x64.exe +0 -0
@@ -0,0 +1,394 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.signBinary = signBinary;
7
+ exports.signIOCDBinaries = signIOCDBinaries;
8
+ exports.signWithSmctl = signWithSmctl;
9
+ exports.detectSigningCapabilities = detectSigningCapabilities;
10
+ const logger_1 = require("../../utils/logger");
11
+ const config_service_1 = require("../config/config.service");
12
+ const path_1 = require("../../utils/path");
13
+ const child_process_1 = require("child_process");
14
+ const fs_1 = require("fs");
15
+ const path_2 = __importDefault(require("path"));
16
+ const logger = logger_1.Logger.getInstance();
17
+ const signableExtensions = ['.exe', '.dll', '.ocx', '.sys', '.node'];
18
+ async function signBinary(binaryPath) {
19
+ logger.debug(`Signing binary: ${path_2.default.basename(binaryPath)}`);
20
+ if (!(0, fs_1.existsSync)(binaryPath)) {
21
+ throw new Error(`Executable not found at path: ${binaryPath}`);
22
+ }
23
+ const config = config_service_1.ConfigManager.config;
24
+ const codeSignConfig = config.win.codeSign;
25
+ if (codeSignConfig.type === 'off') {
26
+ logger.info('Code signing is disabled (type: off)');
27
+ return;
28
+ }
29
+ const ext = path_2.default.extname(binaryPath).toLowerCase();
30
+ if (!signableExtensions.includes(ext)) {
31
+ logger.debug(`File extension ${ext} is not signable. Skipping signing for: ${binaryPath}`);
32
+ return;
33
+ }
34
+ await signBinaryCore(binaryPath, codeSignConfig);
35
+ await verifySignature(binaryPath);
36
+ logger.debug(`Successfully signed: ${path_2.default.basename(binaryPath)}`);
37
+ }
38
+ async function signIOCDBinaries() {
39
+ logger.info('Starting signing of all Windows binaries...');
40
+ const config = config_service_1.ConfigManager.config;
41
+ const codeSignConfig = config.win.codeSign;
42
+ if (codeSignConfig.type === 'off') {
43
+ logger.info('Code signing is disabled (type: off)');
44
+ return;
45
+ }
46
+ storeUnsignedExeIfNeeded();
47
+ try {
48
+ const iocdDir = path_1.PathUtils.getIOCDDir();
49
+ const binariesToSign = await findSignableBinaries(iocdDir);
50
+ if (binariesToSign.length === 0) {
51
+ logger.info('No signable binaries found');
52
+ return;
53
+ }
54
+ logger.info(`Signing ${binariesToSign.length} binaries...`);
55
+ for (const binaryPath of binariesToSign) {
56
+ await signBinaryCore(binaryPath, codeSignConfig);
57
+ }
58
+ logger.info('Signing binaries completed successfully!');
59
+ }
60
+ catch (error) {
61
+ logger.error(`Batch signing failed: ${error instanceof Error ? error.message : String(error)}`);
62
+ throw error;
63
+ }
64
+ }
65
+ function storeUnsignedExeIfNeeded() {
66
+ // we store the original unsigned exe, because rcedits can be done on unsigned exe only.
67
+ // this means that if we do rcedit->sign, we can not longer do rcedit without breaking the signature
68
+ // to overcome this we are storing the original exe in a _temp folder and restore it before any modifications
69
+ // see restoreOriginalUnsignedExeIfNeeded in modifications/windows.helper.ts for restore logic
70
+ const tempDir = path_1.PathUtils.getComponentDir("_temp");
71
+ const tempExePath = path_2.default.join(tempDir, path_2.default.basename(path_1.PathUtils.getIOCDExePath()));
72
+ if (!(0, fs_1.existsSync)(tempDir)) {
73
+ (0, fs_1.mkdirSync)(tempDir);
74
+ }
75
+ if (!(0, fs_1.existsSync)(tempExePath)) {
76
+ logger.debug('Storing current executable into _temp directory before signing. Will restore before next modifications');
77
+ (0, fs_1.copyFileSync)(path_1.PathUtils.getIOCDExePath(), tempExePath);
78
+ }
79
+ }
80
+ async function findSignableBinaries(directory) {
81
+ const binaries = [];
82
+ // Common files that should NOT be signed
83
+ const skipFiles = [
84
+ 'msvcp140.dll',
85
+ 'vcruntime140.dll',
86
+ 'vcruntime140_1.dll',
87
+ 'msvcp140_1.dll',
88
+ 'msvcp140_2.dll',
89
+ 'api-ms-win-*.dll',
90
+ 'ucrtbase.dll'
91
+ ];
92
+ function scanDirectory(dir) {
93
+ try {
94
+ if (!(0, fs_1.existsSync)(dir))
95
+ return;
96
+ const files = (0, fs_1.readdirSync)(dir);
97
+ for (const file of files) {
98
+ const fullPath = path_2.default.join(dir, file);
99
+ const stat = (0, fs_1.statSync)(fullPath);
100
+ if (stat.isDirectory()) {
101
+ // Recursively scan subdirectories
102
+ scanDirectory(fullPath);
103
+ }
104
+ else if (stat.isFile()) {
105
+ const ext = path_2.default.extname(file).toLowerCase();
106
+ const basename = path_2.default.basename(file).toLowerCase();
107
+ // Check if it's a signable extension
108
+ if (signableExtensions.includes(ext)) {
109
+ // Skip system files and runtime libraries
110
+ const shouldSkip = skipFiles.some(skipPattern => {
111
+ if (skipPattern.includes('*')) {
112
+ // Simple wildcard matching
113
+ const regex = new RegExp('^' + skipPattern.replace(/\*/g, '.*') + '$', 'i');
114
+ return regex.test(basename);
115
+ }
116
+ return basename === skipPattern.toLowerCase();
117
+ });
118
+ if (!shouldSkip) {
119
+ binaries.push(fullPath);
120
+ }
121
+ }
122
+ }
123
+ }
124
+ }
125
+ catch (error) {
126
+ logger.debug(`Could not scan directory ${dir}: ${error instanceof Error ? error.message : String(error)}`);
127
+ }
128
+ }
129
+ scanDirectory(directory);
130
+ return binaries;
131
+ }
132
+ async function signBinaryCore(binaryPath, codeSignConfig) {
133
+ switch (codeSignConfig.type) {
134
+ case "off":
135
+ // do nothing
136
+ break;
137
+ case 'pfx':
138
+ await signWithPfx(binaryPath, codeSignConfig);
139
+ break;
140
+ case 'wincert':
141
+ await signWithWinCert(binaryPath, codeSignConfig);
142
+ break;
143
+ case 'smime':
144
+ await signWithSmime(binaryPath, codeSignConfig);
145
+ break;
146
+ case 'smctl':
147
+ await signWithSmctl(binaryPath);
148
+ break;
149
+ case 'custom':
150
+ await signWithCustomScript(binaryPath, codeSignConfig);
151
+ break;
152
+ default:
153
+ throw new Error(`Unsupported code signing type: ${codeSignConfig.type}`);
154
+ }
155
+ }
156
+ async function signWithPfx(exePath, codeSignConfig) {
157
+ logger.debug('Signing with PFX certificate...');
158
+ if (!codeSignConfig.pfxPath) {
159
+ throw new Error('PFX signing requires pfxPath to be configured');
160
+ }
161
+ if (!(0, fs_1.existsSync)(codeSignConfig.pfxPath)) {
162
+ throw new Error(`PFX file not found: ${codeSignConfig.pfxPath}`);
163
+ }
164
+ const args = [
165
+ 'sign',
166
+ // "/debug",
167
+ '/fd', 'SHA256',
168
+ '/td', 'SHA256',
169
+ '/tr', config_service_1.ConfigManager.config.win.codeSign.tsaURL,
170
+ '/f', codeSignConfig.pfxPath
171
+ ];
172
+ if (codeSignConfig.pfxPassword) {
173
+ args.push('/p', codeSignConfig.pfxPassword);
174
+ }
175
+ args.push(exePath);
176
+ await runSigntool(args);
177
+ }
178
+ async function signWithWinCert(exePath, codeSignConfig) {
179
+ logger.debug('Signing with Windows Certificate Store...');
180
+ if (!codeSignConfig.wincertSubjectName) {
181
+ throw new Error('Windows Certificate Store signing requires wincertSubjectName to be configured');
182
+ }
183
+ const args = [
184
+ 'sign',
185
+ '/fd', 'SHA256',
186
+ '/td', 'SHA256',
187
+ '/tr', config_service_1.ConfigManager.config.win.codeSign.tsaURL,
188
+ '/n', codeSignConfig.wincertSubjectName,
189
+ exePath
190
+ ];
191
+ await runSigntool(args);
192
+ }
193
+ async function signWithSmime(exePath, codeSignConfig) {
194
+ logger.debug('Signing with S/MIME certificate...');
195
+ if (!codeSignConfig.smimeCertificatePath) {
196
+ throw new Error('S/MIME signing requires smimeCertificatePath to be configured');
197
+ }
198
+ if (!(0, fs_1.existsSync)(codeSignConfig.smimeCertificatePath)) {
199
+ throw new Error(`S/MIME certificate file not found: ${codeSignConfig.smimeCertificatePath}`);
200
+ }
201
+ const args = [
202
+ 'sign',
203
+ '/fd', 'SHA256',
204
+ '/td', 'SHA256',
205
+ '/tr', config_service_1.ConfigManager.config.win.codeSign.tsaURL,
206
+ '/f', codeSignConfig.smimeCertificatePath
207
+ ];
208
+ if (codeSignConfig.smimeCertificatePassword) {
209
+ args.push('/p', codeSignConfig.smimeCertificatePassword);
210
+ }
211
+ args.push(exePath);
212
+ await runSigntool(args);
213
+ }
214
+ async function signWithSmctl(exePath) {
215
+ logger.debug('Signing with DigiCert smctl (KeyLocker)...');
216
+ const requiredEnvVars = ['SM_API_KEY', 'SM_CLIENT_CERT_FILE', 'SM_CLIENT_CERT_PASSWORD', 'SM_CODE_SIGNING_CERT_SHA1_HASH'];
217
+ const missingVars = requiredEnvVars.filter(varName => !process.env[varName]);
218
+ if (missingVars.length > 0) {
219
+ throw new Error(`DigiCert smctl signing requires the following environment variables: ${missingVars.join(', ')}`);
220
+ }
221
+ try {
222
+ // First, authenticate with DigiCert KeyLocker
223
+ await runCommand('smctl', ['windows', 'certsync'], {
224
+ env: {
225
+ ...process.env,
226
+ SM_API_KEY: process.env['SM_API_KEY'],
227
+ SM_CLIENT_CERT_FILE: process.env['SM_CLIENT_CERT_FILE'],
228
+ SM_CLIENT_CERT_PASSWORD: process.env['SM_CLIENT_CERT_PASSWORD']
229
+ }
230
+ });
231
+ // Then sign the binary
232
+ const args = [
233
+ 'sign',
234
+ '--keypair-alias', process.env['SM_CODE_SIGNING_CERT_SHA1_HASH'],
235
+ '--certificate', process.env['SM_CLIENT_CERT_FILE'],
236
+ '--config-file', process.env['SM_CLIENT_CERT_FILE'],
237
+ '--input', exePath
238
+ ].filter((arg) => arg !== undefined);
239
+ await runCommand('smctl', args, {
240
+ env: {
241
+ ...process.env,
242
+ SM_API_KEY: process.env['SM_API_KEY'],
243
+ SM_CLIENT_CERT_FILE: process.env['SM_CLIENT_CERT_FILE'],
244
+ SM_CLIENT_CERT_PASSWORD: process.env['SM_CLIENT_CERT_PASSWORD']
245
+ }
246
+ });
247
+ logger.debug('DigiCert smctl signing completed successfully!');
248
+ }
249
+ catch (error) {
250
+ throw new Error(`DigiCert smctl signing failed: ${error instanceof Error ? error.message : String(error)}`);
251
+ }
252
+ }
253
+ async function detectSigningCapabilities() {
254
+ logger.debug('Detecting available code signing tools...');
255
+ const result = {
256
+ hasSigntool: false,
257
+ hasSmctl: false,
258
+ sdkPath: undefined,
259
+ recommendations: []
260
+ };
261
+ // Check for signtool in PATH
262
+ try {
263
+ await runCommand('signtool', ['/?']);
264
+ result.hasSigntool = true;
265
+ logger.debug('signtool found in PATH');
266
+ }
267
+ catch (error) {
268
+ // Try common Windows SDK locations
269
+ const sdkPaths = [
270
+ 'C:\\Program Files (x86)\\Windows Kits\\10\\bin\\x64\\signtool.exe',
271
+ 'C:\\Program Files (x86)\\Windows Kits\\10\\bin\\x86\\signtool.exe',
272
+ 'C:\\Program Files\\Microsoft SDKs\\Windows\\v7.1\\Bin\\signtool.exe',
273
+ 'C:\\Program Files (x86)\\Microsoft SDKs\\Windows\\v7.1A\\Bin\\signtool.exe'
274
+ ];
275
+ for (const sdkPath of sdkPaths) {
276
+ if ((0, fs_1.existsSync)(sdkPath)) {
277
+ result.hasSigntool = true;
278
+ result.sdkPath = sdkPath;
279
+ logger.debug(`signtool found at: ${sdkPath}`);
280
+ break;
281
+ }
282
+ }
283
+ }
284
+ // Check for DigiCert smctl
285
+ try {
286
+ await runCommand('smctl', ['--version']);
287
+ result.hasSmctl = true;
288
+ logger.debug('DigiCert smctl found');
289
+ }
290
+ catch (error) {
291
+ result.recommendations.push('Install DigiCert smctl for cloud-based signing: https://docs.digicert.com/en/software-trust-manager/tools/smctl.html');
292
+ }
293
+ if (!result.hasSigntool) {
294
+ result.recommendations.push('Install Windows SDK for signtool: https://developer.microsoft.com/en-us/windows/downloads/windows-sdk/');
295
+ }
296
+ return result;
297
+ }
298
+ async function signWithCustomScript(exePath, codeSignConfig) {
299
+ logger.debug('Signing with custom script...');
300
+ if (!codeSignConfig.customCodeSignScriptPath) {
301
+ throw new Error('Custom signing requires customCodeSignScriptPath to be configured');
302
+ }
303
+ if (!(0, fs_1.existsSync)(codeSignConfig.customCodeSignScriptPath)) {
304
+ throw new Error(`Custom signing script not found: ${codeSignConfig.customCodeSignScriptPath}`);
305
+ }
306
+ logger.debug(`Loading and executing custom signing script: ${codeSignConfig.customCodeSignScriptPath}`);
307
+ try {
308
+ // Resolve the absolute path for the require
309
+ const scriptPath = path_2.default.resolve(codeSignConfig.customCodeSignScriptPath);
310
+ // Clear require cache to ensure fresh execution
311
+ delete require.cache[scriptPath];
312
+ // Require the script module
313
+ const customScript = require(scriptPath);
314
+ // Check if the module exports a function (default export or named export)
315
+ let signFunction;
316
+ if (typeof customScript === 'function') {
317
+ signFunction = customScript;
318
+ }
319
+ else if (typeof customScript.default === 'function') {
320
+ signFunction = customScript.default;
321
+ }
322
+ else if (typeof customScript.sign === 'function') {
323
+ signFunction = customScript.sign;
324
+ }
325
+ else {
326
+ throw new Error('Custom signing script must export a function (either as default export, named "sign" export, or direct export)');
327
+ }
328
+ // Execute the signing function with the binary path and full config
329
+ await signFunction(exePath, codeSignConfig);
330
+ logger.debug('Custom signing script executed successfully');
331
+ }
332
+ catch (error) {
333
+ if (error instanceof Error) {
334
+ throw new Error(`Custom signing script failed: ${error.message}`);
335
+ }
336
+ else {
337
+ throw new Error(`Custom signing script failed: ${String(error)}`);
338
+ }
339
+ }
340
+ }
341
+ async function runSigntool(args) {
342
+ await runCommand('signtool', args);
343
+ }
344
+ async function verifySignature(exePath) {
345
+ logger.debug(`Verifying signature for: ${exePath}`);
346
+ try {
347
+ await runSigntool(['verify', '/pa', '/all', exePath]);
348
+ logger.debug('Signature verification successful');
349
+ }
350
+ catch (error) {
351
+ logger.warn(`Signature verification failed! The binary at ${exePath} may not be signed correctly.`);
352
+ }
353
+ }
354
+ async function runCommand(command, args, options = {}) {
355
+ return new Promise((resolve, reject) => {
356
+ logger.debug(`Executing: ${command} ${args.join(' ')}`);
357
+ const process = (0, child_process_1.spawn)(command, args, {
358
+ stdio: ['ignore', 'pipe', 'pipe'],
359
+ ...options
360
+ });
361
+ let stdout = '';
362
+ let stderr = '';
363
+ if (process.stdout) {
364
+ process.stdout.on('data', (data) => {
365
+ stdout += data.toString();
366
+ });
367
+ }
368
+ if (process.stderr) {
369
+ process.stderr.on('data', (data) => {
370
+ stderr += data.toString();
371
+ });
372
+ }
373
+ process.on('close', (code) => {
374
+ if (code === 0) {
375
+ if (stdout)
376
+ logger.debug(`Command output: ${stdout.trim()}`);
377
+ resolve();
378
+ }
379
+ else {
380
+ const errorMessage = `Command failed with exit code ${code}`;
381
+ if (stderr)
382
+ logger.error(`${stderr.trim()}`);
383
+ if (stdout)
384
+ logger.debug(`${stdout.trim()}`);
385
+ reject(new Error(errorMessage));
386
+ }
387
+ });
388
+ process.on('error', (error) => {
389
+ logger.error(`Failed to start command: ${error.message}`);
390
+ reject(error);
391
+ });
392
+ });
393
+ }
394
+ //# sourceMappingURL=windows.helper.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"windows.helper.js","sourceRoot":"","sources":["../../../src/services/installer/windows.helper.ts"],"names":[],"mappings":";;;;;AAUA,gCAuBC;AAED,4CAiCC;AA8KD,sCA4CC;AAED,8DAqDC;AArVD,+CAA4C;AAC5C,6DAAyD;AACzD,2CAA6C;AAC7C,iDAAsC;AACtC,2BAAgF;AAChF,gDAAwB;AAExB,MAAM,MAAM,GAAG,eAAM,CAAC,WAAW,EAAE,CAAC;AACpC,MAAM,kBAAkB,GAAG,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,OAAO,CAAC,CAAC;AAE9D,KAAK,UAAU,UAAU,CAAC,UAAkB;IAE/C,MAAM,CAAC,KAAK,CAAC,mBAAmB,cAAI,CAAC,QAAQ,CAAC,UAAU,CAAC,EAAE,CAAC,CAAC;IAC7D,IAAI,CAAC,IAAA,eAAU,EAAC,UAAU,CAAC,EAAE,CAAC;QAC1B,MAAM,IAAI,KAAK,CAAC,iCAAiC,UAAU,EAAE,CAAC,CAAC;IACnE,CAAC;IAED,MAAM,MAAM,GAAG,8BAAa,CAAC,MAAM,CAAC;IACpC,MAAM,cAAc,GAAG,MAAM,CAAC,GAAG,CAAC,QAAQ,CAAC;IAC3C,IAAI,cAAc,CAAC,IAAI,KAAK,KAAK,EAAE,CAAC;QAChC,MAAM,CAAC,IAAI,CAAC,sCAAsC,CAAC,CAAC;QACpD,OAAO;IACX,CAAC;IAED,MAAM,GAAG,GAAG,cAAI,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC,WAAW,EAAE,CAAC;IACnD,IAAI,CAAC,kBAAkB,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;QACpC,MAAM,CAAC,KAAK,CAAC,kBAAkB,GAAG,2CAA2C,UAAU,EAAE,CAAC,CAAC;QA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AAC,CAAC,CAAC;QACP,CAAC;QAED,IAAI,OAAO,CAAC,MAAM,EAAE,CAAC;YACjB,OAAO,CAAC,MAAM,CAAC,EAAE,CAAC,MAAM,EAAE,CAAC,IAAI,EAAE,EAAE;gBAC/B,MAAM,IAAI,IAAI,CAAC,QAAQ,EAAE,CAAC;YAC9B,CAAC,CAAC,CAAC;QACP,CAAC;QAED,OAAO,CAAC,EAAE,CAAC,OAAO,EAAE,CAAC,IAAI,EAAE,EAAE;YACzB,IAAI,IAAI,KAAK,CAAC,EAAE,CAAC;gBACb,IAAI,MAAM;oBAAE,MAAM,CAAC,KAAK,CAAC,mBAAmB,MAAM,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC;gBAC7D,OAAO,EAAE,CAAC;YACd,CAAC;iBAAM,CAAC;gBACJ,MAAM,YAAY,GAAG,iCAAiC,IAAI,EAAE,CAAC;gBAC7D,IAAI,MAAM;oBAAE,MAAM,CAAC,KAAK,CAAC,GAAG,MAAM,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC;gBAC7C,IAAI,MAAM;oBAAE,MAAM,CAAC,KAAK,CAAC,GAAG,MAAM,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC;gBAC7C,MAAM,CAAC,IAAI,KAAK,CAAC,YAAY,CAAC,CAAC,CAAC;YACpC,CAAC;QACL,CAAC,CAAC,CAAC;QAEH,OAAO,CAAC,EAAE,CAAC,OAAO,EAAE,CAAC,KAAK,EAAE,EAAE;YAC1B,MAAM,CAAC,KAAK,CAAC,4BAA4B,KAAK,CAAC,OAAO,EAAE,CAAC,CAAC;YAC1D,MAAM,CAAC,KAAK,CAAC,CAAC;QAClB,CAAC,CAAC,CAAC;IACP,CAAC,CAAC,CAAC;AACP,CAAC"}
@@ -0,0 +1,7 @@
1
+ declare class LicenseService {
2
+ hasValidLicense(): boolean;
3
+ getLicenseInfo(): string;
4
+ }
5
+ declare const _default: LicenseService;
6
+ export default _default;
7
+ //# sourceMappingURL=license.service.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"license.service.d.ts","sourceRoot":"","sources":["../../src/services/license.service.ts"],"names":[],"mappings":"AAAA,cAAM,cAAc;IAEhB,eAAe,IAAI,OAAO;IAK1B,cAAc,IAAI,MAAM;CAI3B;;AAED,wBAAoC"}
@@ -0,0 +1,14 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ class LicenseService {
4
+ hasValidLicense() {
5
+ // Placeholder for actual license validation logic
6
+ return true;
7
+ }
8
+ getLicenseInfo() {
9
+ // Placeholder for actual license information retrieval
10
+ return "Valid license found.";
11
+ }
12
+ }
13
+ exports.default = new LicenseService();
14
+ //# sourceMappingURL=license.service.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"license.service.js","sourceRoot":"","sources":["../../src/services/license.service.ts"],"names":[],"mappings":";;AAAA,MAAM,cAAc;IAEhB,eAAe;QACX,kDAAkD;QAClD,OAAO,IAAI,CAAC;IAChB,CAAC;IAED,cAAc;QACV,uDAAuD;QACvD,OAAO,sBAAsB,CAAC;IAClC,CAAC;CACJ;AAED,kBAAe,IAAI,cAAc,EAAE,CAAC"}
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Renames an app bundle contents (not the bundle itself) to a new base name. This means
3
+ * - Updating the executable name inside as well
4
+ * - Updating the Info.plist file accordingly
5
+ * - Updating all Electron Helper apps in Contents/Frameworks to match the new base name (bundle name + executable + plist)
6
+ * - Copies the logo.icns file from Contents/assets/images to Contents/Resources
7
+ *
8
+ * @param appBundlePath Absolute path to YourApp.app
9
+ * @param newBaseName Desired base name (e.g., "JPM Connect")
10
+ *
11
+ */
12
+ export declare function renameAppBundleContents(appBundlePath: string, newBaseName: string): Promise<void>;
13
+ //# sourceMappingURL=macOS.helper.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"macOS.helper.d.ts","sourceRoot":"","sources":["../../../src/services/modifications/macOS.helper.ts"],"names":[],"mappings":"AASA;;;;;;;;;;GAUG;AACH,wBAAsB,uBAAuB,CAAC,aAAa,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,iBASvF"}