Commit 6928f67
authored
Remove any combination of CR/LF line endings when reading private key from PEM
RFC 7468 permits LF, CR or CRLF line endings in PEM files.
Current code first removes LF (\n) and then tries to remove CRLF (\r\n), so the CR (\n) characters are left in the file and key Base64 cannot be decoded. Because of this private key files generated/saved on Windows with CRLF line endings cannot be loaded into library.1 parent d651388 commit 6928f67
File tree
1 file changed
+2
-2
lines changed- src/main/java/com/mastercard/developer/utils
1 file changed
+2
-2
lines changedLines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
64 | 64 | | |
65 | 65 | | |
66 | 66 | | |
67 | | - | |
| 67 | + | |
68 | 68 | | |
69 | 69 | | |
70 | 70 | | |
| |||
73 | 73 | | |
74 | 74 | | |
75 | 75 | | |
76 | | - | |
| 76 | + | |
77 | 77 | | |
78 | 78 | | |
79 | 79 | | |
| |||
0 commit comments