Commit Graph

374 Commits

Author SHA1 Message Date
Richard Hughes
ee2e2c3674 uefi: Rename to uefi-capsule
Rename the plugin to make it clearer of the scope.

Based on a patch from Mario Limonciello <mario.limonciello@dell.com>
2021-01-05 15:31:22 +00:00
Richard Hughes
32d36a0bf5 Release fwupd 1.5.4 2020-12-16 12:52:28 +00:00
Mario Limonciello
a7d1530385 fu-util: Add a new --no-remote-check to ignore checking for download remotes
This fixes the overloaded `--no-metadata-check` that was previously
present from being used in multiple instances.
2020-12-14 12:52:38 -06:00
Mario Limonciello
89a2f190b6 trivial: fwupd-refresh: don't add --no-metadata-check
This is implied because the service is started non-interactively
by systemd.
2020-12-14 12:52:38 -06:00
Richard Hughes
e300ca513f Release fwupd 1.5.3 2020-12-08 09:48:10 +00:00
Richard Hughes
caa1be6a62 trivial: Add device test for Lenovo USB-C Dock Gen2 2020-11-30 08:59:46 +00:00
Richard Hughes
b0cb62fa49 trivial: Add device test for HP USB-C Dock G5 2020-11-30 08:58:18 +00:00
Richard Hughes
c21cff1c04 Release fwupd 1.5.2 2020-11-23 15:49:53 +00:00
Mario Limonciello
2f49da7f4e libfwupd: Restore recognizing gpg and pkcs7 types still
The snap-store intends to ship an updated libfwupd library but
to use it with whatever version daemon is on the host system.

This means that the library needs to still work with older metadata
signing types.

This fixes the following error in that scenario:
```Failed to update metadata for lvfs: Keyring kind jcat not supported```
2020-11-21 07:37:36 -06:00
Richard Hughes
8b035b01fe trivial: Add device tests for the Dell KH08P 2020-11-20 09:59:15 +00:00
Mario Limonciello
5258f33585 trivial: fix ppc64le autopkgtest failure
nvme-self-test only runs if nvme is compiled, which it isn't for
ppc64le.
2020-11-18 08:21:00 +00:00
Emily Miller
937f7401c0 trivial: Add vli tr_gen2 and hyper regression test 2020-11-16 09:28:46 +00:00
Mario Limonciello
db15442c7c trivial: installed-tests: skip tests requiring network by default
Most of the installed tests will skip if files needed to be fetched
from network are not available.  Do the same thing for fwupdmgr
tests.

Fixes: #2566
2020-11-09 15:11:30 -06:00
Richard Hughes
fa11ceae9c trivial: Use the Mini Dock example archives provided by VLI 2020-11-09 09:57:13 +00:00
Richard Hughes
bbb1a8136e Release fwupd 1.5.1 2020-11-02 14:52:43 +00:00
Richard Hughes
203ed841da trivial: Codespell fixes 2020-11-02 14:26:26 +00:00
Richard Hughes
f9fcf47749 trivial: Add device tests for the Lenovo 40au0065 device 2020-11-02 12:01:41 +00:00
exploide
0c10507219 trivial: fix description of unblock-firmware 2020-11-01 20:00:23 +00:00
exploide
7f2ab39c98 updated fish completions to 1.5.0 2020-11-01 17:23:16 +00:00
Richard Hughes
a78b13fb71 Use a different Device ID for the OptionROM devices
We want to continue to dedupe the ID, and the priority should be decided on the
GUID match.

Fixes https://github.com/fwupd/fwupd/issues/2510 in a different way
2020-10-29 14:01:25 +00:00
Richard Hughes
f90cda6f0b Release fwupd 1.5.0 2020-10-26 11:50:11 +00:00
Richard Hughes
b619245897 trivial: Write up some release notes for the next release 2020-10-22 12:45:08 +01:00
Mario Limonciello
02f2cc311e Add switch-branch support to fwupdtool 2020-10-21 12:00:55 -05:00
Richard Hughes
7bcb8d4385 Export FwupdPlugin so we can convey enumerated system errors to the end user
For instance, we can tell the user that UEFI UpdateCapsule is disabled in the
system firmware, or that efivarfs is not mounted. This is much better than
creating "dummy" devices which are really just hacks around the problem because
no better API existed. THe dummy devices cause as many problems as they solve.

Plugins have to set FWUPD_PLUGIN_FLAG_USER_WARNING if a warning should be shown
to the user, and only one warning will be shown of each failure type.

It is expected that GUI clients like gnome-software and gnome-firmware would use
this API to notify the user the localized message for why firmware updates are
not being shown.

Fixes https://github.com/fwupd/fwupd/issues/2456
2020-10-13 15:56:49 +01:00
Mario Limonciello
02d9d23f13 trivial: fix shutdown error on fwupdtool activate
EXIT_NOTHING_TO_DO needs to be caught by the shutdown script too.
Fixes: #2463
2020-10-12 09:06:30 -05:00
Richard Hughes
6450d0deb4 Add FwupdInstallFlags of _IGNORE_CHECKSUM, _IGNORE_VID_PID and _IGNORE_POWER
The FWUPD_INSTALL_FLAG_FORCE flag has really unclear semantics, and ignoring a
file CRC, checksum or model ID should only be done when using fwupdtool actually
debugging a plugin or firmware parser.

Use the existing --force flag when we want a "gentle nudge" like reuploading
previously processed reports.
2020-10-07 13:15:09 +01:00
Richard Hughes
5bbf013879 Add a --allow-branch-switch to fwupdmgr
This allows us to turn off the tests like version format differences and
checking for downgrades.
2020-10-07 13:15:09 +01:00
Mario Limonciello
406025ba56 trivial: ci: fix installed-tests for test plugin
This has been broken for a while and missed various changes.
* Reading firmware version
* Passing `-y` into build
* New verify / verify-image split
2020-10-06 13:34:41 -05:00
Richard Hughes
10c3fd2ff9 Support loading DMI data from DT systems
To do this with the existing codebase just fake the required SMBIOS structures.
2020-09-30 19:22:45 -05:00
Richard Hughes
460c4b75fe Add the concept of firmware 'branches'
This allows a device to identify with different streams, for instance a Lenovo
laptop could have a coreboot firmware or a AMI firmware. The GUIDs would be the
same, but switching firmware would only be done rarely and very carefully.

Another example would be switching the Broadcom BCM57xx nework adaptors from the
vendor nonfree firmware with a signed PXE image, to the free software reverse
engineered driver with no PXE support (and thus no signed DXE) at all.

It is expected firmware would have additional metadata something like this:

    ...
    <branch>sdcc</branch>
    <description>
      <p>
        This is an alternate firmware built by the community using only free
        software tools.
      </p>
    </description>
    <requires>
      <id compare="ge" version="1.5.0">org.freedesktop.fwupd</id>
      <client>switch-branch</client>
    </requires>
    ...

Additionally, alternate branch firmware will not be returned for clients not
setting the FWUPD_FEATURE_FLAG_SWITCH_BRANCH before the GetReleases request.
2020-09-30 18:33:00 +01:00
Daniel Campello
9fbd7fe65d Allow to filter get-updates on device-id
This change allows to get available updates for a given device. This is
similar to what is done for the update and activate commands.
2020-09-28 16:43:42 -05:00
Richard Hughes
fbd8b5d325 Add fu_device_dump_firmware()
Conceptually we were trying to stuff subtly different actions into one vfunc:

 * Read firmware from the device to update the verification checksums

 * Read a firmware blob from the device for debugging

For the first action we might want to mask out the sections of the flash with
serial numbers (so the verification hashes match the ones published on the LVFS)
and for the second we want just a raw ROM file from the hardware with no
pre-processing that we can compare against an external SPI dumper.

Split out ->dump_firmware to get the raw blob, and allow plugins to also
implement ->read_firmware() if they have to mask out specific offsets or remove
specific images from the FuFirmware container.

In the common case when masking is not required, fall back to using a 'binary'
FuFirmware automatically to make most plugins simpler.
2020-09-24 10:54:27 -05:00
Richard Hughes
0924c93422 Do not use firmware-convert to build firmware
Copying the images from the src to the destination meant we could never set
properties on the new FuFirmware instance or subclass.
2020-09-23 15:22:31 +01:00
Richard Hughes
dd65344dde Add firmware-extract subcommand to fwupdtool 2020-09-22 12:11:38 +01:00
Richard Hughes
34f7d9d8fb Allow binding and unbinding kernel drivers 2020-09-21 20:07:54 +01:00
Richard Hughes
7ef2dea271 optionrom: Test if the PCI device has ROM in probe
This means we make things a simpler by not relying on udev to stat the file.
It also reduces the number of added *unused* GUIDs by one per device too.
2020-09-20 19:11:44 +01:00
Richard Hughes
b9ef4399c9 Remove unused udev rules
We used these before we had the quirk files, and now with all the VLI devices
supported in the quirk files these entries do nothing at all.
2020-09-20 19:11:44 +01:00
mendel5
75810207dc flag_require_ac: System requires external power source 2020-09-20 12:08:52 -05:00
Richard Hughes
5c82b94322 Do not show HSI obsoleted attributes by default
When one result is obsoleted by another, then do not show the old result by
default.

Additionally hide the HSI URLs as this was designed more for GUI clients like
gnome-firmware than CLI tools such as fwupdmgr.
2020-09-14 09:58:46 -05:00
Mario Limonciello
5de5dd3582 Install the installed tests
Move binaries out of fwupd tree to https://github.com/fwupd/fwupd-test-firmware

Fixes some of https://github.com/fwupd/fwupd/issues/1956
2020-08-28 10:10:43 -05:00
Richard Hughes
a83deb42b5 Add commands to fwupdtool for interacting with the ESP 2020-08-12 18:35:15 +01:00
Richard Hughes
3120683143 Allow blocking specific firmware releases by checksum
Fixes https://github.com/fwupd/fwupd/issues/2280
2020-08-10 17:14:15 +01:00
Richard Hughes
b76b4f8deb trivial: Make the bash completion script reflect reality 2020-07-29 15:05:15 +01:00
Richard Hughes
5bfa7bf808 trivial: Add a device test for the Thelio Io device 2020-07-28 16:01:47 +01:00
Richard Hughes
ff0dc24e54 trivial: Add some documentation for the ApprovedFirmware config key 2020-07-09 12:52:38 +01:00
Richard Hughes
85226fd9d1 Remove potentially problematic language
Red Hat wants to drive an initiative in correcting problematic and potentially
divisive language in open source projects. These naming conventions and
descriptive phrases are hurtful and offensive to many of our colleagues across
the open source universe.

See https://www.redhat.com/en/blog/making-open-source-more-inclusive-eradicating-problematic-language
2020-06-30 17:31:17 +01:00
Richard Hughes
9bc9debd98 Allow uploading security attributes to the LVFS
We sign the data with the client cert to allow users with LVFS accounts to
publish 'official' HSI ratings.
2020-05-21 11:48:09 +01:00
Richard Hughes
196c6c69db Add support for the Host Security ID
The HSI specification assigns a simple text ID to the current state of firmware
security. As new vulnerabilities are found, and as protection measures are
updated, new requirements will be added to the required firmware behaviours for
each HSI value.

The HSI specification is currently incomplete and in active development, and
so the --force flag is required in all command line tools. The current ID value
will probably change on a given platform so please do not start using the result
for any kind of compliance requirements.
2020-05-11 22:11:49 +01:00
Mario Limonciello
3838b22a7c trivial: add missing changelog entry for 1.3.9
This release came out after 1_3_X branched but long before 1.40 release
so these entries are confusing to be missing.
Fixes: #2059
2020-05-05 13:14:22 -05:00
Richard Hughes
86f6324a26 Switch the default of EnumerateAllDevices to false
This was causing dozens of regressions to be reported.
2020-05-03 06:47:40 +01:00