Skip to content

Commit

Permalink
Merge remote-tracking branch 'mntm/dev' into feat/use-after-free-sent…
Browse files Browse the repository at this point in the history
…inel
  • Loading branch information
Willy-JL committed Dec 10, 2024
2 parents 6485d7f + 88a474f commit 3e6128e
Show file tree
Hide file tree
Showing 16 changed files with 812 additions and 497 deletions.
11 changes: 10 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
- Apps:
- Games: Pinball0 (by @rdefeo)
- NFC: Metroflip (by @luu176)
- UL: Sub-GHz: Jolly Motors support with add manually (by @pkooiman & @xMasterX)
- OFW: Add VCP break support (by @gsurkov)

### Updated:
- Apps:
Expand All @@ -20,10 +22,17 @@
- WebCrawler: Improved progress display, added connectivity check on startup (by @jamisonderek)
- UL: NFC Magic: Added possibility to write 7b MFC to Gen1 tags (by @mishamyte)
- UL: Fixed apps for firmware USB CDC callback changes (by @xMasterX)
- NFC:
- OFW: Replace mf_classic_dict.nfc with Proxmark3 version (by @onovy)
- OFW: More station IDs for Clipper plugin (by @ted-logan)
- OFW: Infrared: Add IR command for NAD DR2 D7050 D3020 (by @nikos9742)

### Fixed:
- Desktop: Fixed Wardriving animation design (by @Davim09)
- OFW: GPIO: Merged gsurkov/vcp_break_support branch for usb uart bridge (WIP!!!)
- OFW: GPIO: Fix USB UART Bridge Crash by increasing system stack size (by @Astrrra)
- NFC:
- OFW: Plantain parser Last payment amount fix (by @mxcdoam)
- OFW: Fix typo for mf_classic_key_cahce_get_next_key() function (by @luu176)

### Removed:
- Nothing
13 changes: 13 additions & 0 deletions applications/main/infrared/resources/infrared/assets/audio.ir
Original file line number Diff line number Diff line change
Expand Up @@ -5810,3 +5810,16 @@ type: parsed
protocol: NECext
address: 7F 01 00 00
command: 69 96 00 00
#
name: Next
type: parsed
protocol: NECext
address: 87 7C 00 00
command: 1A E5 00 00
#
name: Prev
type: parsed
protocol: NECext
address: 87 7C 00 00
command: 1D E2 00 00
#
2 changes: 1 addition & 1 deletion applications/main/nfc/helpers/mf_classic_key_cache.c
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ void mf_classic_key_cache_load_from_data(MfClassicKeyCache* instance, const MfCl
}
}

bool mf_classic_key_cahce_get_next_key(
bool mf_classic_key_cache_get_next_key(
MfClassicKeyCache* instance,
uint8_t* sector_num,
MfClassicKey* key,
Expand Down
2 changes: 1 addition & 1 deletion applications/main/nfc/helpers/mf_classic_key_cache.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ bool mf_classic_key_cache_load(MfClassicKeyCache* instance, const uint8_t* uid,

void mf_classic_key_cache_load_from_data(MfClassicKeyCache* instance, const MfClassicData* data);

bool mf_classic_key_cahce_get_next_key(
bool mf_classic_key_cache_get_next_key(
MfClassicKeyCache* instance,
uint8_t* sector_num,
MfClassicKey* key,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ static NfcCommand nfc_scene_read_poller_callback_mf_classic(NfcGenericEvent even
uint8_t sector_num = 0;
MfClassicKey key = {};
MfClassicKeyType key_type = MfClassicKeyTypeA;
if(mf_classic_key_cahce_get_next_key(
if(mf_classic_key_cache_get_next_key(
instance->mfc_key_cache, &sector_num, &key, &key_type)) {
mfc_event->data->read_sector_request_data.sector_num = sector_num;
mfc_event->data->read_sector_request_data.key = key;
Expand Down
6 changes: 5 additions & 1 deletion applications/main/nfc/plugins/supported_cards/clipper.c
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,8 @@ static const IdMapping bart_zones[] = {
{.id = 0x001d, .name = "Lake Merrit"},
{.id = 0x001e, .name = "Fruitvale"},
{.id = 0x001f, .name = "Coliseum"},
{.id = 0x0021, .name = "San Leandro"},
{.id = 0x0020, .name = "San Leandro"},
{.id = 0x0021, .name = "Bay Fair"},
{.id = 0x0022, .name = "Hayward"},
{.id = 0x0023, .name = "South Hayward"},
{.id = 0x0024, .name = "Union City"},
Expand Down Expand Up @@ -132,6 +133,9 @@ static const IdMapping muni_zones[] = {
{.id = 0x000b, .name = "Castro"},
{.id = 0x000c, .name = "Forest Hill"}, // Guessed
{.id = 0x000d, .name = "West Portal"},
{.id = 0x0019, .name = "Union Square/Market Street"},
{.id = 0x001a, .name = "Chinatown - Rose Pak"},
{.id = 0x001b, .name = "Yerba Buena/Moscone"},
};
static const size_t kNumMUNIZones = COUNT(muni_zones);

Expand Down
16 changes: 10 additions & 6 deletions applications/main/nfc/plugins/supported_cards/plantain.c
Original file line number Diff line number Diff line change
Expand Up @@ -310,9 +310,11 @@ static bool plantain_parse(const NfcDevice* device, FuriString* parsed_data) {
last_payment_date.year,
last_payment_date.hour,
last_payment_date.minute);
//payment amount. This needs to be investigated more, currently it shows incorrect amount on some cards.
uint16_t last_payment = (data->block[18].data[9] << 8) | data->block[18].data[8];
furi_string_cat_printf(parsed_data, "Amount: %d rub", last_payment / 100);
//Last payment amount.
uint16_t last_payment = ((data->block[18].data[10] << 16) |
(data->block[18].data[9] << 8) | (data->block[18].data[8])) /
100;
furi_string_cat_printf(parsed_data, "Amount: %d rub", last_payment);
furi_string_free(card_number_s);
furi_string_free(tmp_s);
//This is for 4K Plantains.
Expand Down Expand Up @@ -369,9 +371,11 @@ static bool plantain_parse(const NfcDevice* device, FuriString* parsed_data) {
last_payment_date.year,
last_payment_date.hour,
last_payment_date.minute);
//payment amount
uint16_t last_payment = (data->block[18].data[9] << 8) | data->block[18].data[8];
furi_string_cat_printf(parsed_data, "Amount: %d rub", last_payment / 100);
//Last payment amount
uint16_t last_payment = ((data->block[18].data[10] << 16) |
(data->block[18].data[9] << 8) | (data->block[18].data[8])) /
100;
furi_string_cat_printf(parsed_data, "Amount: %d rub", last_payment);
furi_string_free(card_number_s);
furi_string_free(tmp_s);
}
Expand Down
Loading

0 comments on commit 3e6128e

Please sign in to comment.