Created
January 4, 2023 22:19
-
-
Save williamcroberts/80f37b1772b61a975214cc5c03cbf06a to your computer and use it in GitHub Desktop.
systemd patch
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
wcrobert@wcrobert-mobl1:~/workspace/systemd$ git diff | |
diff --git a/src/cryptenroll/cryptenroll-tpm2.c b/src/cryptenroll/cryptenroll-tpm2.c | |
index bd60b79e42a7..cce04e6c4496 100644 | |
--- a/src/cryptenroll/cryptenroll-tpm2.c | |
+++ b/src/cryptenroll/cryptenroll-tpm2.c | |
@@ -174,6 +174,7 @@ int enroll_tpm2(struct crypt_device *cd, | |
/* re-stringify pin_str */ | |
// Question: r is in int but base64mem returns ssize_t, this was copied | |
// from enroll_fido2 from line 56. | |
+ erase_and_freep(pin_str); | |
r = base64mem(salted_pin, sizeof(salted_pin), &pin_str); | |
if (r < 0) | |
return log_error_errno(r, "Failed to base64 encode salted pin: %m"); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment