1355 Commits
Author SHA1 Message Date
Etienne Helluy-Lafont 14d7ef161e repo url 2020-05-18 17:08:27 +02:00
Etienne Helluy-Lafont 2382ca6e41 ubtbr initial commit 2020-05-18 17:01:46 +02:00
Mike Ryan 985a40d891 Merge pull request #406 from geistesk/issue-405
ego: include signal.h for signal functions
2020-05-14 09:31:47 -07:00
Alvar Penning 8574834aa3 ego: include signal.h for signal functions
This fixes the build and closes #405.
2020-05-14 17:23:59 +02:00
Mike Ryan 19c69f23ec ego: start of rfcat24 - set access code and length
Beginnings of a generic radio interface built on top of the old e-Go
sniffing code. Eventually this will be able to sniff ShockBurst™ and
Enhanced ShockBurst™ (aka PowerThirst™ AHHHHHHH).
2020-04-24 21:22:22 -07:00
Mike Ryan 063b614b91 ego: handle ctrl-c more cleanly
The signal handler previously installed could cause hangs most commonly
observed on OS X. This much simpler handler sets a flag that is checked
in a tight while loop to prevent lockups.
2020-04-24 21:21:30 -07:00
Mike Ryan f2c5217c5d firmware: enable fault handler that blink LEDs
In order to facilitate debugging, this patch implements fault handlers
that blink all three LEDs a certain number of times based on the nature
of the fault. The blinking pattern indicates which of the four major
fault types was triggered along with the subtype (example: usage fault
with divide by zero will blink five times followed by one).
2019-12-01 14:47:52 -08:00
Mike Ryan fdf2700657 travis: fix build error on OS X with workaround from certbot 2019-12-01 14:03:32 -08:00
Mike Ryan fea9d0fc2d le: disable DMA interrupt to workaround timer interrupt issues
Under certain circumstances, it is possible for a timer interrupt to
fire while a DMA interrupt is being handled. Regardless of interrupt
priority and subpriority between the DMA and timer interrupt, the timer
interrupt will never be serviced.

The LE sniffing code uses the timer interrupt to poll the CC2400's
FS_LOCK status. If this bug is triggered, the FS_LOCK polling will not
occur and the timer interrupt will not be rescheduled, causing capture
to freeze.

Curiously this only occurs after all DMA channels have been disabled,
and the DMACIntStat register will indicate 0 on all channels. The
interrupt fires 8 microseconds after the previous byte is received, when
the next byte would be available from the radio had the DMA channel not
be disabled. Perhaps it's an issue draining the FIFO?

Regardless, if a timer interrupt fires during a DMA interrupt handler,
it should be serviced either pre-emptively (if higher priority) or after
the DMA interrupt handler finishes (same or lower priority). This may be
a hardware issue with the chip.

Closes #326, although this fix is a kludge
2019-11-07 21:33:55 -08:00
Mike Ryan 53f44b58c0 le: handle NULL rxbuf under heavy load
Under heavy load and when processing long packets, all rxbufs can become
used. In this situation, buffer_get() will return NULL. The existing
code would dereference the NULL, freezing capture.

This fix checks for NULL and uses the timer interrupt to periodically
poll for available rxbufs. Once an rxbuf becomes available, capture is
resumed.

Note that the existing code includes a comment: TODO handle error
condition. Had that TODO been heeded, untold hours of debugging,
patches, and lost productivity could have been saved. All for want of an
error handler.

See #326
2019-11-07 21:21:20 -08:00
Mike Ryan 3b17477ace le: lower priority of DMA interrupt
Occasionally a DMA interrupt would fire a few microseconds before the
timer1 interrupt for checking FSON status was scheduled. Due to some
weirdness in the ARM's NVIC, this was causing the timer1 interrupt
handler to never execute. This patch reduces DMA interrupt to the lowest
priority, allowing the timer1 interrupt handler to preempt the DMA
handler. See #326.

This does not completely solve the problem, as it is still possible for
the firmware to hang and become unresponsive to USB requests in
environments with a lot of BLE traffic.
2019-11-07 21:14:59 -08:00
cathy 2f0558c82a Change to ubertooth-follow to get target clock correctly 2019-07-10 14:01:38 -04:00
Michael Farrell 04eb7c0ac4 Use DLT_BLUETOOTH_LE_LL for PPI rather than DLT_USER0.
`DLT_USER*` is intended for private use.  It requires extra configuration in
tools like Wireshark to make it actually work, and causes problems for
Ubertooth users in other tools (eg: secdev/scapy#1673)

I don't have the hardware for this, so I cannot test this change.
2019-03-16 23:19:07 +11:00
Dominic Spill f2575054a9 Build artefacts from Travis CI (#342) 2018-12-19 15:36:23 -07:00
dor.zusman 62bc2963ba le: Fixed CC2400 FIFO usage to allow BLE packets that are larger then 32 bytes
Added some code to correctly fill-out the CC2400 FIFO while transmitting BLE and removed size limitation placed as a workaround.
2018-12-13 19:42:39 +02:00
Mike Ryan 0adf33ee73 release: 2018-12-R1 -- the Uberducky release
Make your Ubertooth quack like a USB Rubber Ducky!
2018-12-R1
2018-12-04 22:21:07 -08:00
Mike Ryan 0dd3657eda host: make an Uberducky enter the bootloader 2018-12-04 22:21:07 -08:00
Mike Ryan a05b604691 le: handle USB interrupts correctly within LE slave mode 2018-12-04 22:21:07 -08:00
Mike Ryan db6df2704d host: ubertooth-quack - make an Uberducky quack! 2018-12-04 22:21:03 -08:00
Mike Ryan ac739d6ad7 le: correctly return 0 on invalid mask 2018-12-04 22:14:56 -08:00
Mike Ryan b41886942d le slave: set advertising data via USB 2018-11-19 21:00:17 -08:00
Mike Ryan 7c8ab5388e le slave: load adv data from a global buffer 2018-11-19 20:27:20 -08:00
Mike Ryan 6a40257e49 firmware: include data len in USB vendor request parameters
All USB commands taking variable length data need to be updated to
perform bounds checking.
2018-11-19 20:25:09 -08:00
Mike Ryan ef82068a0f le slave: limit packets to 32 bytes to work around FIFO issues
See #208
2018-11-18 22:01:10 -08:00
Mike Ryan f51831bfb1 le slave: use hardware sync word for AA
The old mode turned off preamble, stuffed the preamble into one byte of
hardware sync word, and then stuffed the AA into the packet body.
Possibly due to a strange reading of the CC2400 manual?
2018-11-18 21:54:24 -08:00
Dominic Spill d558cdfe0c Merge pull request #336 from ayleph/master
Fix for #308: Migrate ubertooth-specan-ui to PySide2
2018-10-25 14:33:42 -06:00
Andrew Browning 7985d95f67 Migrate ubertooth-specan-ui to PySide2 2018-10-24 22:45:13 -07:00
Dominic Spill 65c0a5dbf5 Merge pull request #329 from Etherealflux/master
Specan UI improvements
2018-08-20 16:57:46 -06:00
Steven Haussmann afd00bcf12 Clean up duplicate code. Improve how --wifi args worse 2018-08-20 18:48:20 -04:00
Steven Haussmann 275c5acf04 Improve formatting 2018-08-20 11:06:27 -04:00
Steven Haussmann 7b1f2aca9c Switch from optparse to argparse. Add wifi channel selection. 2018-08-20 10:35:26 -04:00
Steven Haussmann c0ca3b0d69 Add clear function to the UI 2018-08-19 21:08:36 -04:00
Steven Haussmann e33b85e6de Add lower/upper frequency bounds for the specan UI 2018-08-19 20:50:53 -04:00
Mike Ryan 134ac9a805 release: 2018-08-R1 -- the DEFCON release
New LE sniffing engine and lots of other awesome extras
2018-08-07 15:32:46 -07:00
Mike Ryan 57e0426c39 doc: document no-follow mode in ubertooth-btle 2018-08-07 15:26:20 -07:00
Mike Ryan fec3f3dd06 le: introduce feature to NOT follow connections
This oft-requested feature uses the LE sniffing engine to log
advertising packets but NOT follow connections as they are observed.
Previously we recommended people use a hack involving filters, but the
new LE sniffing engine made that hack non-functional. Instead we now
formally support explicitly requesting not to follow connections.

Closes #327
2018-08-04 14:44:46 -07:00
Mike Ryan 54109a7ebf doc: document new filter behavior in markdown + man
d# You are currently bisecting, started from branch 'master'.
2018-07-09 10:10:08 -07:00
Mike Ryan a6332a7d0b le: handle connection update procedure
The LE Connection Update Procedure allows devices to change their
connection parameters, mainly hop interval. This code has a major
shortcoming: if we miss the first packet after the update, the
connection is lost completely. This code and the new connection handling
code should be refactored to use the transmit window until at least one
packet is captured and an anchor is set.
2018-07-01 13:10:56 -07:00
Mike Ryan 71a3aca9e5 le: add support for BD ADDR filter mask, and other improvements
- support filter masks. example: 11:22:33:00:00:00/24
 - allow clearing the filter using -t none
 - can set filter on same command as -f
 - bumped libubertooth to 1.01
 - bumped USB API to 1.04
2018-06-28 13:55:52 -07:00
Mike Ryan 76d17b1de7 le: retry due to stalls when polling for packets 2018-06-26 15:50:44 -07:00
Mike Ryan 630c4d95d8 release: 2018-06-R1 -- new BLE sniffing engine 2018-06-R1 2018-06-26 13:39:04 -07:00
Mike Ryan 5441b44989 Merge pull request #318 from mnaberez/libusb_free_device_list
host: Fix unreachable libusb_free_device_list() in ubertooth_count()
2018-06-25 16:33:15 -07:00
Mike Naberezny 41f9cfa20e host: Fix unreachable libusb_free_device_list() in ubertooth_count() 2018-06-25 15:50:25 -07:00
Mike Ryan 41481727cb le: reset cancel_follow when le_phy is reinvoked 2018-06-24 16:35:38 -07:00
Mike Ryan cc2991c495 host: cleanly exit ubertooth-btle on ctrl-c
The previous version of this code (and the version that all other tools
use) attempts to close ubertooth and then calls exit(0) inside the
signal handler. In addition to being bad practice, it can fail if the
signal is received in the middle of handling another USB command,
leaving the Ubertooth running in an inconsistent state. The other tools
should be similarly refactored.
2018-06-24 16:07:45 -07:00
Mike Ryan 7bf79eec62 le: do not attempt to follow obviously bad CONNECT_REQ 2018-06-24 15:58:46 -07:00
Mike Ryan c920e95c1c host: print total number of Uberteeth and exit 2018-06-22 12:36:49 -07:00
Mike Ryan b1093000a8 le: include signal.h to fix build on Linux 2018-06-22 10:08:25 -07:00
Mike Ryan cc2081cef6 le: cancel following an active connection
Add a USB command to cancel following and add support for invoking it by
sending SIGUSR1 to the ubertooth-btle host command. If it is sent when a
connection is not being followed, it acts as a NOP.
2018-06-22 10:04:31 -07:00
Mike Ryan 8e9054af40 lib: support unlimited uberteeth 2018-06-21 21:13:57 -07:00