Commit Graph

154 Commits

Author SHA1 Message Date
Richard Hughes
63fa4effd3 pci-mei: Check the ME device is not in manufacturing mode 2020-05-15 21:28:27 -05:00
Mario Limonciello
8b5bcbb9e3 Add a new plugin for IOMMU support 2020-05-15 11:32:51 -05:00
Richard Hughes
8fdefd459b pci-bcr: Read the PCI BCR config register from userspace
We can read this from userspace even when SB is turned on and with the kernel
locked down. The kernel securityfs patches are still in-progress, but will take
significant time to get upstream.

The kernel patches are needed when the PCI device is hidden from userspace.
2020-05-15 10:21:07 +01:00
Richard Hughes
b9640a28ec uefi-dbx: Add a plugin that analyses the UEFI dbx variable
This will be used for future functionality.
2020-05-07 16:59:36 +01:00
Mario Limonciello
22306055e3 trivial: enable libjcat from Debian & Ubuntu distro builds 2020-04-08 10:32:34 -05:00
Mario Limonciello
e4fa62b1d1 trivial: contrib: drop Jared from uploaders 2020-04-01 16:51:42 -05:00
Richard Hughes
d5aab65f30 Use Jcat files in firmware archives and for metadata
A Jcat file can be used to store GPG, PKCS-7 and SHA-256 checksums for multiple
files. This allows us to sign a firmware or metadata multiple times (perhaps
by the OEM and also then the LVFS) which further decentralizes the trust model
of the LVFS.

The Jcat format was chosen as the Microsoft catalog format is nonfree and not
documented. We also don't want to modify an existing .cat file created from WU
as this may make it unsuitable to use on Windows.

More information can be found here: https://github.com/hughsie/libjcat
2020-03-23 19:55:12 +00:00
Mario Limonciello
16eea10554 ci: build Debian using libflashrom
The package is now in unstable in the 1.2-4 package.
2020-03-05 17:07:28 -06:00
exploide
c33fbb5002 added completion script for fish shell 2020-02-29 16:31:50 +00:00
Mario Limonciello
93d6131d0e trivial: debian: fix build for systems without UEFI
Just dynamically find the binaries in usr/bin rather than hardcoding
2020-02-21 10:39:55 -06:00
Mario Limonciello
9fa7b38ac1 Move fwupdtpmevlog into bindir 2020-02-20 09:02:11 -06:00
Mario Limonciello
21e7faa78b uefi: Move fwupdate into bindir
Intended to be executed by users for debugging purposes, create a man
page as well.
2020-02-20 09:02:11 -06:00
Mario Limonciello
bf6d455687 Move fwupdtool and fwupdagent into bindir
These are intended to be executed by users (albeit for debugging and
advanced users) and shouldn't be left as an internal implementation
per FHS 3.0.
2020-02-20 09:02:11 -06:00
Laurent Bigonville
81e359199b Move the daemons from /usr/lib/fwupd to /usr/libexec/fwupd
This is supported since debian policy version 4.1.5 (FHS 3.0)
2020-02-18 11:22:58 -06:00
Laurent Bigonville
022d4fa708 debian/control.in: Add libglib2.0-doc to Build-Depends-Indep
This allows the links between the documentations files to be properly
generated
2020-02-18 11:22:58 -06:00
Mario Limonciello
026f0e0d28 trivial: contrib/debian: Add a diff ignore for vscode in debian packages 2020-02-14 10:31:47 -06:00
Mario Limonciello
df6a9464d5 trivial: contrib/debian: refresh standards version 2020-02-14 10:31:45 -06:00
dann frazier
b25be977a9 trivial: debian: Don't use --parents when rmdir'ing /var/*/fwupdate
Calling 'rmdir --parents /var/cache/fwupdate' will cause it to attempt
to rmdir /var/cache and /var. Those directories are very unlikely to be
empty, so it should always quietly fail. However, there's not benefit
in attempting those removals, so let's quit doing it.
2020-01-21 17:52:28 -06:00
Mario Limonciello
31c08120b9 trivial: debian: Add explicit cleanup for fwupdate->fwupd transition
It's possible that someone has removed fwupdate package prior to the
fwupd transition meaning that they might have some artifacts left
behind from fwupdate packaging.  Clean up these artifacts.

This commit can be reverted after both Debian bullseye and Ubuntu
focal have been released.
2020-01-09 09:01:15 -06:00
Richard Hughes
f5c6e1d276 Add a new plugin that can parse the TPM event log
Some devices do not have a stable PCR0 for the same firmware version, and I'd
like to collect the TPM event log for affected machines to debug why.
2019-12-06 15:05:16 +00:00
Richard Hughes
297d1598ef trivial: Only dlopen the test plugin once
This causes problems in the self tests when not lazy-loading symbols.

Also use g_build_filename() for the paths to be more portable and readable.
2019-12-01 20:59:19 +00:00
Mario Limonciello
f12e471414 trivial: ci: debian: enable verbose daemon logging for failure analysis 2019-12-01 06:23:27 -06:00
Mario Limonciello
f35a3dec93 trivial: debian: remove obj-* built files to fix back to back builds 2019-11-30 18:56:09 -06:00
Mario Limonciello
0f67b79cc5 trivial: debian: correct a dependency for libfwupdplugin-dev 2019-11-30 18:34:56 -06:00
Mario Limonciello
11503c23ee Install development files for libfwupdplugin
This splits out all development files, including headers into their
own packages where relevant.

Notably absent is `fu-hash.h` which is used for determining taint.
Out of tree developed plugins should still taint the daemon.
2019-11-27 11:32:43 +00:00
Mario Limonciello
6b0e66354b Convert libfwupdprivate to a shared library libfwupdplugin 2019-11-27 11:32:43 +00:00
Mario Limonciello
4fcf48606f trivial: debian: ci: ignore library-not-linked-against-libc for more 2019-11-23 20:18:36 +00:00
Mario Limonciello
e62db1bc57 trivial: debian: remove some unneeded lintian 2019-10-28 10:43:43 -05:00
Mario Limonciello
ea10d7b14e trivial: debian: bump compat version 2019-10-28 10:43:43 -05:00
Mario Limonciello
e7b2ea02b9 uefi: use genpeimg to mark ASLR and DP/NX on EFI binary
If the tool is available at build time use it to this.
2019-10-26 12:59:11 -05:00
Mario Limonciello
0b9bfec150 Add a systemd preset file for fwupd-refresh.service
Makes `fwupd-refresh.service` strictly opt-in.

Some distros are defaulting to all systemd services on and causing
more refreshes than desirable by default, especially when using
both `gnome-software` and `fwupd-refresh.service`
2019-10-20 14:31:13 -05:00
Mario Limonciello
71d4b08445 trivial: debian: remove more conffiles from transitions (Closes: #932617) 2019-10-06 21:05:02 -05:00
Mario Limonciello
1ff1164630 trivial: debian/control*: Update for fwupdate transition
Per Steve's recommendation:
 1. In fwupd, add Provides/Replaces, plus Conflicts: against the older
    versions of fwupdate-*-signed. That will tell apt to upgrade
    cleanly and thereby switch to fwupd instead. See
    https://www.debian.org/doc/manuals/developers-reference/ch05.html#s5.9.3
2019-10-06 21:00:24 -05:00
Mario Limonciello
dc7e7c3808 trivial: fwupd-refresh: fix a clash with fwupd.service (Closes: #941360)
`fwupd-refresh.service` uses `DynamicUser=true` which causes systemd
to make `/var/cache/fwupd` a symlink to `/var/cache/private/fwupd`.

Individual units aren't allowed to access this directory, only the ones
with the directive.  This means that `fwupd.service` stops working as
soon as a user tries to start `fwupd-refresh.service`.

The bug details are present in
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=941360
2019-09-30 14:09:18 -05:00
Jonas Witschel
1b5f1da202 uefi: use tpm2-tss library to read PCR values
Using the library instead of the command line tools provides a more
stable interface. This implementation only fetches PCR 0 for all
available hash algorithms since this is the only PCR that is actually
used in fwupd.
2019-08-27 06:23:42 -05:00
Mario Limonciello
805f7990f3 trivial: disable gtkdoc by default
Since https://fwupd.github.io is now a thing, people can be directed there
rather than relying upon locally built documentation by default.

Also this will mean one less dependency to install for people who build
from source.

Lastly this finally means that I can do this set of actions without failure:
```
meson build
ninja -C build
ninja -C build install (PK prompts for password)
rm -rf build
```

Previously gtkdoc stuff was built as root due to the PK prompt and removing
it would lead to stuff like this:
```
rm: cannot remove 'build/docs/libfwupd/html/libfwupd-FwupdClient.html': Permission denied
```
2019-08-23 10:54:54 -05:00
Mario Limonciello
71d2f62dc2 trivial: update references of hughsie/fwupd to fwupd/fwupd 2019-08-22 09:47:52 -05: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
Mario Limonciello
09700bbce8 trivial: debian: For signed package fill out Built-Using (Closes: #932757) 2019-07-22 15:23:56 -05:00
Mario Limonciello
8837da60fa trivial: ci: debian: Only turn on flashrom when running CI
This will prevent normal debian builds from turning it on until it
has been packaged.
2019-07-07 14:29:48 -05:00
Artur Raglis
13fd21d806 flashrom: Use libflashrom
This also means we now include a flashrom subproject as no distro currently has
a flashrom new enough to build the plugin.

Signed-off-by: Richard Hughes <richard@hughsie.com>
Signed-off-by: Artur Raglis <artur.raglis@3mdeb.com>
Signed-off-by: Maciej Pijanowski <maciej.pijanowski@3mdeb.com>
2019-06-28 08:28:51 +01:00
Mario Limonciello
2df922c23d Move the core built-in 'fwupd' remote over to the dell-esrt plugin
This metadata is useless to other systems, so if compiling a custom
fwupd without -Dplugin_dell=true it shouldn't be included.
2019-04-02 07:18:29 -05:00
Steve McIntyre
c8de6b6398 trivial: debian: Update the format of the json metadata to match new requirements
* Move all the data under a new top-level "packages" key
* Add an empty "trusted_certs" key - our binaries do not do any
  further verification with an embedded key.
2019-03-11 17:06:21 -05:00
Richard Hughes
4499d19ba3 Move out the offline update functionality to a new binary
The offline updates environment is special, and we have to be careful to delete
the trigger before doing anything that can fail to avoid boot loops.

For this reason, split it out to a simple self-contained binary that is easy to
understand.
2019-03-08 09:45:30 -06:00
Richard Hughes
5806867ebe Add the fwupdagent binary for use in shell scripts
This currently just outputs the current list of devices with releases and makes
it possible to integrate firmware version reporting with other tools like mgmt.
2019-03-06 13:15:55 +00:00
Richard Hughes
ffa3b84706 Add a plugin to support ModemManager hardware 2019-02-27 16:09:13 +00:00
Mario Limonciello
96a0dd5606 Add a support for delayed activation
This is intended for devices that it is not safe to immediately activate
the firmware.  It may be called at a more convenient time instead.

Both fwupdmgr and fwupdtool support the feature.

- if called at runtime with fwupdmgr it uses the daemon
- during shutdown fwupdtool uses the pending.db to perform this feature.
2019-02-27 09:04:54 +00:00
Mario Limonciello
dc845bec2b trivial: debian: override newer lintian for missing ASLR on PE executable 2019-02-25 16:59:29 -06:00
Richard Hughes
97293c4560 Show in Flathub correctly
For this we need to register as a console application (which fwupdtool is, I
suppose) and also supply a usable icon.

I've used the new GNOME icon theme guidelines so please add a drop shadow
before using: https://gitlab.gnome.org/GNOME/Initiatives/issues/2
2019-02-15 12:32:46 +00:00
Mario Limonciello
9772f8aca6 debian: explicitly depend on shared-mime-info
This helps autopkgtest issue:
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=922331
2019-02-14 21:34:43 -06:00