Skip to content

Commit

Permalink
Merge pull request RfidResearchGroup#2407 from tweathers-sec/tweather…
Browse files Browse the repository at this point in the history
…s-sec

Updated clone and sim handling for 48-Bit HID (C1k48s)
  • Loading branch information
iceman1001 authored Jun 19, 2024
2 parents 2a31079 + f80e8d0 commit 57c54f3
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions client/src/wiegand_formatutils.c
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,10 @@ bool add_HID_header(wiegand_message_t *data) {
if (data->Length > 84 || data->Length == 0)
return false;

if (data->Length == 48) {
data->Mid |= 1U << (data->Length - 32); // Example leading 1: start bit
return true;
}
if (data->Length >= 64) {
data->Top |= 0x09e00000; // Extended-length header
data->Top |= 1U << (data->Length - 64); // leading 1: start bit
Expand Down

0 comments on commit 57c54f3

Please sign in to comment.