Commit Graph

18 Commits

Author SHA1 Message Date
Richard Hughes
6de10e118c Allow downloading firmware from IPFS
Only a small amount of the firmware on the LVFS will be available. The user
can use --ipfs on the command line for testing, or change the system-wide
default in /etc/fwupd/daemon.conf.

The IPFS daemon and command line client will need to be installed manually.
2021-02-01 19:33:31 +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
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
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
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
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
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
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
428ed8a0b2 trivial: Fix bash completion
`get-devices` and `get-remotes` output changed in the past.
It would be ideal to use `jq` instead, but it's not available by
default in most distros.
2020-03-04 08:03:19 -06:00
Mario Limonciello
d81ea2e3fc Move MOTD population into the daemon
This allows it to be refreshed anytime the daemon updates rather
than once a day by a systemd job.

As part of this change, remove the logging from `fwupdmgr` which
was only used for motd purposes.
2020-01-16 10:33:43 -06:00
Mario Limonciello
98b951688a Use device safety flags to show prompts before installing updates 2019-10-30 11:30:36 -05:00
Mario Limonciello
d837ca8c28 fu-util: add support for a reinstall command 2019-10-03 08:16:41 -05:00
Richard Hughes
0e46b22728 Allow disabling SSL strict mode for broken corporate proxies 2019-09-05 19:14:38 +01:00
Mario Limonciello
dfff18e3e8 Add aliases for get-upgrades and upgrade
Mostly for consistency purpose.  Details:
* It's confusing that internally the functions for `FwupdClient` use
`upgrade` in the name.
* The logical antonym of `downgrade` is `upgrade` not `update`
* People who don't use the tool frequently may try `get-upgrades`
2019-08-29 19:14:55 +01:00
Mario Limonciello
b390b14f8f Add support to integrate into the motd (Fixes: #1270)
Fixes Debian bug https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=921820

Introduce a new --log option to fwupdmgr that will log stdout to an argument.
If run under systemd, prefix that argument with $RUNTIME_DIRECTORY.

Add a new systemd unit and associated timer to regularly refresh metadata.
After the metadata refresh is complete, save the output to the motd location.

The timer and service are disabled by default and can be enabled by an admin.
2019-08-22 06:39:02 +01:00
Richard Hughes
747f570310 Allow filtering devices when using the command line tools 2019-08-06 20:59:28 +01:00