Dpkg::Checksums - Online Linux Manual PageSection : 3perl
Updated : 2021-04-13
Source : 1.20.9
Note : libdpkg-perl

NAMEDpkg::Checksums − generate and manipulate file checksums

DESCRIPTIONThis module provides a class that can generate and manipulate various file checksums as well as some methods to query information about supported checksums.

FUNCTIONS@list = checksums_get_list() Returns the list of supported checksums algorithms. $bool = checksums_is_supported($alg) Returns a boolean indicating whether the given checksum algorithm is supported. The checksum algorithm is case-insensitive. $value = checksums_get_property($alg, $property) Returns the requested property of the checksum algorithm. Returns undef if either the property or the checksum algorithm doesn't exist. Valid properties currently include name (returns the name of the digest algorithm), regex for the regular expression describing the common string representation of the checksum, and strong for a boolean describing whether the checksum algorithm is considered cryptographically strong.

METHODS$ck = Dpkg::Checksums−>new() Create a new Dpkg::Checksums object. This object is able to store the checksums of several files to later export them or verify them. $ck>reset() Forget about all checksums stored. The object is again in the same state as if it was newly created. $ck>add_from_file($filename, %opts) Add or verify checksums information for the file $filename. The file must exists for the call to succeed. If you don't want the given filename to appear when you later export the checksums you might want to set the key option with the public name that you want to use. Also if you don't want to generate all the checksums, you can pass an array reference of the wanted checksums in the checksums option. It the object already contains checksums information associated the filename (or key), it will error out if the newly computed information does not match what's stored, and the caller did not request that it be updated with the boolean update option. $ck>add_from_string($alg, $value, %opts) Add checksums of type $alg that are stored in the $value variable. ​$value can be multi-lines, each line should be a space separated list of checksum, file size and filename. Leading or trailing spaces are not allowed. It the object already contains checksums information associated to the filenames, it will error out if the newly read information does not match what's stored, and the caller did not request that it be updated with the boolean update option. $ck>add_from_control($control, %opts) Read checksums from Checksums−* fields stored in the Dpkg::Control object ​$control. It uses $self>add_from_string() on the field values to do the actual work. If the option use_files_for_md5 evaluates to true, then the Files field is used in place of the Checksums−Md5 field. By default the option is false. @files = $ck>get_files() Return the list of files whose checksums are stored in the object. $bool = $ck>has_file($file) Return true if we have checksums for the given file. Returns false otherwise. $ck>remove_file($file) Remove all checksums of the given file. $checksum = $ck>get_checksum($file, $alg) Return the checksum of type $alg for the requested $file. This will not compute the checksum but only return the checksum stored in the object, if any. If $alg is not defined, it returns a reference to a hash: keys are the checksum algorithms and values are the checksums themselves. The hash returned must not be modified, it's internal to the object. $size = $ck>get_size($file) Return the size of the requested file if it's available in the object. $bool = $ck>has_strong_checksums($file) Return a boolean on whether the file has a strong checksum. $ck>export_to_string($alg, %opts) Return a multi-line string containing the checksums of type $alg. The string can be stored as-is in a Checksum−* field of a Dpkg::Control object. $ck>export_to_control($control, %opts) Export the checksums in the Checksums−* fields of the Dpkg::Control ​$control object.

CHANGES

Version 1.04 (dpkg 1.20.0)Remove warning: For obsolete property 'program'.

Version 1.03 (dpkg 1.18.5)New property: Add new 'strong' property. New member: $ck>has_strong_checksums().

Version 1.02 (dpkg 1.18.0)Obsolete property: Getting the 'program' checksum property will warn and return undef, the Digest module is used internally now. New property: Add new 'name' property with the name of the Digest algorithm to use.

Version 1.01 (dpkg 1.17.6)New argument: Accept an options argument in $ck>export_to_string(). New option: Accept new option 'update' in $ck>add_from_file() and ​$ck>add_from_control().

Version 1.00 (dpkg 1.15.6)Mark the module as public.
0
Johanes Gumabo
Data Size   :   19,378 byte
man-Dpkg::Checksums.3perlBuild   :   2024-12-05, 20:55   :  
Visitor Screen   :   x
Visitor Counter ( page / site )   :   3 / 184,950
Visitor ID   :     :  
Visitor IP   :   18.220.196.68   :  
Visitor Provider   :   AMAZON-02   :  
Provider Position ( lat x lon )   :   39.962500 x -83.006100   :   x
Provider Accuracy Radius ( km )   :   1000   :  
Provider City   :   Columbus   :  
Provider Province   :   Ohio ,   :   ,
Provider Country   :   United States   :  
Provider Continent   :   North America   :  
Visitor Recorder   :   Version   :  
Visitor Recorder   :   Library   :  
Online Linux Manual Page   :   Version   :   Online Linux Manual Page - Fedora.40 - march=x86-64 - mtune=generic - 24.12.05
Online Linux Manual Page   :   Library   :   lib_c - 24.10.03 - march=x86-64 - mtune=generic - Fedora.40
Online Linux Manual Page   :   Library   :   lib_m - 24.10.03 - march=x86-64 - mtune=generic - Fedora.40
Data Base   :   Version   :   Online Linux Manual Page Database - 24.04.13 - march=x86-64 - mtune=generic - fedora-38
Data Base   :   Library   :   lib_c - 23.02.07 - march=x86-64 - mtune=generic - fedora.36

Very long time ago, I have the best tutor, Wenzel Svojanovsky . If someone knows the email address of Wenzel Svojanovsky , please send an email to johanes_gumabo@yahoo.co.id .
If error, please print screen and send to johanes_gumabo@yahoo.co.id
Under development. Support me via PayPal.

ERROR : Need New Coding :         (parse_manual_page_|249|Dpkg::Checksums.3perl|36/37|el══─{─══.|.el══─{─══. ds -- \|\(em\| )         (htmlprn|149|Dpkg::Checksums.3perl|36/37|.el══─{─══. ds --  —  |.el══─{─══. ds -- \|\(em\| )         (parse_manual_page_|249|Dpkg::Checksums.3perl|43|br══─}─══|'br══─}─══ )         (htmlprn|149|Dpkg::Checksums.3perl|43|'br══─}─══ |'br══─}─══ )