Skip to content

Commit f1616a1

Browse files
committed
Use new commands to generate certs without a CA
Signed-off-by: worksofliam <[email protected]>
1 parent 5848916 commit f1616a1

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

src/api/debug/certificates.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -113,11 +113,9 @@ export async function setup(connection: IBMi) {
113113
}
114114

115115
const commands = [
116-
`openssl genrsa -out debug_service_ca.key 2048`,
117-
`openssl req -x509 -new -nodes -key debug_service_ca.key -sha256 -days 1825 -out debug_service_ca.pem -subj '/CN=${host}'`,
118116
`openssl genrsa -out debug_service.key 2048`,
119117
`openssl req -new -key debug_service.key -out debug_service.csr -subj '/CN=${host}'`,
120-
`openssl x509 -req -in debug_service.csr -CA debug_service_ca.pem -CAkey debug_service_ca.key -CAcreateserial -out debug_service.crt -days 1095 -sha256 -sha256 -req -extfile <(printf "${extFileContent}")`,
118+
`openssl x509 -req -in debug_service.csr -signkey debug_service.key -out debug_service.crt -days 1095 -sha256 -sha256 -req -extfile <(printf "${extFileContent}")`,
121119
`openssl pkcs12 -export -out debug_service.pfx -inkey debug_service.key -in debug_service.crt -password pass:${host}`
122120
];
123121

src/api/debug/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -505,7 +505,7 @@ export async function startDebug(instance: Instance, options: DebugOptions) {
505505
"host": connection!.currentHost,
506506
"port": port,
507507
"secure": secure, // Enforce secure mode
508-
"ignoreCertificateErrors": !secure,
508+
"ignoreCertificateErrors": true,
509509
"library": options.library.toUpperCase(),
510510
"program": options.object.toUpperCase(),
511511
"startBatchJobCommand": `SBMJOB CMD(${currentCommand}) INLLIBL(${options.libraries.libraryList.join(` `)}) CURLIB(${options.libraries.currentLibrary}) JOBQ(QSYSNOMAX) MSGQ(*USRPRF)`,

0 commit comments

Comments
 (0)