SlideShare uma empresa Scribd logo
1 de 46
Baixar para ler offline
N	
  F	
  C	
  
Naked	
  Fried	
  Chicken
Matteo	
  Beccaro ||	
  May	
  18th,	
  2016
Me	
  ||
§ Matteo	
  Beccaro
§ Founder &	
  Chief	
  Technology	
  Officer	
  at	
  Opposing	
  Force
§ The	
  first	
  Italian	
  company	
  specialize	
  in	
  offensive	
  physical	
  security
§ Twitter:	
  @_bughardy_	
  |	
  @_opposingforce
Agenda	
  ||
§ NFC:	
  what	
  are	
  we	
  talking	
  about?
§ Modern	
  ticketing	
  systems	
  security
§ Weapons	
  for	
  NFC-­‐based	
  solutions	
  mass	
  destruction
§ Penetration	
  testing	
  methodology
§ Case	
  studies
Agenda	
  ||
§ NFC:	
  what	
  are	
  we	
  talking	
  about?
§ Modern	
  ticketing	
  systems	
  security
§ Weapons	
  for	
  NFC-­‐based	
  solutions	
  mass	
  destruction
§ Penetration	
  testing	
  methodology
§ Case	
  studies
What	
  is	
  NFC?	
  ||
§ NFC	
  stands	
  for	
  Near	
  Field	
  Communication
§ Frequency	
  at	
  13.56	
  MHz
§ 3-­‐5	
  cm	
  of	
  range
§ Widely	
  used	
  for
§ Access	
  control	
  systems
§ Electronic	
  ticketing	
  systems
§ Mobile	
  phone	
  applications
Notorious	
  NFC	
  families||
§ MIFARE
§ MIFARE	
  Classic
§ MIFARE	
  Ultralight
§ MIFARE	
  DesFire
§ HID	
  iClass
§ Calypso
§ FeliCa
MIFARE	
  Classic	
  ||
§ 1-­‐4	
  KB	
  memory	
  storage	
  device
§ Strong access	
  control	
  mechanisms
§ A	
  key	
  is	
  required	
  to	
  access	
  data	
  sectors
§ Use	
  of	
  Crypto1 Crapto1 algorithm
§ Sadly	
  broken..
§ ..but	
  still	
  so	
  widely	
  used	
  (!)	
  – RFID	
  door	
  tokens,	
  transport	
  tickets,	
  etc.
MIFARE	
  Ultralight	
  ||
§ 64	
  byte	
  memory	
  storage	
  device
§ Basic	
  security	
  mechanisms
§ OTP	
  (One-­‐Time-­‐Programmable)	
  sector
§ Lock	
  bytes	
  sector
§ Mostly	
  used	
  for	
  disposable	
  tickets
§ It	
  has	
  some	
  more	
  secure	
  children:
• ULTRALIGHT	
  C
• ULTRALIGHT	
  EV
MIFARE	
  DesFire ||
§ 2	
  KB,	
  4KB	
  or	
  8	
  KB	
  memory	
  size
§ Advanced	
  security	
  mechanisms	
  (3DES,	
  AES,	
  etc.)
§ File	
  system	
  structure	
  is	
  supported
§ Several	
  variants	
  are	
  available
§ DESFIRE
§ DESFIRE	
  EV1
§ DESFIRE	
  EV2
HID	
  iClass ||
§ Same	
  encryption	
  and	
  authentication	
  keys	
  are	
  shared	
  across	
  
every	
  HID	
  iClass Standard	
  Security	
  installations	
  (!)
§ Keys	
  have	
  already	
  been	
  extracted	
  (!!)
§ Two	
  variants
§ iClass Standard	
  (very	
  common)
§ iClass High	
  Secure	
  (not	
  that	
  common)
§ Both	
  variants	
  are	
  BROKEN
Agenda	
  ||
§ NFC:	
  what	
  are	
  we	
  talking	
  about?
§ Modern	
  ticketing	
  systems	
  security
§ Weapons	
  for	
  NFC-­‐based	
  solutions	
  mass	
  destruction
§ Penetration	
  testing	
  methodology
§ Case	
  studies
Modern	
  ticketing	
  systems	
  security	
  ||
§ We	
  need	
  to	
  create	
  a	
  common	
  methodology
§ We	
  need	
  tools to	
  effectively	
  assess	
  these	
  systems
§ We	
  need	
  secure	
  architecturesas	
  references	
  and	
  best	
  practices
Modern	
  ticketing	
  systems	
  architecture	
  ||
Modern	
  ticketing	
  systems	
  architecture	
  ||
Local
Remote
Modern	
  ticketing	
  systems	
  architecture	
  ||
The	
  token	
  ||
§ Usually	
  a	
  NFC	
  card
§ MIFARE	
  Ultralight
§ MIFARE	
  Classic
§ Calypso
§ The	
  card	
  can	
  store
§ Multiple	
  rides	
  or	
  subscriptions
§ Timestamp	
  of	
  the	
  last	
  stamping
§ Details	
  on	
  the	
  location	
  where	
  we	
  used	
  the	
  ticket
§ Other	
  data
The	
  token	
  ||
§ What	
  about	
  MIFACE	
  Classic?
§ It	
  is	
  just	
  BROKEN
§ What	
  about	
  MIFACE	
  Ultralight?
§ Well,	
  it’s	
  bleeding..
§ Lock	
  attack
§ Time	
  attack
§ Reply	
  attack..
§ Calypso
§ Currently	
  we	
  are	
  under	
  NDA,	
  sorry	
  J
Readers	
  and	
  controllers	
  ||
§ Can	
  operate	
  offline	
  or	
  online
§ Wire	
  or	
  wireless	
  connected	
  to	
  the	
  controller
§ Usually	
  supports	
  multiple	
  standards
§ Simply	
  checks	
  if	
  the	
  ticket	
  is	
  valid
§ Is	
  the	
  ticket	
  “genuine”?
§ Is	
  the	
  stored	
  stamp	
  ok?
§ Can	
  store	
  secrets	
  and	
  keys	
  used	
  for	
  validation
The	
  backend	
  ||
§ It	
  can	
  be	
  cloud-­‐based	
  or	
  not
§ Performs	
  multiple	
  operations
§ Provide	
  ticket	
  validation	
  “logic”
§ Fraud	
  prevention?
§ Statistics
§ OTA	
  updates	
  for	
  readers
§ Frauds	
  detection
Agenda	
  ||
§ NFC:	
  what	
  are	
  we	
  talking	
  about?
§ Modern	
  ticketing	
  systems	
  security
§ Weapons	
  for	
  NFC-­‐based	
  solutions	
  mass	
  destruction
§ Penetration	
  testing	
  methodology
§ Case	
  studies
Tools	
  of	
  the	
  trade	
  ||
§ HydraNFC
§ ProxMark3
§ ChameleonMini
§ NFCulT
HydraNFC ||
§ HydraNFC (~90	
  €)	
  
§ http://hydrabus.com/hydranfc-­‐1-­‐0-­‐specifications/
§ Users	
  Texas	
  Instrument	
  TRF7970A NFC	
  chipset	
  (13.56MHz	
  only)
§ MIFARE	
  1k	
  and	
  14443A	
  UID	
  emulation
§ ISO	
  14443A	
  sniffing	
  (also	
  autonomous	
  mode)
§ 2	
  different	
  raw	
  modes
ProxMark3	
  ||
§ ProxMark3	
  (~200	
  €)	
  
§ HF	
  and	
  LF	
  capabilities
§ Very	
  large	
  community
§ http://proxmark.org/forum/index.php
§ Supports	
  almost	
  every	
  known	
  RFID	
  tags
§ Support	
  sniffing	
  and	
  emulation
ChameleonMini ||
§ ChameleonMini (~100	
  €)	
  
§ http://kasper-­‐oswald.de/gb/chameleonmini/
§ HF	
  (13.56MHz)	
  only
§ Almost	
  same	
  capabilities	
  as	
  HydraNFC
§ Different	
  chipset
§ The	
  firmware	
  is	
  only	
  available	
  for	
  old
revision
Opposing	
  Force	
  own	
  weapon	
  ||
§ NFCulT (~0	
  €)
§ Mobile	
  app	
  for	
  NFC-­‐enabled	
  Android	
  smartphones
§ Implements	
  Lock,	
  Time	
  and	
  Reply	
  attacks
§ A	
  “custom	
  edit	
  mode”	
  is	
  available	
  for	
  bit	
  by	
  bit	
  data	
  editing
§ The	
  app	
  currently	
  supports	
  the	
  MIFARE	
  Ultralight	
  format	
  only
§ MIFARE	
  Classic	
  support	
  will	
  be	
  released	
  during	
  summer	
  2016
The	
  lock	
  attack	
  feature	
  ||
§ Sets	
  the	
  OTP	
  page	
  in	
  Read-­‐Only	
  mode
§ The	
  operation	
  is	
  irreversible
§ If	
  the	
  reader	
  doesn’t	
  check	
  for	
  writing
permission	
  on	
  OTP	
  sector..
§ ..free	
  rides!
The	
  time	
  attack	
  feature	
  ||
§ The	
  features	
  allows	
  the	
  forging	
  (stamping)
(free)	
  tickets
§ The	
  tester	
  is	
  required	
  to	
  identify	
  and	
  decode
the	
  ticket’s	
  timestamps
The	
  reply	
  attack	
  feature	
  ||
§ Reply	
  attacks	
  can	
  be	
  implemented	
  using
UID	
  magic	
  tickets	
  (~15€ per	
  ticket)
§ The	
  attack	
  can	
  bypass	
  every	
  (offline)
anti-­‐fraud	
  prevention	
  mechanisms
§ Anyway,	
  guess	
  what?	
  Free	
  rides!
The	
  custom	
  editing	
  feature	
  ||
§ The	
  features	
  is	
  useful	
  to	
  better	
  understand
the	
  structure	
  of	
  data	
  stored	
  onto	
  the	
  ticket
(e.g.,	
  exact	
  location	
  of	
  timestamp)
§ Quick	
  encoding	
  from	
  hex	
  to	
  bin	
  and	
  back
§ The	
  app	
  allows	
  ticket’s	
  bit	
  per	
  bit	
  data	
  editing
Agenda	
  ||
§ NFC:	
  what	
  are	
  we	
  talking	
  about?
§ Modern	
  ticketing	
  systems	
  security
§ Weapons	
  for	
  NFC-­‐based	
  solutions	
  mass	
  destruction
§ Penetration	
  testing	
  methodology
§ Case	
  studies
What	
  are	
  we	
  looking	
  for?	
  ||
The	
  stamping	
  machine	
  ||
Attack Surface Attacks to	
  Perform Impact
NFC Interface
Analyze	
  the	
  stamping
mechanisms
Free	
  tickets
Hardware	
  board
Analyze the	
  exposed	
  
interface	
  (JTAG,	
  UART,	
  etc.)
Firmware	
  or secrets	
  
dumping
GSM/GPRS/Eth Interface
Is	
  MITM	
  possible?
Intercepting the	
  exchanged	
  
data
Intercepting secrets	
  or	
  
sensitive	
  data
• We	
  can	
  identify	
  it	
  as	
  the	
  reader	
  +	
  controller
What	
  are	
  we	
  looking	
  for?	
  ||
The	
  vending	
  machine	
  ||
Attack Surface Attacks to	
  Perform Impact
NFC Interface
Analyze	
  the	
  recharging
mechanisms
Free	
  tickets, for	
  everyone
Hardware	
  board
Analyze the	
  exposed	
  
interface	
  (JTAG,	
  UART,	
  etc.)
Firmware	
  or secrets	
  
dumping
GSM/GPRS/Eth Interface
Is	
  MITM	
  possible?
Intercepting the	
  data
Intercepting secrets	
  or	
  
sensitive	
  data
(e.g.,	
  credit	
  card	
  details)
Computer	
  Application
Analyzing exposed	
  network	
  
services
Complete control	
  of	
  the	
  
machine
• We	
  can	
  identify	
  it	
  as	
  one	
  the	
  possible	
  clients
What	
  are	
  we	
  looking	
  for?	
  ||
The	
  backend||
Attack Surface Attacks to	
  Perform Impact
Web	
  application(s)
Classic	
  web	
  app-­‐related
attacks
Data	
  exfiltration,	
  service	
  
interruption,	
  etc.
Network service(s)
Classic	
  network	
  
services-­‐related attacks
Data	
  exfiltration,	
  service	
  
interruption,	
  etc.
Physical location
Try	
  to	
  get	
  physical
access	
  to	
  the	
  servers
Basically,	
  heavily	
  
PWNED
What	
  are	
  we	
  looking	
  for?	
  ||
Agenda	
  ||
§ NFC:	
  what	
  are	
  we	
  talking	
  about?
§ Modern	
  ticketing	
  systems	
  security
§ Weapons	
  for	
  NFC-­‐based	
  solutions	
  mass	
  destruction
§ Penetration	
  testing	
  methodology
§ Case	
  studies
MIFARE	
  Ultralight	
  ticketing	
  system	
  ||
MIFARE	
  Ultralight	
  ticketing	
  system	
  ||
MIFARE	
  Ultralight	
  ticketing	
  system	
  ||
Lock	
  bit	
  for	
  the	
  OTP	
  sector	
  is	
  
not	
  checked	
  by	
  the	
  stamping	
  
machine
Absence	
  of	
  a	
  UID	
  blacklist	
  in	
  
the	
  backend
Timestamp	
  are	
  not	
  
encrypted	
  nor	
  signed
MIFARE	
  Classic	
  hotel	
  door	
  lock	
  ||
MIFARE	
  Classic	
  hotel	
  door	
  lock	
  ||
MIFARE	
  Classic	
  door	
  lock	
  ||
Card’s	
  UID
Room	
  number:	
  
int(0x17ea,	
  16)	
  =	
  6122
Q&A	
  ||
Any	
  question?
Don’t	
  be	
  shy..
Thank	
  you
Contacts	
  – engage@opposingforce.it	
  ||	
  www.opposingoforce.it	
  ||	
  @_opposingforce

Mais conteúdo relacionado

Mais procurados

Workshop on Wireless Security
Workshop on Wireless SecurityWorkshop on Wireless Security
Workshop on Wireless Security
amiable_indian
 
Voice encryption for gsm using arduino
Voice encryption for gsm using arduinoVoice encryption for gsm using arduino
Voice encryption for gsm using arduino
iruldaworld
 
NFC Everywhere Brochure 2016
NFC Everywhere Brochure 2016NFC Everywhere Brochure 2016
NFC Everywhere Brochure 2016
Laurent Dardé
 
How to hack a telecommunication company and stay alive. Sergey Gordeychik
How to hack a telecommunication company and stay alive. Sergey GordeychikHow to hack a telecommunication company and stay alive. Sergey Gordeychik
How to hack a telecommunication company and stay alive. Sergey Gordeychik
Positive Hack Days
 
festival ICT 2013: Mobile Network Security: stato dell’arte e oltre
festival ICT 2013: Mobile Network Security: stato dell’arte e oltrefestival ICT 2013: Mobile Network Security: stato dell’arte e oltre
festival ICT 2013: Mobile Network Security: stato dell’arte e oltre
festival ICT 2016
 
InfoSec World 2016 – RFIDiggity – Pentester Guide to Hacking HF/NFC and UHF...
	 InfoSec World 2016 – RFIDiggity – Pentester Guide to Hacking HF/NFC and UHF...	 InfoSec World 2016 – RFIDiggity – Pentester Guide to Hacking HF/NFC and UHF...
InfoSec World 2016 – RFIDiggity – Pentester Guide to Hacking HF/NFC and UHF...
Bishop Fox
 

Mais procurados (20)

Workshop on Wireless Security
Workshop on Wireless SecurityWorkshop on Wireless Security
Workshop on Wireless Security
 
Hacking Telco equipment: The HLR/HSS, by Laurent Ghigonis
Hacking Telco equipment: The HLR/HSS, by Laurent GhigonisHacking Telco equipment: The HLR/HSS, by Laurent Ghigonis
Hacking Telco equipment: The HLR/HSS, by Laurent Ghigonis
 
Track 5 session 2 - st dev con 2016 - security iot best practices
Track 5   session 2 - st dev con 2016 - security iot best practicesTrack 5   session 2 - st dev con 2016 - security iot best practices
Track 5 session 2 - st dev con 2016 - security iot best practices
 
Voice encryption for gsm using arduino
Voice encryption for gsm using arduinoVoice encryption for gsm using arduino
Voice encryption for gsm using arduino
 
NFC Everywhere Brochure 2016
NFC Everywhere Brochure 2016NFC Everywhere Brochure 2016
NFC Everywhere Brochure 2016
 
Security Level 3 (SL3) Capabilities
Security Level 3 (SL3) CapabilitiesSecurity Level 3 (SL3) Capabilities
Security Level 3 (SL3) Capabilities
 
Критически опасные уязвимости в популярных 3G- и 4G-модемах или как построить...
Критически опасные уязвимости в популярных 3G- и 4G-модемах или как построить...Критически опасные уязвимости в популярных 3G- и 4G-модемах или как построить...
Критически опасные уязвимости в популярных 3G- и 4G-модемах или как построить...
 
Secure Dynamic Messaging Feature
Secure Dynamic Messaging FeatureSecure Dynamic Messaging Feature
Secure Dynamic Messaging Feature
 
PrivateGSM - Voice Encryption Technical Overview
PrivateGSM - Voice Encryption Technical OverviewPrivateGSM - Voice Encryption Technical Overview
PrivateGSM - Voice Encryption Technical Overview
 
Transaction Timer Feature
Transaction Timer FeatureTransaction Timer Feature
Transaction Timer Feature
 
DEFCON 23 - Matteo Becarro Matteo Collura - extracting the painf
DEFCON 23 - Matteo Becarro Matteo Collura - extracting the painfDEFCON 23 - Matteo Becarro Matteo Collura - extracting the painf
DEFCON 23 - Matteo Becarro Matteo Collura - extracting the painf
 
Hardwear.io 2018 BLE Security Essentials workshop
Hardwear.io 2018 BLE Security Essentials workshopHardwear.io 2018 BLE Security Essentials workshop
Hardwear.io 2018 BLE Security Essentials workshop
 
How to hack a telecommunication company and stay alive. Sergey Gordeychik
How to hack a telecommunication company and stay alive. Sergey GordeychikHow to hack a telecommunication company and stay alive. Sergey Gordeychik
How to hack a telecommunication company and stay alive. Sergey Gordeychik
 
festival ICT 2013: Mobile Network Security: stato dell’arte e oltre
festival ICT 2013: Mobile Network Security: stato dell’arte e oltrefestival ICT 2013: Mobile Network Security: stato dell’arte e oltre
festival ICT 2013: Mobile Network Security: stato dell’arte e oltre
 
InfoSec World 2016 – RFIDiggity – Pentester Guide to Hacking HF/NFC and UHF...
	 InfoSec World 2016 – RFIDiggity – Pentester Guide to Hacking HF/NFC and UHF...	 InfoSec World 2016 – RFIDiggity – Pentester Guide to Hacking HF/NFC and UHF...
InfoSec World 2016 – RFIDiggity – Pentester Guide to Hacking HF/NFC and UHF...
 
Labmeeting - 20150211 - Novel End-to-End Voice Encryption Method in GSM System
Labmeeting - 20150211 - Novel End-to-End Voice Encryption Method in GSM SystemLabmeeting - 20150211 - Novel End-to-End Voice Encryption Method in GSM System
Labmeeting - 20150211 - Novel End-to-End Voice Encryption Method in GSM System
 
Mikael Falkvidd IoT - Stena AB Faster Forward
Mikael Falkvidd IoT - Stena AB Faster ForwardMikael Falkvidd IoT - Stena AB Faster Forward
Mikael Falkvidd IoT - Stena AB Faster Forward
 
Unauthorized Wireless Network Connections
Unauthorized Wireless Network ConnectionsUnauthorized Wireless Network Connections
Unauthorized Wireless Network Connections
 
Encrypted Voice Communications
Encrypted Voice CommunicationsEncrypted Voice Communications
Encrypted Voice Communications
 
Owasp top 10
Owasp top 10 Owasp top 10
Owasp top 10
 

Destaque (6)

(Ab)using Smart Cities - the dark age of modern mobility
(Ab)using Smart Cities - the dark age of modern mobility(Ab)using Smart Cities - the dark age of modern mobility
(Ab)using Smart Cities - the dark age of modern mobility
 
Breaking Bad EACS Implementations
Breaking Bad EACS ImplementationsBreaking Bad EACS Implementations
Breaking Bad EACS Implementations
 
Electronic Access Control Security
Electronic Access Control SecurityElectronic Access Control Security
Electronic Access Control Security
 
Smart Cities in the IoT Era
Smart Cities in the IoT EraSmart Cities in the IoT Era
Smart Cities in the IoT Era
 
NEAR FIELD COMMUNICATION
NEAR FIELD COMMUNICATIONNEAR FIELD COMMUNICATION
NEAR FIELD COMMUNICATION
 
NFC technical presentation
NFC technical presentationNFC technical presentation
NFC technical presentation
 

Semelhante a NFC: Naked Fried Chicken (PHDays VI)

amrapali builders@@sub way hacking.pdf
amrapali builders@@sub way hacking.pdfamrapali builders@@sub way hacking.pdf
amrapali builders@@sub way hacking.pdf
amrapalibuildersreviews
 

Semelhante a NFC: Naked Fried Chicken (PHDays VI) (20)

NFC: Naked Fried Chicken / Пентест NFC — вот что я люблю
NFC: Naked Fried Chicken / Пентест NFC — вот что я люблюNFC: Naked Fried Chicken / Пентест NFC — вот что я люблю
NFC: Naked Fried Chicken / Пентест NFC — вот что я люблю
 
RFID Security Module
RFID Security ModuleRFID Security Module
RFID Security Module
 
amrapali builders@@sub way hacking.pdf
amrapali builders@@sub way hacking.pdfamrapali builders@@sub way hacking.pdf
amrapali builders@@sub way hacking.pdf
 
Net Defender
Net DefenderNet Defender
Net Defender
 
Netdefender
NetdefenderNetdefender
Netdefender
 
Architectural Patterns in IoT Cloud Platforms
Architectural Patterns in IoT Cloud PlatformsArchitectural Patterns in IoT Cloud Platforms
Architectural Patterns in IoT Cloud Platforms
 
Conclusions from Tracking Server Attacks at Scale
Conclusions from Tracking Server Attacks at ScaleConclusions from Tracking Server Attacks at Scale
Conclusions from Tracking Server Attacks at Scale
 
Why Its time to Upgrade a Next-Generation Firewall
Why Its time to Upgrade a Next-Generation FirewallWhy Its time to Upgrade a Next-Generation Firewall
Why Its time to Upgrade a Next-Generation Firewall
 
Unified Threat Management
Unified Threat ManagementUnified Threat Management
Unified Threat Management
 
VULNERABILITY ( CYBER SECURITY )
VULNERABILITY ( CYBER SECURITY )VULNERABILITY ( CYBER SECURITY )
VULNERABILITY ( CYBER SECURITY )
 
DSS ITSEC Conference 2012 - Forescout NAC #1
DSS ITSEC Conference 2012 - Forescout NAC #1DSS ITSEC Conference 2012 - Forescout NAC #1
DSS ITSEC Conference 2012 - Forescout NAC #1
 
PLNOG14: Czy można żyć bez systemu ochrony przed atakami DDoS - Marek Janik
PLNOG14: Czy można żyć bez systemu ochrony przed atakami DDoS - Marek JanikPLNOG14: Czy można żyć bez systemu ochrony przed atakami DDoS - Marek Janik
PLNOG14: Czy można żyć bez systemu ochrony przed atakami DDoS - Marek Janik
 
Myles firewalls
Myles firewallsMyles firewalls
Myles firewalls
 
Iot vupico-damien-contreras-2018-05-17-light-v3
Iot vupico-damien-contreras-2018-05-17-light-v3Iot vupico-damien-contreras-2018-05-17-light-v3
Iot vupico-damien-contreras-2018-05-17-light-v3
 
Introduction to nfc
Introduction to nfcIntroduction to nfc
Introduction to nfc
 
DC4420 2014 - NFC - The Non-Radio Bits
DC4420 2014 - NFC - The Non-Radio BitsDC4420 2014 - NFC - The Non-Radio Bits
DC4420 2014 - NFC - The Non-Radio Bits
 
01- intro to firewall concepts
01- intro to firewall concepts01- intro to firewall concepts
01- intro to firewall concepts
 
DevLink - WiFu: You think your wireless is secure?
DevLink - WiFu: You think your wireless is secure?DevLink - WiFu: You think your wireless is secure?
DevLink - WiFu: You think your wireless is secure?
 
DIY Internet: Snappy, Secure Networking with MinimaLT (JSConf EU 2013)
DIY Internet: Snappy, Secure Networking with MinimaLT (JSConf EU 2013)DIY Internet: Snappy, Secure Networking with MinimaLT (JSConf EU 2013)
DIY Internet: Snappy, Secure Networking with MinimaLT (JSConf EU 2013)
 
2017 - LISA - LinkedIn's Distributed Firewall (DFW)
2017 - LISA - LinkedIn's Distributed Firewall (DFW)2017 - LISA - LinkedIn's Distributed Firewall (DFW)
2017 - LISA - LinkedIn's Distributed Firewall (DFW)
 

Último

Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
WSO2
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 

Último (20)

Ransomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdfRansomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdf
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
A Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusA Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source Milvus
 
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 

NFC: Naked Fried Chicken (PHDays VI)

  • 1. N  F  C   Naked  Fried  Chicken Matteo  Beccaro ||  May  18th,  2016
  • 2. Me  || § Matteo  Beccaro § Founder &  Chief  Technology  Officer  at  Opposing  Force § The  first  Italian  company  specialize  in  offensive  physical  security § Twitter:  @_bughardy_  |  @_opposingforce
  • 3. Agenda  || § NFC:  what  are  we  talking  about? § Modern  ticketing  systems  security § Weapons  for  NFC-­‐based  solutions  mass  destruction § Penetration  testing  methodology § Case  studies
  • 4. Agenda  || § NFC:  what  are  we  talking  about? § Modern  ticketing  systems  security § Weapons  for  NFC-­‐based  solutions  mass  destruction § Penetration  testing  methodology § Case  studies
  • 5. What  is  NFC?  || § NFC  stands  for  Near  Field  Communication § Frequency  at  13.56  MHz § 3-­‐5  cm  of  range § Widely  used  for § Access  control  systems § Electronic  ticketing  systems § Mobile  phone  applications
  • 6. Notorious  NFC  families|| § MIFARE § MIFARE  Classic § MIFARE  Ultralight § MIFARE  DesFire § HID  iClass § Calypso § FeliCa
  • 7. MIFARE  Classic  || § 1-­‐4  KB  memory  storage  device § Strong access  control  mechanisms § A  key  is  required  to  access  data  sectors § Use  of  Crypto1 Crapto1 algorithm § Sadly  broken.. § ..but  still  so  widely  used  (!)  – RFID  door  tokens,  transport  tickets,  etc.
  • 8. MIFARE  Ultralight  || § 64  byte  memory  storage  device § Basic  security  mechanisms § OTP  (One-­‐Time-­‐Programmable)  sector § Lock  bytes  sector § Mostly  used  for  disposable  tickets § It  has  some  more  secure  children: • ULTRALIGHT  C • ULTRALIGHT  EV
  • 9. MIFARE  DesFire || § 2  KB,  4KB  or  8  KB  memory  size § Advanced  security  mechanisms  (3DES,  AES,  etc.) § File  system  structure  is  supported § Several  variants  are  available § DESFIRE § DESFIRE  EV1 § DESFIRE  EV2
  • 10. HID  iClass || § Same  encryption  and  authentication  keys  are  shared  across   every  HID  iClass Standard  Security  installations  (!) § Keys  have  already  been  extracted  (!!) § Two  variants § iClass Standard  (very  common) § iClass High  Secure  (not  that  common) § Both  variants  are  BROKEN
  • 11. Agenda  || § NFC:  what  are  we  talking  about? § Modern  ticketing  systems  security § Weapons  for  NFC-­‐based  solutions  mass  destruction § Penetration  testing  methodology § Case  studies
  • 12. Modern  ticketing  systems  security  || § We  need  to  create  a  common  methodology § We  need  tools to  effectively  assess  these  systems § We  need  secure  architecturesas  references  and  best  practices
  • 13. Modern  ticketing  systems  architecture  ||
  • 14. Modern  ticketing  systems  architecture  || Local Remote
  • 15. Modern  ticketing  systems  architecture  ||
  • 16. The  token  || § Usually  a  NFC  card § MIFARE  Ultralight § MIFARE  Classic § Calypso § The  card  can  store § Multiple  rides  or  subscriptions § Timestamp  of  the  last  stamping § Details  on  the  location  where  we  used  the  ticket § Other  data
  • 17. The  token  || § What  about  MIFACE  Classic? § It  is  just  BROKEN § What  about  MIFACE  Ultralight? § Well,  it’s  bleeding.. § Lock  attack § Time  attack § Reply  attack.. § Calypso § Currently  we  are  under  NDA,  sorry  J
  • 18. Readers  and  controllers  || § Can  operate  offline  or  online § Wire  or  wireless  connected  to  the  controller § Usually  supports  multiple  standards § Simply  checks  if  the  ticket  is  valid § Is  the  ticket  “genuine”? § Is  the  stored  stamp  ok? § Can  store  secrets  and  keys  used  for  validation
  • 19. The  backend  || § It  can  be  cloud-­‐based  or  not § Performs  multiple  operations § Provide  ticket  validation  “logic” § Fraud  prevention? § Statistics § OTA  updates  for  readers § Frauds  detection
  • 20. Agenda  || § NFC:  what  are  we  talking  about? § Modern  ticketing  systems  security § Weapons  for  NFC-­‐based  solutions  mass  destruction § Penetration  testing  methodology § Case  studies
  • 21. Tools  of  the  trade  || § HydraNFC § ProxMark3 § ChameleonMini § NFCulT
  • 22. HydraNFC || § HydraNFC (~90  €)   § http://hydrabus.com/hydranfc-­‐1-­‐0-­‐specifications/ § Users  Texas  Instrument  TRF7970A NFC  chipset  (13.56MHz  only) § MIFARE  1k  and  14443A  UID  emulation § ISO  14443A  sniffing  (also  autonomous  mode) § 2  different  raw  modes
  • 23. ProxMark3  || § ProxMark3  (~200  €)   § HF  and  LF  capabilities § Very  large  community § http://proxmark.org/forum/index.php § Supports  almost  every  known  RFID  tags § Support  sniffing  and  emulation
  • 24. ChameleonMini || § ChameleonMini (~100  €)   § http://kasper-­‐oswald.de/gb/chameleonmini/ § HF  (13.56MHz)  only § Almost  same  capabilities  as  HydraNFC § Different  chipset § The  firmware  is  only  available  for  old revision
  • 25. Opposing  Force  own  weapon  || § NFCulT (~0  €) § Mobile  app  for  NFC-­‐enabled  Android  smartphones § Implements  Lock,  Time  and  Reply  attacks § A  “custom  edit  mode”  is  available  for  bit  by  bit  data  editing § The  app  currently  supports  the  MIFARE  Ultralight  format  only § MIFARE  Classic  support  will  be  released  during  summer  2016
  • 26. The  lock  attack  feature  || § Sets  the  OTP  page  in  Read-­‐Only  mode § The  operation  is  irreversible § If  the  reader  doesn’t  check  for  writing permission  on  OTP  sector.. § ..free  rides!
  • 27. The  time  attack  feature  || § The  features  allows  the  forging  (stamping) (free)  tickets § The  tester  is  required  to  identify  and  decode the  ticket’s  timestamps
  • 28. The  reply  attack  feature  || § Reply  attacks  can  be  implemented  using UID  magic  tickets  (~15€ per  ticket) § The  attack  can  bypass  every  (offline) anti-­‐fraud  prevention  mechanisms § Anyway,  guess  what?  Free  rides!
  • 29. The  custom  editing  feature  || § The  features  is  useful  to  better  understand the  structure  of  data  stored  onto  the  ticket (e.g.,  exact  location  of  timestamp) § Quick  encoding  from  hex  to  bin  and  back § The  app  allows  ticket’s  bit  per  bit  data  editing
  • 30. Agenda  || § NFC:  what  are  we  talking  about? § Modern  ticketing  systems  security § Weapons  for  NFC-­‐based  solutions  mass  destruction § Penetration  testing  methodology § Case  studies
  • 31. What  are  we  looking  for?  ||
  • 32. The  stamping  machine  || Attack Surface Attacks to  Perform Impact NFC Interface Analyze  the  stamping mechanisms Free  tickets Hardware  board Analyze the  exposed   interface  (JTAG,  UART,  etc.) Firmware  or secrets   dumping GSM/GPRS/Eth Interface Is  MITM  possible? Intercepting the  exchanged   data Intercepting secrets  or   sensitive  data • We  can  identify  it  as  the  reader  +  controller
  • 33. What  are  we  looking  for?  ||
  • 34. The  vending  machine  || Attack Surface Attacks to  Perform Impact NFC Interface Analyze  the  recharging mechanisms Free  tickets, for  everyone Hardware  board Analyze the  exposed   interface  (JTAG,  UART,  etc.) Firmware  or secrets   dumping GSM/GPRS/Eth Interface Is  MITM  possible? Intercepting the  data Intercepting secrets  or   sensitive  data (e.g.,  credit  card  details) Computer  Application Analyzing exposed  network   services Complete control  of  the   machine • We  can  identify  it  as  one  the  possible  clients
  • 35. What  are  we  looking  for?  ||
  • 36. The  backend|| Attack Surface Attacks to  Perform Impact Web  application(s) Classic  web  app-­‐related attacks Data  exfiltration,  service   interruption,  etc. Network service(s) Classic  network   services-­‐related attacks Data  exfiltration,  service   interruption,  etc. Physical location Try  to  get  physical access  to  the  servers Basically,  heavily   PWNED
  • 37. What  are  we  looking  for?  ||
  • 38. Agenda  || § NFC:  what  are  we  talking  about? § Modern  ticketing  systems  security § Weapons  for  NFC-­‐based  solutions  mass  destruction § Penetration  testing  methodology § Case  studies
  • 41. MIFARE  Ultralight  ticketing  system  || Lock  bit  for  the  OTP  sector  is   not  checked  by  the  stamping   machine Absence  of  a  UID  blacklist  in   the  backend Timestamp  are  not   encrypted  nor  signed
  • 42. MIFARE  Classic  hotel  door  lock  ||
  • 43. MIFARE  Classic  hotel  door  lock  ||
  • 44. MIFARE  Classic  door  lock  || Card’s  UID Room  number:   int(0x17ea,  16)  =  6122
  • 46. Thank  you Contacts  – engage@opposingforce.it  ||  www.opposingoforce.it  ||  @_opposingforce