Richard Hughes
3b84753769
Use help2man to generate the man page at build time
...
The man pages are always old and out-of-sync with the actual tool, so just
generate them using the output of --help.
Fixes https://github.com/hughsie/fwupd/issues/285
2017-10-23 16:47:08 +01:00
Richard Hughes
7f6d78fb1b
Add fwupd_remote_get_checksum() to use in client programs
2017-09-28 09:23:52 +01:00
Richard Hughes
b2fb80925c
trivial: Remove fwupd_remote_get_filename()
...
The data for these was just being generated internally based on the ID and the
basename of the original URI, and that's easy for the calling application to do
itself.
2017-09-28 09:23:52 +01:00
Richard Hughes
80893e29fe
trivial: Remove FwupdResult from libfwupd
2017-09-28 09:23:52 +01:00
Richard Hughes
b86ef97b36
trivial: Remove fwupd_remote_build_uri()
...
This also removes the long-deprecated fwupd_remote_get_uri() and fwupd_remote_get_uri_asc()
2017-09-28 09:23:52 +01:00
Richard Hughes
ba73c76d69
trivial: Remove the deprecated fwupd_client_update_metadata()
...
Also, rename fwupd_client_update_metadata_with_id() to it's now-removed counterpart.
2017-09-28 09:23:52 +01:00
Richard Hughes
07f963a52d
trivial: Remove the deprecated fwupd_client_get_details()
...
Also, rename fwupd_client_get_details_local() to it's now-removed counterpart.
2017-09-28 09:23:52 +01:00
Richard Hughes
eb94c14022
trivial: Remove the deprecated fwupd_client_get_devices()
...
Also, rename fwupd_client_get_devices_simple() to it's now-removed counterpart.
2017-09-28 09:23:52 +01:00
Richard Hughes
820dac7fde
trivial: Use a different SYSFSFIRMWAREDIR for self tests
...
This means we can drop some self-test specific code in fu_smbios_setup().
2017-09-16 17:46:41 +01:00
Richard Hughes
f11fa3caac
trivial: Use the new fwupd_client_get_upgrades() in fwupdmgr
2017-09-15 14:12:18 +01:00
Richard Hughes
97284b1ad8
Move the downgrade calculation to the daemon
2017-09-15 14:12:18 +01:00
Richard Hughes
6ab53111db
Never fallback to an offline update from client code
...
UEFI updates don't need to be retried since a785a1c
. If the call to Install()
failed with NOT_SUPPORTED we can just show the error rather than doing the
little dance and involving the offline pending database for no reason.
Fixes some of https://github.com/hughsie/fwupd/issues/255
2017-09-15 09:35:27 +01:00
Richard Hughes
31bbd1691b
Add a command 'clear-offline' to fwupdmgr
...
This allows us to 'unschedule' any offline updates.
2017-09-15 09:33:06 +01:00
Richard Hughes
ba15eebabb
trivial: Show the RemoteID when printing available releases
2017-09-14 10:26:15 +01:00
Richard Hughes
a1aab517d1
Move the update state to FwupdDevice
...
It only remained on FwupdResult because I couldn't make up my mind about whether
it was a property of the device, or the firmware release. It's more logically
the former, and that's how plugins are using it.
2017-09-13 14:59:32 +01:00
Richard Hughes
48ad97fd61
Add a human-readable title for each remote
...
This allows us to show something useful in a GUI.
2017-09-10 09:08:32 +01:00
Richard Hughes
a6bd5580d3
Add ModifyRemote as an easy way to enable and disable remotes like the LVFS
...
For example:
$ fwupdmgr modify-remote lvfs-testing Enabled true
2017-09-07 23:02:58 +01:00
Richard Hughes
49e5e05aa8
Parse the SMBIOS DMI table directly
...
The Linux DMI class still does not provide the information we need, and parsing
the blob directly also allows the Dell and Redfish plugins to get the raw data.
2017-09-05 18:10:36 +01:00
Richard Hughes
f315719851
trivial: Fix up a literal format string in fwupdmgr
2017-08-31 20:00:01 +01:00
Richard Hughes
1f92addd10
trivial: Remove unused function in fwupdmgr
...
Fixes 2nd half of https://github.com/hughsie/fwupd/issues/209
2017-08-30 10:51:51 +01:00
Richard Hughes
c6afb51e32
Add a FirmwareBaseURI parameter to the remote configs
...
This allows somebody to mirror the CDN without resigning the metadata files.
Fixes: https://github.com/hughsie/fwupd/issues/186
2017-08-23 14:22:12 +01:00
Richard Hughes
0dea1efb92
Use MetadataURI for both kinds of remote
...
I think this is clearer having one key for both types of remote.
2017-08-23 14:22:08 +01:00
Richard Hughes
9a7db9df7d
Show a bouncing progress bar if the percentage remains at zero
...
Device actions like a Thunderbolt replug can take 25 seconds (!) and so it's a
good idea to show the user that the calling process is still alive.
2017-08-21 15:51:38 +01:00
Richard Hughes
99e621d388
Save the metadata signature in the local cache
...
This is useful if the admin wants to re-verify the metadata, or if a public
key is removed or expires.
2017-08-16 13:42:10 +01:00
Richard Hughes
7ee42feb83
trivial: Add common function for making required parent directories
2017-08-15 15:35:36 +01:00
Richard Hughes
7403dc505f
Optionally use GnuTLS to verify PKCS7 certificates
...
We can use this as an alternative for GPG. No PKCS7 certificates are currently
installed by fwupd and it's expected that the LVFS will still only provide GPG
detached signatures.
If an OEM distributor wants to sign firmware with a PKCS7 and the corresponding
certificate is provided then the firmware will be marked as valid.
Only firmware shipping with a .p7b file will use the PKCS7 functionality,
similarly remote metadata validation will default to GPG unless Keyring=pkcs7
is specified in the config file.
2017-08-14 09:42:48 +01:00
Richard Hughes
0724d8bde0
trivial: Bump the appstream-glib requirement to 0.6.13
2017-08-09 17:21:48 +01:00
Richard Hughes
41cbe2aab3
Add a firmware builder
...
This runs a script inside the firmware archive to generate firmware specific to
the machine. This uses bubblewrap to protect the local machine.
2017-08-09 10:33:39 +01:00
Richard Hughes
2d95a71a0c
Support embedded devices with local firmware metadata
...
In this mode, both the metadata and firmware is stored on the local filesystem
and distributed using a distribution system like OSTree.
Fixes https://github.com/hughsie/fwupd/issues/162
2017-07-28 17:41:24 +01:00
Richard Hughes
ba51279752
trivial: Fix two tiny leaks in fwupdmgr
2017-07-27 16:32:43 +01:00
Mario Limonciello
9ac53e28b1
Add information about compile-time dependency versions
...
Since the codebase looks at these versions for turning on and off
functionality it will be useful to use this for debugging
2017-07-24 15:30:28 -05:00
Mario Limonciello
dc8c985159
trivial: back the requirement on appstream-glib to 0.6.9
...
The items that 0.6.13 requires are now guarded by a version test.
This should allow running fwupd master on more distros that haven't
yet picked up appstream-glib 0.6.13.
2017-07-10 14:32:42 -05:00
Richard Hughes
b3dca14e90
trivial: Never compare a string against zero to avoid warnings
2017-07-06 18:28:01 +01:00
Mario Limonciello
b04c13e1cf
Include optional git checkout information in --version
...
When users are running from git this should aide in
debugging if they have a fix included.
2017-07-05 17:49:50 -05:00
Richard Hughes
89483f1bb9
Add --version option to fwupdmgr
...
$ fwupdmgr --version
client version: 0.9.6
daemon version: 0.9.6
Fixes https://github.com/hughsie/fwupd/issues/153
2017-07-04 20:49:27 +01:00
Richard Hughes
b53ad36012
trivial: Fix up a number of FALSE/NULL return issues
2017-06-19 13:50:42 +01:00
Richard Hughes
feb8027ee3
Show the age of the remote metadata in 'fwupdmgr get-remotes'
...
Note: we have to transfer the mtime (not the age) when creating the GVariant,
as we want calls to fwupd_remote_get_age() to update the value without getting
the remote from the daemon each time.
2017-06-16 20:24:41 +01:00
Richard Hughes
0a87f6fb03
Store the metadata files rather than merging to one store
...
Now we have multiple remotes that can be enabled or changed at runtime we need
to do several things better:
* Only load components from remotes that are enabled
* Only load a component if a higher priority remote has not already added it
Rather than just appending all recieved metadata into one big XML file, save
the original metadata .xml.gz files in /var/lib/fwupd/remotes.d and only load
them in the correct priority order if the remote is known and enabled.
Remove the old /var/cache/app-info/xmls/fwupd.xml file, also noting it wasn't
really a cache file at all but actually something quite important.
2017-06-16 16:43:13 +01:00
Richard Hughes
4c36970445
Move the remotes parsing from the client to the server
...
This allows us to load the metadata stores in a more sensible way in the future.
2017-06-16 15:31:40 +01:00
Richard Hughes
f0bde3e4af
Add a get-remotes command to fwupdmgr
...
This allows the user to show the configured remotes.
2017-06-16 14:31:20 +01:00
Richard Hughes
bbde1df44f
Fix downgrades when version_lowest is set
...
Also, add some tests to test this with the dummy device.
2017-06-16 12:40:15 +01:00
Richard Hughes
8a870d0399
trivial: Ensure there are no updates after the update is applied
2017-06-16 12:40:10 +01:00
Richard Hughes
954de52612
trivial: Make --verbose work in fwupdmgr
2017-06-16 07:59:02 +01:00
Richard Hughes
40aeea4167
trivial: Show the release (not device) checksums in 'fwupdmgr get-updates'
2017-06-16 07:59:02 +01:00
Richard Hughes
c2a20d7fff
trivial: Show the release (not device) checksums in 'fwupdmgr get-releases'
2017-06-15 20:19:03 +01:00
Richard Hughes
109526bf34
trivial: Fix a harmless warning when building RPMs
2017-06-15 11:07:00 +01:00
Richard Hughes
18b73a4bdd
trivial: Return with exist code 0 when there is nothing to do
2017-06-14 15:16:06 +01:00
Richard Hughes
2899cb28d5
Show progress download when refreshing metadata
2017-06-13 16:31:18 +01:00
Richard Hughes
b86484a585
Export some more API for dealing with checksums
2017-06-09 10:11:58 +01:00
Piotr Drąg
748ae3154e
trivial: Fix a typo in a translatable string ( #132 )
2017-06-07 16:59:40 -05:00
Richard Hughes
cffef2654b
trivial: Include the device name in the output of 'fwupdmgr get-releases'
...
If only one device is present, then it's not obvious what this output refers to.
2017-06-07 15:34:53 +01:00
Richard Hughes
97fc78bbc3
trivial: Fix a harmless warning from clang
2017-06-07 15:34:53 +01:00
Richard Hughes
68cc00c7e9
Allow multiple checksums on devices and releases
...
Although we supported other hashes than SHA1 (which is now moderately unsafe)
we had to switch the metadata provider and daemon on some kind of flag day to
using SHA256. Since that's somewhat impractical, just allow multiple checksums
to be set on objects and just try to match whatever is given in preference
order.
This also means we can easily transition to other hash types in the future.
The removed API was never present in a tarball release, so not an API break.
2017-06-06 20:06:53 +01:00
Richard Hughes
7e206447a8
Use the user cache directory for firmware
...
We don't need to redownload this multiple times if we have multiple devices
needing the same firmware update.
2017-06-06 12:22:30 +01:00
Richard Hughes
81c7649dd8
libfwupd: Add fwupd_client_get_devices_simple() to return us an array of devices, not results
2017-06-06 11:10:57 +01:00
Richard Hughes
45c1545b0a
Add a 'downgrade' command to fwupdmgr
...
This allows the user to downgrade the firmware on a device.
2017-06-06 09:44:47 +01:00
Richard Hughes
224002ab38
Prompt for the device ID if nothing specified in get-releases
...
This makes it somewhat easier to use for the common case.
2017-06-06 09:34:46 +01:00
Richard Hughes
e4a100cfee
Add a GetReleases() D-Bus call to return all releases for a device
...
This allows us to downgrade firmware in the future.
2017-06-05 17:42:57 +01:00
Richard Hughes
1642b3b95a
Deprecate the old FwupdResult API
...
It will be removed next time we bump soname.
2017-06-05 17:41:11 +01:00
Richard Hughes
502a2ca64a
Do not re-download firmware that exists in the cache
2017-06-05 09:23:10 +01:00
Richard Hughes
b8f8db2082
Add support for Microsoft HardwareIDs
...
This commit provides a new "hwids" subcommand for fwupdmgr that shows the
hardware GUIDs on the local system. It also provides API that plugins can use
to self-disable when a specific HWID does not match.
The GUIDs used in this implementation match that of ComputerHardwareIds.exe
2017-06-04 19:46:36 +01:00
Richard Hughes
0b57806b68
Use the correct user and password for the firmware download
2017-06-02 13:19:08 +01:00
Richard Hughes
90bcd058f0
Return the remote ID when getting updates about hardware
2017-06-02 13:19:08 +01:00
Richard Hughes
1b50d960f2
Send the daemon the remote ID when sending updated firmware metadata
...
This allows us to 'tag' the components with the correct remote ID value, which
then means we can tell where the firmware information has come from when saving
a composite store. It also allows us use the correct username and password in
the future when downloading the firmware blob itself.
Keep the old D-Bus method around to preserve API for existing clients.
2017-06-02 13:19:05 +01:00
Richard Hughes
dfed515573
Allow downloading metadata from more than just the LVFS
...
Add the concept of 'remotes' that can dropped into /etc and used as firmware
metadata sources. This may be desirable when firmware is only accessable with
a valid support contract or from behind a VPN.
2017-06-02 13:19:05 +01:00
Eric Koegel
23603f0452
Add support for ConsoleKit2
...
Make systemd and ConsoleKit support an optional compile time flag
with both enabled by default. If both are used, the ifdef/elif will
ensure only the systemd calls are used so there's no conflict.
2017-06-01 09:00:16 +01:00
Richard Hughes
741dc5054a
trivial: Use g_autoptr for the fwupdmgr private data
2017-05-08 20:38:17 +01:00
Richard Hughes
df5652ffb5
trivial: Return a sensible error if DownloadURI is intentionaly left blank
2017-05-08 19:06:08 +01:00
Richard Hughes
860640e32a
trivial: Fallback to the system-wide config file if running from tree
2017-05-08 19:04:25 +01:00
Richard Hughes
b0fce88754
Do not spew a critial warning when parsing an invalid URI
2017-05-08 19:02:24 +01:00
Richard Hughes
ee401a17c4
Support proxy servers in fwupdmgr
2017-04-14 19:56:04 +01:00
Richard Hughes
da3ec457c4
Use a 60 second timeout on all client downloads
2017-04-14 19:46:57 +01:00
Richard Hughes
74702297b2
Move the Option ROM parsing to the Udev plugin
2016-12-15 17:09:38 +00:00
Richard Hughes
29c220db9f
Add VerifyUpdate to update the device checksums server-side
2016-12-15 17:09:37 +00:00
Mario Limonciello
e781bb9b64
trivial: fix cosmetic fallout from provider -> plugin
...
some code (such as libfwupd) still internally refers to provider,
but this will need to be more carefully massaged
2016-12-13 12:25:09 -06:00
Richard Hughes
cff38bcb3a
Convert the providers to plugins to simplify code and for future features
...
This is a large commit that removes all the providers and turns them into
plugins. I think having both providers _and_ plugins was super confusing.
Plugins are loaded at runtime so you could in theory develop a new plugin
without putting it in the fwupd source tree, although there are no installed
headers or PC files as I'm not sure it's a good idea at this stage.
This commit moves all the per-provider docs, tests, notes, debug dumps and test
data to plugin-specific directories -- these also allows the plugin author to
"own" more of the source tree so we don't enforce fu- prefixes and the style
guide everywhere.
This allows us to run the same action on all the plugins in the future, so we
could have a prepare(FuPlugin, FuDevice) and cleanup(FuPlugin, FuDevice) run
on *all* plugins, so doing an update using one plugin would allow us to work
around hardware quirks in other plugins.
If I've broken your out-of-tree provider it's trivial to port to the new API
with sed and a fixed up build file. If you need help please let me know.
2016-12-12 12:31:23 +00:00
Mario Limonciello
11dee100af
Clarify the test in --help and man page related to offline ( #69 )
2016-10-19 15:56:48 -05:00
Richard Hughes
da004cf318
Show a progress notification when installing firmware
2016-08-17 17:46:15 +01:00
Richard Hughes
876c007b1a
Allow providers to export percentage completion
2016-08-17 17:46:15 +01:00
Richard Hughes
33a518a615
Add another compile warning and fix up any build failures
2016-07-27 16:57:36 +01:00
Richard Hughes
f192bf025a
trivial: Switch to compiling with C99 by default
...
We're already using non-MSVC features like g_autoptr().
2016-07-22 08:41:59 +01:00
Richard Hughes
ce38d94d5e
trivial: Get rid of useless internal-only gtk-doc markup
2016-06-29 11:25:25 +01:00
Richard Hughes
7289a6b5f0
Add a GetDetailsLocal() method to eventually replace GetDetails()
...
This allows us to return multiple results from one file, for instance where the
firmware.cab file contains multiple metainfo.xml files.
This allows us to show all the entries in the firmware file, rather than
searching for the installed device that matches and falling back to just the
first listed item.
2016-05-29 09:57:24 +01:00
Richard Hughes
99147f180b
Allow devices to have multiple assigned GUIDs
2016-05-17 09:35:04 +01:00
Mario Limonciello
71a5b98d30
Add support for a --force flag to override provider warnings
...
Under some circumstances a provider may want to prevent a user from
performing a flash without additional user interaction.
Providers can opt into this behavior by checking for
FWUPD_INSTALL_FLAG_FORCE in the update routine.
2016-05-10 15:41:16 -05:00
Richard Hughes
8ca33784ec
Add device-added, device-removed and device-changed signals
...
This allows us to watch a specific device from client code without
re-requesting the device list on every Changed() signal.
2016-04-28 16:56:23 +01:00
Richard Hughes
cfc44fa0ae
Add a 'monitor' debugging command for fwupdmgr
...
This allows us to watch for signals from the daemon.
2016-04-28 16:56:23 +01:00
Richard Hughes
3c694baf2d
trivial: Make it clear the version from get-updates is an update version
2016-04-25 12:28:08 +01:00
Richard Hughes
1d3567056c
trivial: Fix alignment of multi-line update descriptions
2016-04-25 12:17:42 +01:00
Mario Limonciello
d9c234aeb3
trivial: update get-results error to be clearer
2016-04-14 13:44:01 -05:00
Richard Hughes
7105e42af8
trivial: Do not show the argument list for an internal error
2016-03-31 11:23:04 +01:00
Richard Hughes
b8956d41ee
Do not use /tmp for downloaded files
...
The files are signed but downloading into user-cachedir is probably safer.
2016-03-29 19:18:18 +01:00
Richard Hughes
b8f6b737e6
Show the checksum kind in the fwupdmgr output
2016-03-18 12:33:47 +00:00
Richard Hughes
48a5117fde
trivial: Allow different checksum types in FuRom
2016-03-18 12:33:47 +00:00
Richard Hughes
2d6e186800
Rename some of the new libfwupd API to align with the D-Bus names
2016-03-18 09:20:40 +00:00
Richard Hughes
cb07a3eb3f
Use FwupdClient from libfwupd in fwupdmgr
2016-03-17 10:09:03 +00:00
Richard Hughes
b94f2f0488
Export FwupdUpdateFlags in libfwupd
2016-03-17 09:52:00 +00:00
Richard Hughes
a475eecda2
Export FwupdUpdateState in libfwupd
2016-03-17 09:48:34 +00:00
Richard Hughes
6d39d37039
Show device flags in 'fwupdmgr get-devices'
2016-03-15 21:40:36 +00:00
Richard Hughes
65dfbfe54f
Do not use deprecated API from libappstream-glib
2016-03-02 13:43:21 +00:00
Richard Hughes
9a410ce459
Add an unlock method for devices
...
This is based on an idea from Mario Limonciello which can be used to enable a
PCI OptionROM read, or possibly enable ESRT functionality.
2016-03-02 10:17:02 +00:00
Richard Hughes
1d96633198
Add 'Created' and 'Modified' properties on managed devices
...
This allows us to show suitable UI in GNOME Software when reporting historical
firmware updates.
2016-01-27 13:25:45 +00:00
Richard Hughes
a2b2b1cc68
Export the AppStream ID when returning device results
...
This allows us to match up the AppStream data we've parsed in gnome-software and the firmware update we've got from fwupd. This means we can get access to some of the data that fwupd doesn't care about, for instance the how-to-upgrade screenshots.
2015-11-25 15:00:51 +00:00
Richard Hughes
b2fe639940
Use the correct user agent string for fwupdmgr
2015-11-05 08:48:48 +00:00
Richard Hughes
709d0114e3
Fix verify-update to produce components with the correct provide values
2015-10-09 12:17:08 +01:00
Richard Hughes
60f48c2013
trivial: Do no ship the old-style cleanup functions
2015-10-08 20:25:51 +01:00
Richard Hughes
2d32b8f0e9
trivial: Include the filename in the error when fwupd.conf is not found
...
This can happen if the user deletes it from /etc or is running inside a prefix
shell, e.g. jhbuild.
2015-09-28 13:56:42 +01:00
Richard Hughes
697eb60320
Ensure D-Bus remote errors are registered at fwupdmgr startup
...
Fixes: https://github.com/hughsie/fwupd/issues/31
2015-09-23 10:04:17 +01:00
Kalev Lember
1f819d7adc
offline update: Use glib api for for reading symlinks
...
readlink() man page says that applications must not rely on it returning
null-terminated links. This commit switches it to use g_file_read_link()
instead that has much nicer API and shields us from readlink() oddities.
2015-09-18 13:54:34 +02:00
Richard Hughes
f00f1e90ea
trivial: Do not show the D-Bus error prefix
2015-09-17 12:48:26 +01:00
Richard Hughes
c2da4b2580
Do not reboot if racing with the PackageKit offline update mechanism
...
The very first thing the PackageKit updater does is delete this symlink...
2015-09-14 12:15:41 +01:00
Richard Hughes
46832432ea
Raise the dep on GLib to support and use g_autoptr()
2015-09-11 13:43:15 +01:00
Richard Hughes
2257cee8ee
Simplify the version properties on devices to avoid complexity and bugs
...
This reduces the number of 'version' properties from 4 to 2... We can just use
these consistently to mean 'older' and 'newer'.
2015-09-08 16:53:49 +01:00
Richard Hughes
51f5083b09
Depend on appstream-glib >= 0.5.0
2015-09-08 16:53:49 +01:00
Richard Hughes
98dd640f41
Don't apply firmware if something else is processing the offline update
...
This also stops us rebooting the computer a few seconds into a PackageKit
offline update...
2015-08-25 14:07:48 +01:00
Richard Hughes
ac8b192033
Add a simple config file to store the correct LVFS download URI
2015-08-04 14:56:39 +01:00
Richard Hughes
c6ff8fa574
Move the verification and metadata matching phase to the daemon
...
This allows us to use the functionality in gnome-software or cockpit without
loading the system AppStream store.
2015-08-03 18:00:54 +01:00
Richard Hughes
9985a24a29
Fix validation of written firmware
...
It turns out comparing sha1{firmware.cab} and sha1{firmware.bin} doesn't match.
Require appstream-glib 0.5.x for the new API required to fix this.
2015-08-03 13:22:34 +01:00
Richard Hughes
d51173d448
Allow no arguments to 'fwupdmgr verify-update' and use sane defaults
...
Reading firmware from devices and writing to the default path will typically
require authentication.
2015-07-30 19:56:04 +01:00
Richard Hughes
40b6b3f597
Prefer the GUID from the firmware than the device
...
The firmware may be more generic, and it also allows us to match the GUID then
doing 'verify' on a device with a different device PID than the firmware
actually declares.
2015-07-30 18:41:39 +01:00
Richard Hughes
fe8b96e74e
Do not pre-convert the update description from AppStream XML
...
This allows the text clients like fwupdmgr to convert to UTF-8 text, and
graphical clients can use the markdown target to ensure the links are made
clickable and paragraphs are presented in the right way.
2015-07-28 13:13:41 +01:00
Thomas Hindoe Paaboel Andersen
1058ce8155
trivial: remove unused variables
2015-07-27 00:24:01 +02:00
Mario Limonciello
a570bb5195
Fallback to offline install when calling the update argument.
...
The fallback support is currently only present in the regular
install argument.
Signed-off-by: Richard Hughes <richard@hughsie.com>
2015-07-23 20:40:52 +01:00
Richard Hughes
e97261ab3d
trivial: rename 'update-metadata' to 'refresh' now we have an 'update' command
2015-07-22 10:36:00 +01:00
Richard Hughes
777917ef21
Add a 'fwupdmgr update' command to update all devices to latest versions
...
This downloads the latest version of the firmware and applies it to any
matching hardware. e.g.
$ fwupdmgr update
Downloading 1.2.3 for ColorHug...
Updating 1.2.3 on ColorHug...
* Loading firmware
* Decompressing firmware
* Restarting device
* Writing firmware to device
* Verifying firmware from device
* Restarting device
Done!
2015-07-22 10:36:00 +01:00
Richard Hughes
ade063b0df
Allow installing an offline UEFI update without --offline
...
The way this works is we try with the user settings, and if this fails with
NotSupported and the offline flag is unset then we retry the action with a
warning and the flag manually set.
I chose to do this in the client rather than the daemon as I don't want to
encode too many magic rules when we don't know the kind of devices that will
appear in the future.
Fixes the other half of https://github.com/hughsie/fwupd/pull/23
2015-07-22 10:36:00 +01:00
Richard Hughes
63a407ab34
Change the DBus method for installing firmware to 'Install'
...
It seems a little odd to call it 'Update' when it's being used for downgrading
and reinstalling as well.
As we're making things simpler, just use a single 'install' action in fwupdmgr
rather than 'install', 'update-online', 'update-offline'. We can use the flags
and fallbacks to do the right thing in all cases, and make the typical case
(installing a local file to any matching hardware) simple.
Fixes half of https://github.com/hughsie/fwupd/pull/23
2015-07-22 10:36:00 +01:00
Richard Hughes
7708a0f3fd
Move GetUpdates to the daemon
...
This only returns the latest version, if you actually need to know details
about all versions including downgrades then you still need to load the
AppStream metadata and match devices manually.
2015-07-22 10:35:05 +01:00
Richard Hughes
0b8d461099
trivial: Use the correct error codes when failing to download metadata
2015-07-21 13:27:10 +01:00
Richard Hughes
c7cf166a2f
Automatically download metadata using fwupdmgr if required
...
Using no arguments to 'fwupdmgr update-metadata' means we use the network.
2015-07-20 16:19:20 +01:00
Richard Hughes
8ffbd403cb
Fix ROM PPID searching to work for all ROMs
2015-07-08 14:28:53 +01:00
Richard Hughes
fe68ff584f
Make the version parsing more resilient to corrupt firmware
2015-07-03 12:37:56 +01:00
Richard Hughes
5dc6f5ccfc
Add a 'verify-update' command to fwupdmgr
...
This allows us to do something like:
$ fwupdmgr verify
e9b8eebd-b5f8-18d4-9fbd-d7da7711985c f21e1d2c969dedbefcf5acfdab4fa0c5ff111a57 No metadata
$ find /sys/devices -name rom -exec sudo fwupdmgr verify-update /var/cache/app-info/xmls/fwupd-verify.xml {} \;
$ fwupdmgr verify
e9b8eebd-b5f8-18d4-9fbd-d7da7711985c f21e1d2c969dedbefcf5acfdab4fa0c5ff111a57 OK
$ # flash the firmware
$ fwupdmgr verify
e9b8eebd-b5f8-18d4-9fbd-d7da7711985c 5c946b3950deaf7b102e75be488052afd4dcf16 Failed: for v013.012.000.019.000000 expected f21e1d2c969dedbefcf5acfdab4fa0c5ff111a57
2015-07-01 12:16:09 +01:00
Richard Hughes
826a5698e3
trivial: Always return the verification hash for the first verify run
...
The property is being cached, so re-request the list of devices.
2015-07-01 12:07:07 +01:00
Richard Hughes
5e33bccd54
Accept multiple files at one time when using fwupdmgr dump-rom
2015-07-01 11:53:33 +01:00
Thomas Hindoe Paaboel Andersen
80b85676bb
remove unused variables
2015-06-30 20:47:15 +02:00
Richard Hughes
174211b979
Provide a way to dump the option ROM using the command line
...
This allows someone to do:
$ find /sys/devices -name rom -exec sudo fwupdmgr dump-rom {} \;
...and get a nice summary of the option roms installed.
2015-06-30 15:40:46 +01:00
Richard Hughes
a043c2e376
Add a 'verify' command that verifies the cryptographic hash of device firmware
...
Goes some way towards fixing https://github.com/hughsie/fwupd/issues/15
2015-06-29 12:53:01 +01:00
Richard Hughes
ae0efdc5a7
Provide a way for clients to add new firmware metadata to the system cache
...
This is only possible if the metadata has been signed by a key that we trust.
2015-06-25 09:59:53 +01:00
Richard Hughes
f0d6c86df2
trivial: Print the command message even for internal error
2015-05-21 13:42:10 +01:00
Richard Hughes
d7dba98e68
Move boolean properties on the device to a set of flags
...
This is much less boilerplate and allows us to expand in the future.
2015-05-05 16:02:20 +01:00
Richard Hughes
c89c1b0e9b
Support OpenHardware devices using the fwupd vendor extensions
...
We won't be able to update these devices ourself, but we can detect if there
are updates available.
2015-05-05 15:22:00 +01:00
Richard Hughes
d8a02bfeeb
Run the offline actions using systemd when required
2015-04-25 17:14:20 +01:00
Richard Hughes
d8fa049693
Show the firmware trust status when doing GetDetails()
2015-04-14 15:57:08 +01:00
Richard Hughes
8818151196
Export the status as an enumerated value rather than a string
2015-03-19 10:57:44 +00:00
Richard Hughes
f910ac9541
trivial: Also export the status enum codes
2015-03-19 10:54:06 +00:00
Richard Hughes
8645ec9ad5
Create a libfwupd shared library
2015-03-19 10:54:05 +00:00
Richard Hughes
0e883ee815
Add and document the offline-update lifecycle
...
Also allow providers to override getting and clearing the last update status.
2015-03-19 10:31:23 +00:00
Richard Hughes
871e017bdb
Add a 'get-updates' command to fwupdmgr
...
This matches the devices from the AppStream metadata and displays new releases.
2015-03-17 21:00:21 +00:00
Richard Hughes
7c3485bc1b
trivial: Make a translated string a little clearer
2015-03-17 07:56:31 +00:00
Richard Hughes
8ded6ca0f1
trivial: Mark some more strings as translatable
...
Also fix up some translator comments.
2015-03-16 12:51:43 +00:00
Richard Hughes
bbac6d7932
Return some more fields when returning data about firmware files
2015-03-12 11:41:20 +00:00
Richard Hughes
773ce988e8
Add a 'Status' property which is updated when the daemon is active
2015-03-09 22:43:25 +00:00
Richard Hughes
a8e8394b70
Do not require the root password to update removable devices
2015-03-09 22:43:25 +00:00
Richard Hughes
cccc775b60
Add a method to get details about a firmware file
2015-03-09 11:04:32 +00:00
Richard Hughes
d079b1a6ca
Allow installing firmware without a specified device ID
2015-03-06 10:09:55 +00:00
Richard Hughes
412034adaa
Add actual error codes for failure
2015-03-05 11:30:58 +00:00
Richard Hughes
d1e823ccbf
Allow scheduling updates for later
...
Also add a update-prepared command to fwupdmgr to process the defered updates.
In the future we'll hook into the systemd early-boot code for this.
2015-03-05 11:15:36 +00:00
Richard Hughes
9849d2bb61
Register the local error codes with D-Bus to return a nice error message
2015-03-04 22:30:12 +00:00
Richard Hughes
d3d0165259
trivial: Strip the D-Bus error before showing to the user
2015-03-04 22:30:12 +00:00
Richard Hughes
1b5ea3517d
Add an OnlyOffline property for devices that cannot do online updates
2015-03-04 22:30:12 +00:00
Richard Hughes
e7c1264f3b
Add a --force option to fwupdmgr to allow installing old firmware
2015-03-04 22:30:12 +00:00
Richard Hughes
81e8d799f7
trivial: Pad out the properties when doing GetDevices
2015-03-03 15:11:22 +00:00
Richard Hughes
67ec898265
Extract the .cab file and parse the .inf file
2015-03-03 11:41:01 +00:00
Richard Hughes
1ffde6cd72
Return the device properties when calling GetDevices()
...
This allows us to discover a version number, and other things.
2015-03-02 22:44:58 +00:00
Richard Hughes
74cc217f9d
Support online updates
...
This doesn't make sense for UEFI firmware, but allows us to support other
future usecases.
2015-03-01 20:33:54 +00:00
Richard Hughes
f508e76a7a
Use PolicyKit to check the authorisation of the firmware update
2015-02-27 12:49:36 +00:00
Richard Hughes
8bbfdf49a8
Flesh out the provider interface and allow offline updates
2015-02-27 08:29:13 +00:00
Richard Hughes
8dbfb1c478
Add initial build files and enough code to launch a simple D-Bus daemon
2015-02-26 18:16:40 +00:00