Skip to content

Commit 02237f3

Browse files
committed
Make Android cert script resilient to pre-existing htk-ca-copy directory
Unclear how this could happen, perhaps a failed/interrupted setup, or a race condition? Regardless, this should handle it more cleanly.
1 parent ea982aa commit 02237f3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/interceptors/android/adb-commands.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -236,7 +236,7 @@ export async function injectSystemCertificate(
236236
237237
# Create a separate temp directory, to hold the current certificates
238238
# Without this, when we add the mount we can't read the current certs anymore.
239-
mkdir -m 700 /data/local/tmp/htk-ca-copy
239+
mkdir -p -m 700 /data/local/tmp/htk-ca-copy
240240
241241
# Copy out the existing certificates
242242
cp /system/etc/security/cacerts/* /data/local/tmp/htk-ca-copy/

0 commit comments

Comments
 (0)