Skip to content

Commit 18b4e3f

Browse files
committed
Handle long OID nodes.
This will behave differently on 32bit architectures, but since 32bit is mostly dead and I don't see a way how to handle this w/o breaking ABI&API, I guess we have to live with it. Signed-off-by: Steffen Jaeckel <s@jaeckel.eu>
1 parent c00b006 commit 18b4e3f

File tree

2 files changed

+1
-2
lines changed

2 files changed

+1
-2
lines changed

src/pk/asn1/der/object_identifier/der_encode_object_identifier.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ int der_encode_object_identifier(const unsigned long *words, unsigned long nwor
5959
wordbuf = words[0] * 40 + words[1];
6060
for (i = 1; i < nwords; i++) {
6161
/* store 7 bit words in little endian */
62-
t = wordbuf & 0xFFFFFFFF;
62+
t = wordbuf;
6363
if (t) {
6464
y = x;
6565
mask = 0;

src/pk/asn1/der/object_identifier/der_length_object_identifier.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
unsigned long der_object_identifier_bits(unsigned long x)
1313
{
1414
unsigned long c;
15-
x &= 0xFFFFFFFF;
1615
c = 0;
1716
while (x) {
1817
++c;

0 commit comments

Comments
 (0)