1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
Commit Graph

9027 Commits

Author SHA1 Message Date
Marian Buschsieweke
8a178f49e7
sys/fido2: fix CBOR parsing
The TinyCBOR library takes a `size_t *` length argument in many
functions which at function call contains the length of a buffer, and
at exit the actual size of the data. The FIDO-2 code however uses
`uint8_t` fields in `struct`s to store the data. Previously, a pointer
to that `uint8_t` filed was just casted to `size_t *`, resulting in
three neighboring bytes also being interpreted as being part of the
buffer size - which could result in undetected buffer overflows.
Similar, upon exit of the function not only the `uint8_t` sized length
`struct` member but also three neighboring bytes were written to.

I didn't care to investigate, but this really looks like crafted CBOR
payloads send to the FIDO2 implementation could result in arbitrary
code execution on the device.
2021-11-13 20:32:02 +01:00
Marian Buschsieweke
7b06e665ee
sys/architecture: add HAS_ALIGNMENT_OF() helper 2021-11-11 10:57:26 +01:00
Kevin "Tristate Tom" Weiss
da60ba5fff
Merge pull request #17165 from leandrolanzieri/pr/sys/ztimer_kconfig_entry
sys/ztimer: rework Kconfig

To eliminate circular dependencies based in periph_rtc and xtimer_ztimer_compatibility the following changes are applied:
- Change entrypoint of ztimer as a specific backend is always required
- Add a non-module symbol for ztimer_usec that bring in the ztimer and ztimer_usec module which allows the xtimer ztimer compatibility layer to only select the ztimer_usec module preventing circular dependency issues
2021-11-11 09:21:33 +01:00
dba51edc69 net/uhcp[cd]: use modules to select client/server code 2021-11-09 21:42:45 +01:00
Leandro Lanzieri
703e66b4c1
sys/ztimer/kconfig: change entry point 2021-11-09 15:32:34 +01:00
Leandro Lanzieri
3837286750
sys/{x,z}timer/Kconfig: fix compatibility modules 2021-11-09 15:32:33 +01:00
Martine Lenders
4b2ca7a702
Merge pull request #16986 from benpicco/uhcp-debug
sys/net/uhcp: use LOG_DEBUG instead of LOG_INFO
2021-11-09 12:58:16 +01:00
Marian Buschsieweke
f7bed004ff
Merge pull request #17153 from maribu/sys/net/dns
sys/net/dns: mark dns_hdr_t as packed
2021-11-07 07:52:16 +01:00
Marian Buschsieweke
2e6eca1918
sys/net/dns: mark dns_hdr_t as packed
This structure is used to parse data from unaligned buffers, so make
sure the compiler issues instructions suitable for unaligned memory
access.
2021-11-06 20:16:56 +01:00
benpicco
1f11780c02
Merge pull request #17119 from spectraphilic/sdi12-remote
pkg/arduino_sdi_12: support the remote-revb board
2021-11-06 11:32:54 +01:00
J. David Ibáñez
77df3eedbd sys/arduino: millis() expected to have C linkage
This fixes building tests/pkg_arduino_sdi_12 for the hifive1b board.

The problem is, in build/pkg/arduino_api/api/Common.h millis is defined
within an extern "C" block. While in sys/arduino/include/arduino.hpp it
was not.
2021-11-05 10:21:26 +01:00
eaa007d412
Merge pull request #17135 from bergzand/pr/usbdev/fix_cppcheck_vera
usb(dev|bus): Fix static-check issues
2021-11-05 08:36:53 +01:00
9f510fb1ab
usbus/cdc_acm: resolve vera++ issues 2021-11-04 13:49:35 +01:00
df39337ebf
usbopt: resolve vera++ issues 2021-11-04 13:49:34 +01:00
86aa665cbc
usbus_hid: Fix possible null pointer dereference 2021-11-04 13:45:19 +01:00
b0d5e9a027
Merge pull request #17128 from dylad/pr/usbus/dfu/fix_underflow_condition
usbus/dfu: fix underflow condition while updating firmware
2021-11-04 09:50:18 +01:00
Dylan Laduranty
64a82c9a78 usbus/dfu: fix underflow condition while updating firmware
Reports dfuERROR if underflow is detected or if flash write failed
Implement DFU control CLRSTATUS while at it to clear dfuERROR by the host
2021-11-03 17:06:27 +01:00
1fa8bcc9d2
Merge pull request #17123 from bergzand/pr/stdio_semihosting/ztimer
stdio_semihosting: Convert to ztimer
2021-11-03 16:22:45 +01:00
benpicco
47029055a6
Merge pull request #8954 from zhuoshuguo/gnrc_gomach/adapt_duty_recode_para_name
gnrc_gomach: adapt duty recording parameters' namings.
2021-11-03 12:56:39 +01:00
4cfb155397
stdio_semihosting: Add unit clarification to poll define 2021-11-03 11:39:26 +01:00
2b696fd770
stdio_semihosting: Convert to ztimer 2021-11-03 11:39:26 +01:00
Martine Lenders
67f67bfe62
Merge pull request #17076 from jenswet/feature/add-fff-package
pkg/fff: Add fake functions framework package
2021-11-03 11:00:56 +01:00
Francisco
8e0d5efaa2
Merge pull request #17113 from fjmolinas/pr_ztimer_sec_no_rtc
sys/ztimer: don't default to rtc for ztimer_sec
2021-11-02 22:08:37 +01:00
Jens Wetterich
14f90f3c5e pkg/fff: Add fake functions framework package 2021-11-02 18:01:21 +01:00
Francisco
0bbcf4863f
Merge pull request #17006 from yarrick/ifconfig_help
sys/shell/gnrc_netif: Allow 'ifconfig help'
2021-11-02 16:32:59 +01:00
Francisco Molina
2e4dfa0aac sys/ztimer: don't default to rtc for ztimer_sec 2021-11-02 15:31:04 +01:00
Francisco
1ef44844e0
Merge pull request #17085 from bergzand/pr/cdcacm/stall_on_no_line_coding
usbus/cdc_acm: Return stall on line coding not supported
2021-11-02 13:04:26 +01:00
Leandro Lanzieri
f64b166319
Merge pull request #16845 from MrKevinWeiss/pr/kconfig/supportstms
.murdock: Add nucleo boards to kconfig test
2021-11-01 09:55:22 +01:00
Leandro Lanzieri
4011bd9edf
Merge pull request #16780 from fjmolinas/pr_kconfig_uwb
pkg/uwb*: add Kconfig dependency modelling
2021-11-01 09:35:29 +01:00
6a509308fe
usbus/cdc_acm: Return stall on line coding not supported
The SetLineCoding request is optional to support (CDC PSTN subclass). No
need to claim to support it to the host and actually discard the data if
it is not supported by the implementation.
2021-10-30 11:56:42 +02:00
Benjamin Valentin
358aa11d48 ztimer/xtimer_compat: implement trivial functions
xtimer_ticks64_t / xtimer_ticks32_t is no longer a struct, so these are
even more trivial than on xtimer.
2021-10-29 00:45:01 +02:00
J. David Ibáñez
a651315fbe sys/arduino: add interrupts/noInterrupts
This fixes the error:

$ BOARD=arduino-mega2560 make -C tests/pkg_arduino_sdi_12/
[...]
[...]/RIOT/build/pkg/arduino_sdi_12/src/SDI12.cpp:379:7: error: ‘interrupts’ was not declared in this scope
2021-10-28 15:59:48 +02:00
chrysn
a92cdb535e
Merge pull request #16378 from chrysn-pull-requests/gcoap-handle-truncation
sys/net/gcoap: Use socket _buf API to recognize truncated requests
2021-10-27 08:55:52 +02:00
Dylan Laduranty
aa4383104f
Merge pull request #17051 from bergzand/pr/riotboot_dfu/ztimer
riotboot_dfu: use ztimer instead of xtimer
2021-10-26 20:49:26 +02:00
5dfc4725c8
usbus_dfu: Use ztimer for reboot timeout 2021-10-26 14:14:46 +02:00
5c01e14b7a
riotboot_dfu: Add ztimer_msec dependency 2021-10-26 14:14:45 +02:00
261a615439
ztimer: Use auto_init for manual init in bootloaders 2021-10-25 22:24:07 +02:00
4bec2f0723
Merge pull request #17034 from fjmolinas/pr_turo_optional_space_after_symbol
sys/test_utils/result_output/json: optional space after symbol
2021-10-25 22:31:16 +03:00
benpicco
2aab2b83bc
Merge pull request #17046 from bergzand/pr/usb/deprecate_fail_report
usbdev/USBUS: deprecate transfer failure reporting report
2021-10-25 16:27:01 +02:00
0ce6bfc1a2
usbus: Deprecate USBUS_HANDLER_FLAG_TR_FAIL event 2021-10-24 19:33:29 +02:00
Erik Ekman
ccfe80c844 sys/shell/gnrc_netif: Allow 'ifconfig help'
Currently a valid netif name must be passed to show the usage
instructions:

```
> ifconfig help
error: invalid interface given
> ifconfig 6 help
usage: ifconfig
usage: ifconfig <if_id> [up|down]
[...]
```

`ifconfig --help` is also accepted.
2021-10-22 14:14:58 +02:00
4bee52a693 sys/test_utils/result_output: fix turo_float() precision value
`print_float()` only allows values from 0-7.
2021-10-22 12:49:16 +02:00
Francisco Molina
720338b304 sys/test_utils/result_output/json: optional space after symbol 2021-10-22 12:31:03 +02:00
Francisco
abbf798e8e
Merge pull request #17027 from kaspar030/turo_json_fixes
turo: some json fixes
2021-10-22 10:48:29 +02:00
99dbed9ce7 turo: fix json toru_float() precision value 2021-10-21 13:02:48 +02:00
1c8a8bf6c4 turo: add space after JSON comma 2021-10-21 13:02:21 +02:00
Karl Fessel
c9f4d11c52
Merge pull request #16966 from yarrick/net_v6
sys/net: Add ipv4/ipv6 pseudomodules

to ease code unification
2021-10-20 11:58:26 +02:00
0486c0dba7
Merge pull request #17001 from kaspar030/support_picolibc_stdio_globals
sys/picolibc_syscalls_default: support new picolibc stdio globals
2021-10-20 12:17:14 +03:00
Martine Lenders
44927b493f
Merge pull request #16967 from miri64/dsm/enh/peer-sync
dsm: rename DTLS_PEER_MAX and make it dependent on CONFIG_DTLS_PEER_MAX
2021-10-18 16:27:26 +02:00
27b9c6da06 sys/picolibc_syscalls_default: support new picolibc stdio globals 2021-10-18 12:02:33 +02:00