Commit 35c6e74f authored by Volker Krause's avatar Volker Krause
Browse files

Extend CHR decoding

Looks like we need to consider all these values for (sub)CA key lookup.
parent 75cd0e80
...@@ -48,7 +48,7 @@ VdvCertificate::VdvCertificate(const QByteArray &data, int offset) ...@@ -48,7 +48,7 @@ VdvCertificate::VdvCertificate(const QByteArray &data, int offset)
} }
qDebug() << "car:" << QByteArray(certKey()->car.region, 2) << QByteArray(certKey()->car.name, 3); qDebug() << "car:" << QByteArray(certKey()->car.region, 2) << QByteArray(certKey()->car.name, 3);
qDebug() << "chr:" << QByteArray(certKey()->chr.name, 5); qDebug() << "chr:" << QByteArray(certKey()->chr.name, 5) << certKey()->chr.algorithmReference << certKey()->chr.year;
qDebug() << "cha:" << QByteArray(certKey()->cha.name, 6); qDebug() << "cha:" << QByteArray(certKey()->cha.name, 6);
qDebug() << "modulus:" << modulusSize() << *modulus() << *(modulus() + modulusSize() - 1); qDebug() << "modulus:" << modulusSize() << *modulus() << *(modulus() + modulusSize() - 1);
qDebug() << "exponent:" << exponentSize() << *exponent() << *(exponent() + exponentSize() - 1); qDebug() << "exponent:" << exponentSize() << *exponent() << *(exponent() + exponentSize() - 1);
......
...@@ -159,7 +159,10 @@ struct VdvCaReferenceBlock : public VdvSimpleDataBlock<uint8_t, TagCaReference> ...@@ -159,7 +159,10 @@ struct VdvCaReferenceBlock : public VdvSimpleDataBlock<uint8_t, TagCaReference>
struct VdvCertificateHolderReference { struct VdvCertificateHolderReference {
uint8_t filler[4]; // always null uint8_t filler[4]; // always null
char name[5]; char name[5];
uint8_t extension[3]; uint8_t serviceIndicator: 4;
uint8_t discretionaryData: 4;
uint8_t algorithmReference;
uint8_t year;
}; };
/** Certificate Holder Authorization (CHA) */ /** Certificate Holder Authorization (CHA) */
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment