As you already know, so far DNF has been using a bunch of C libraries (hawkey, librepo, libsolv, libcomps) while yum was written entirely in Python. From now some of the DNF code will be slowly rewritten into C, more precisely, moved into libhif project. The next milestone was reached by merging hawkey into libhif and further we plan to expand libhif to support general functionality of package managers.
Why have we merged hawkey into libhif
Nowadays there are three major consumers of hawkey – DNF, PackageKit and rpm-ostree. The hawkey API was not in final form yet and was changed constantly based on demands from these package managers. We have merged hawkey project inside libhif and hidden some of not yet stable API.
Merging hawkey into libhif was another step to move more code base of DNF into C. DNF will reuse some of the existing code of libhif. Having this shared library can eliminate inconsistencies about installed packages when DNF and PackageKit is used alternately. Moreover we would like to reuse the same metadata for all package managers to save your bandwidth.
Libhif should contain the common functionality for all package managers. So far libhif is providing high level API by taking care of fetching metadata from mirrors, doing dependency solving and executing RPM transaction. In the future it will support repository configuration parsing, GPG checking and so on. At this time, this is handled by all package managers separately.
Facts for Hawkey consumers:
- libhif-0.7.0 will obsolete hawkey package
- some of the C hawkey API from libhif will not be exposed anymore, please use libhif functions instead
- python bindings will not change and the libhif package will still provide
- API in libhif is still not considered as fully stable yet
- first release of libhif with hawkey inside is targeted for Fedora 25
Please watch libhif project on github and participate in pull request discussions so you can influence the development.
Thanks to Michal Sherer, a big computer security enthusiast, the DNF users are now able to enhance the privacy and the security of their systems using Tor network for metadata and packages downloading. For those of you who are not familiar with the basic concepts of Tor networking there is a short introduction available on the project pages. Hiding your identity during the communication with mirrors reduces the ability of potential sniffing attacker to determine the exact applications and their versions used on your system and most likely secures your downloading from the attacks like quantum insert.
Since this feature has been introduced in
DNF-1.1.6-1, it should be already available in your supported up to date Fedora installations and it can be enabled in the following four easy steps:
First of all, you have to install tor package from your distribution repository. You can do so via your favorite package manager by executing ‘
dnf install tor', that will install
torsocks packages into your system.
2, Configuration of Tor
By default, the Tor SOCKS proxy is configured to run in a client mode listening on your
9050. This default configuration might be altered by editing the
torsocks.conf file located inside
3, Activation of Tor service
Start the Tor proxy by
systemct start tor and enable it permanently by
systemctl enable tor. Check whether Tor service is up and properly running by
systemct status tor .
4, Configuration of DNF
On the DNF side of configuration, the only required step is to simply add
proxy=socks5h://127.0.0.1:9050 line into your
/etc/dnf/dnf.conf. From this point, any upcoming DNF communication with remote servers will be routed through the Tor network.
P.S.: I guess that even more of Tor awesomeness is coming soon in DNF plugins extras.
Another version od DNF and DNF-PLUGINS-CORE has been released. Recently released DNF adds socks5 proxy support and repoquery has new
--recent switches available. Additionally a a lot of bugs have been fixed. For more information see DNF and plugins release notes.