libdnf5.advisory
- class libdnf5.advisory.Advisory(*args)
An advisory, represents advisory used to track security updates
- get_buildtime()
Get buildtime of this advisory. Libsolv combines issued and updated dates into buildtime by always using the newer one.
- Return type:
int
- Returns:
buildtime of this advisory.
- get_collections()
Get all collections from this advisory.
- Return type:
std::vector< libdnf5::advisory::AdvisoryCollection,std::allocator< libdnf5::advisory::AdvisoryCollection > >
- Returns:
Vector of AdvisoryCollection objects.
- get_description()
Get description of this advisory.
- Return type:
string
- Returns:
Description of this advisory as std::string.
- get_id()
Get AdvisoryId.
- Return type:
- Returns:
AdvisoryId of this advisory.
- get_message()
Get message of this advisory.
- Return type:
string
- Returns:
Message of this advisory as std::string.
- get_name()
Get name of this advisory.
- Return type:
string
- Returns:
Name of this advisory as std::string.
- get_references(*args)
Get all references of specified type from this advisory. Possible refenrece types are: “bugzilla”, “cve”, “vendor”.
- Parameters:
types (std::vector< std::string,std::allocator< std::string > >, optional) – What types of references to get. If not specified gets all types.
- Return type:
std::vector< libdnf5::advisory::AdvisoryReference,std::allocator< libdnf5::advisory::AdvisoryReference > >
- Returns:
Vector of AdvisoryReference objects.
- get_rights()
Get rights of this advisory.
- Return type:
string
- Returns:
Rights of this advisory as std::string.
- get_severity()
Get severity of this advisory.
- Return type:
string
- Returns:
Severity of this advisory as std::string.
- get_status()
Get status of this advisory.
- Return type:
string
- Returns:
Status of this advisory as std::string.
- get_title()
Get title of this advisory.
- Return type:
string
- Returns:
Title of this advisory as std::string.
- get_type()
Get type of this advisory. Possible types are: “security”, “bugfix”, “enhancement”, “newpackage”.
- Return type:
string
- Returns:
type of this advisory as std::string.
- get_vendor()
Get vendor of this advisory.
- Return type:
string
- Returns:
Vendor of this advisory as std::string.
- is_applicable()
Check whether at least one collection from this advisory is applicable.
- Return type:
boolean
- Returns:
True if applicable, False otherwise.
- thisown
- class libdnf5.advisory.AdvisoryCollection(*args)
- get_advisory()
Get Advisory this AdvisoryCollection belongs to.
- Return type:
- Returns:
newly construted Advisory object of this AdvisoryCollection.
- get_advisory_id()
Get AdvisoryId of Advisory this AdvisoryCollection belongs to.
- Return type:
- Returns:
AdvisoryId of this AdvisoryCollection.
- get_modules()
Get all AdvisoryModules stored in this AdvisoryCollection
- Return type:
std::vector< libdnf5::advisory::AdvisoryModule,std::allocator< libdnf5::advisory::AdvisoryModule > >
- Returns:
std::vector of AdvisorModules.
- get_packages()
Get all AdvisoryPackages stored in this AdvisoryCollection
- Return type:
std::vector< libdnf5::advisory::AdvisoryPackage,std::allocator< libdnf5::advisory::AdvisoryPackage > >
- Returns:
std::vector of AdvisorPackages used as output.
- is_applicable()
Whether this AdvisoryCollection is applicable. True when at least one AdvisoryModule in this AdvisoryCollection is active on the system, False otherwise.
- thisown
- class libdnf5.advisory.AdvisoryModule(*args)
- get_advisory()
Get Advisory this AdvisoryModule belongs to.
- Return type:
- Returns:
newly construted Advisory object of this AdvisoryModule.
- get_advisory_collection()
Get AdvisoryCollection this AdvisoryModule belongs to.
- Return type:
- Returns:
newly construted AdvisoryCollection object of this AdvisoryModule.
- get_advisory_id()
Get AdvisoryId of Advisory this AdvisoryModule belongs to.
- Return type:
- Returns:
AdvisoryId of this AdvisoryModule.
- get_arch()
Get arch of this AdvisoryModule.
- Return type:
string
- Returns:
Arch of this AdvisoryModule as std::string.
- get_context()
Get context of this AdvisoryModule.
- Return type:
string
- Returns:
Context of this AdvisoryModule as std::string.
- get_name()
Get name of this AdvisoryModule.
- Return type:
string
- Returns:
Name of this AdvisoryModule as std::string.
- get_nsvca()
Get NSVCA of this AdvisoryModule.
- Return type:
string
- Returns:
NSVCA of this AdvisoryModule as std::string.
- get_stream()
Get stream of this AdvisoryModule.
- Return type:
string
- Returns:
Stream of this AdvisoryModule as std::string.
- get_version()
Get version of this AdvisoryModule.
- Return type:
string
- Returns:
Version of this AdvisoryModule as std::string.
- thisown
- class libdnf5.advisory.AdvisoryPackage(*args)
- get_advisory()
Get Advisory this AdvisoryPackage belongs to.
- Return type:
- Returns:
newly construted Advisory object of this AdvisoryPackage.
- get_advisory_collection()
Get AdvisoryCollection this AdvisoryPackage belongs to.
- Return type:
- Returns:
newly construted AdvisoryCollection object of this AdvisoryPackage.
- get_advisory_id()
Get AdvisoryId of Advisory this AdvisoryPackage belongs to.
- Return type:
- Returns:
AdvisoryId of this AdvisoryPackage.
- get_arch()
Get arch of this AdvisoryPackage.
- Return type:
string
- Returns:
Arch of this AdvisoryPackage as std::string.
- get_epoch()
Get epoch of this AdvisoryPackage.
- Return type:
string
- Returns:
Epoch of this AdvisoryPackage as std::string.
- get_evr()
Get evr of this AdvisoryPackage.
- Return type:
string
- Returns:
Evr of this AdvisoryPackage as std::string.
- get_name()
Get name of this AdvisoryPackage.
- Return type:
string
- Returns:
Name of this AdvisoryPackage as std::string.
- get_nevra()
Get NEVRA of this AdvisoryPackage.
- Return type:
string
- Returns:
NEVRA of this AdvisoryPackage as std::string.
- get_reboot_suggested()
Get bool value whether reboot is suggested
- Return type:
boolean
- Returns:
Reboot suggestion of this advisory package as bool
- get_release()
Get release version of this AdvisoryPackage.
- Return type:
string
- Returns:
Release of this AdvisoryPackage as std::string.
- get_relogin_suggested()
Get bool value whether relogin is suggested
- Return type:
boolean
- Returns:
Relogin suggestion of this advisory package as bool
- get_restart_suggested()
Get bool value whether restart is suggested
- Return type:
boolean
- Returns:
Restart suggestion of this advisory package as bool
- get_version()
Get version of this AdvisoryPackage.
- Return type:
string
- Returns:
Version of this AdvisoryPackage as std::string.
- thisown
- class libdnf5.advisory.AdvisoryQuery(*args)
AdvisoryQuery is the only way how to access advisories. It is constructed using Base and filled with advisories from enabled repositories in its RepoSack.
- filter_name(*args)
- filter_packages(*args)
Filter out advisories that don’t contain at least one AdvisoryPackage that has a counterpart Package in package_set such that they have matching name and architecture and also their epoch-version-release complies to cmp_type.
- Parameters:
package_set (libdnf5::rpm::PackageSet) – libdnf5::rpm::PackageSet used when filtering.
cmp_type (int, optional) – Condition to fulfill when comparing epoch-version-release of packages.
- filter_reference(*args)
- filter_severity(*args)
- filter_type(*args)
- get_advisory_packages_sorted(*args)
Get std::vector of AdvisoryPackages present in advisories from query. Each AdvisoryPackage is returned only if it has a counterpart Package in package_set such that they have matching name and architecture and also their epoch-version-release complies to cmp_type. AdvisoryPackages are sorted in the std::vector by Name, Arch and EVR.
- Parameters:
package_set (libdnf5::rpm::PackageSet) – libdnf5::rpm::PackageSet used when filtering.
cmp_type (int, optional) – Condition to fulfill when comparing epoch-version-release of packages.
- Return type:
std::vector< libdnf5::advisory::AdvisoryPackage,std::allocator< libdnf5::advisory::AdvisoryPackage > >
- Returns:
std::vector of AdvisoryPackages
- thisown
- class libdnf5.advisory.AdvisoryReference(*args)
- get_id()
Get id of this advisory reference, this id is like a name of this reference (it is not libsolv id).
- Return type:
string
- Returns:
id of this reference as std::string.
- get_title()
Get title of this reference.
- Return type:
string
- Returns:
Title of this reference.
- get_type()
Get type of this reference. Possible reference types are: “bugzilla”, “cve”, “vendor”.
- Return type:
string
- Returns:
type of this reference as std::string.
- get_type_cstring()
Get type of this reference.
- Return type:
string
- Returns:
Type of this reference as const char* !! (temporal value)
- get_url()
Get url of this reference.
- Return type:
string
- Returns:
Url of this reference.
- thisown
- class libdnf5.advisory.AdvisorySet(*args)
- add(adv)
Add adv to the set.
- Parameters:
adv (
Advisory
) – Advisory to be added to the set.
Since: 5.0
- begin()
- clear()
Remove all advisories from the set.
Since: 5.0
- contains(adv)
- Return type:
boolean
- Returns:
true if an advisory is in the set, false otherwise.
- Parameters:
adv (
Advisory
) – Advisory that is tested for presence.
Since: 5.0
- difference(other)
Set difference: elements in the current set that are not in the other set.
- Parameters:
other (
AdvisorySet
) – The set to check for differences in.- Raises:
UsedDifferentSack When the sets entering the operation do not share the same AdvisorySack.
Since: 5.0
- empty()
- Return type:
boolean
- Returns:
true if the set is empty, false otherwise.
Since: 5.0
- end()
- get_advisory_packages_sorted_by_name_arch_evr(only_applicable=False)
Gather AdvisoryPackages for each Advisory in the set. The AdvisoryPackages are sorted by libsolv `id`s of name, arch and evr. This is a different sorting than sorting by the strings of AdvisoryPackages names, architectures and evrs.
- Parameters:
only_applicable (boolean, optional) – Whether to return only AdvisoryPackages from applicable AdvisoryCollections.
Since: 5.0
- get_base()
- intersection(other)
Set intersection: elements in the current set that are also in the other set.
- Parameters:
other (
AdvisorySet
) – The set to intersect with.- Raises:
UsedDifferentSack When the sets entering the operation do not share the same AdvisorySack.
Since: 5.0
- remove(adv)
Remove adv from the set.
- Parameters:
adv (
Advisory
) – Advisory to be removed from the set.
Since: 5.0
- size()
- Return type:
int
- Returns:
Number of elements in the set.
- swap(other)
- thisown
- update(other)
Set union: elements that are in the current set or in the other set.
- Parameters:
other (
AdvisorySet
) – The set to unify with.- Raises:
UsedDifferentSack When the sets entering the operation do not share the same AdvisorySack.
Since: 5.0
- class libdnf5.advisory.AdvisorySetIterator(other)
- begin(*args)
- end(*args)
- next()
- thisown
- value()
- libdnf5.advisory.AdvisorySet__iter__(self)
- class libdnf5.advisory.SwigPyIterator(*args, **kwargs)
- advance(n)
- copy()
- decr(n=1)
- distance(x)
- equal(x)
- incr(n=1)
- next()
- previous()
- thisown
- value()
- class libdnf5.advisory.VectorAdvisoryCollection(*args)
- append(x)
- assign(n, x)
- back()
- begin()
- capacity()
- clear()
- empty()
- end()
- erase(*args)
- front()
- get_allocator()
- insert(*args)
- iterator()
- pop()
- pop_back()
- push_back(x)
- rbegin()
- rend()
- reserve(n)
- size()
- swap(v)
- thisown
- class libdnf5.advisory.VectorAdvisoryModule(*args)
- append(x)
- assign(n, x)
- back()
- begin()
- capacity()
- clear()
- empty()
- end()
- erase(*args)
- front()
- get_allocator()
- insert(*args)
- iterator()
- pop()
- pop_back()
- push_back(x)
- rbegin()
- rend()
- reserve(n)
- size()
- swap(v)
- thisown