You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
"clone a EM410x ID to a T55x7, Q5/T5555 or EM4305/4469 tag.",
678
+
"clone a EM410x ID to a T55x7, Q5/T5555, EM4305/4469 or Hitag S/8211 tag.",
679
679
"lf em 410x clone --id 0F0368568B -> encode for T55x7 tag\n"
680
680
"lf em 410x clone --id 0F0368568B --q5 -> encode for Q5/T5555 tag\n"
681
681
"lf em 410x clone --id 0F0368568B --em -> encode for EM4305/4469\n"
@@ -710,9 +710,15 @@ static int CmdEM410xClone(const char *Cmd) {
710
710
returnPM3_EINVARG;
711
711
}
712
712
713
-
if (hs&&IfPm3Hitag() == false) {
714
-
PrintAndLogEx(FAILED, "Device not compiled to support Hitag");
715
-
returnPM3_EINVARG;
713
+
if (hs) {
714
+
if (IfPm3Hitag() == false) {
715
+
PrintAndLogEx(FAILED, "Device not compiled to support Hitag");
716
+
returnPM3_EINVARG;
717
+
}
718
+
if (clk==40) {
719
+
PrintAndLogEx(FAILED, "supported clock rates for Hitag are "_YELLOW_("16, 32, 64"));
720
+
returnPM3_EINVARG;
721
+
}
716
722
}
717
723
718
724
// Allowed clock rates: 16, 32, 40 and 64
@@ -722,31 +728,14 @@ static int CmdEM410xClone(const char *Cmd) {
722
728
}
723
729
724
730
uint64_tid=bytes_to_num(uid, uid_len);
725
-
PrintAndLogEx(SUCCESS, "Preparing to clone EM4102 to "_YELLOW_("%s") " tag with EM Tag ID "_GREEN_("%010"PRIX64) " (RF/%d)", q5 ? "Q5/T5555" : (em ? "EM4305/4469" : "T55x7"), id, clk);
726
-
727
-
struct {
728
-
boolQ5;
729
-
boolEM;
730
-
booladd_electra;
731
-
uint8_tclock;
732
-
uint32_thigh;
733
-
uint32_tlow;
734
-
} PACKEDpayload;
735
-
736
-
payload.Q5=q5;
737
-
payload.EM=em;
738
-
payload.add_electra=add_electra;
739
-
payload.clock=clk;
740
-
payload.high= (uint32_t)(id >> 32);
741
-
payload.low= (uint32_t)id;
742
-
743
-
744
-
uint8_tdata[8] = {0xFF, 0x80}; // EM410X_HEADER 9 bits of one
731
+
PrintAndLogEx(SUCCESS, "Preparing to clone EM4102 to "_YELLOW_("%s") " tag with EM Tag ID "_GREEN_("%010"PRIX64) " (RF/%d)",
0 commit comments