GitHub PushEvent at 2014-04-07 22:44:36
Repository: puppet-1
Actor: jaredjennings
Payload: {"shas":[["34261f2369015552ce0f112c5f9d9f688064753a","3692e7e6671257c977ead43a7dd405288f46dfef@us.af.mil","(PUP-1840) Add a digest_algorithm Puppet setting, defaulting to md5\n\nWithout this patch applied, Puppet only performs checksums of files\nusing the MD5 algorithm. MD5 is not available on hosts configured for\nFIPS 140-2 compliance, so Puppet fails. This patch adds a setting,\nsettable in puppet.conf, whose name is digest_algorithm and whose\nvalue can be any checksum type known to Puppet::Util::Checksums. The\nsetting indicates which digest algorithm should be used for performing\nchecksums. (This patch does not contain the code that pays attention\nto the setting.) The value defaults to md5, so that if you do not set\nthis setting yourself, Puppet will act like it always has before.","Jared Jennings",false],["c1b9638dd06bda806a49cdd53ebeac62d6fe1c04","3692e7e6671257c977ead43a7dd405288f46dfef@us.af.mil","(PUP-1840) Ease testing under different digest_algorithm settings\n\nWithout this patch, spec tests for pieces of the code having to do\nwith checksums would have to be duplicated twice and contain repeated\ncode.\n\nThe patch adds the `using_checksums_describe` and `using_checksums_it`\nmethods, which can be used instead of the `describe` and `it` methods\nto enclose spec tests where checksums are involved. The methods are\nonly defined inside describe blocks where the `:uses_checksums =>\ntrue` user metadata is given, to mitigate the risk of unintended\nchanges to the behavior of spec tests not having to do with checksums.\n\n`using_checksums_it` defines a group of examples, each having the\ngiven block as body. Each example happens with a different value set\nfor `digest_algorithm`. Many `let`s are defined for use inside the\nspec test; foremost are `plaintext`, `checksum`, and\n`algo`. `plaintext` is some text; `checksum` is the checksum for this\ntext under the present setting of `digest_algorithm`. `algo` contains\nthe name of the digest algorithm in use; if `digest_algorithm` is\nunset, `algo` is 'md5'.","Jared Jennings",false],["94bca188b90bbce0a6b4d05a6929a395140d5308","3692e7e6671257c977ead43a7dd405288f46dfef@us.af.mil","(PUP-1840) Use configured digest_algorithm as default checksum_type for file resources\n\nWithout this patch, file resources will always try to checksum\nthemselves using MD5. On FIPS 140-2 compliant hosts, this will\nfail. This patch adds sha256 as a permissible value for the File\nresource's checksum parameter, and makes the checksum parameter\ndefault to using the digest_algorithm, as set in the puppet.conf.","Jared Jennings",false],["70b42d2f3b81408f949ed53c5bd22a770979db82","3692e7e6671257c977ead43a7dd405288f46dfef@us.af.mil","(PUP-1840) Use configured digest_algorithm for file bucketing and fetching\n\nWithout this patch the filebucket works using MD5, which may fail on\nFIPS 140-2 compliant hosts. This patch makes the filebucket use the\ndigest algorithm indicated by the digest_algorithm setting in\npuppet.conf.","Jared Jennings",false],["13223b9b5052b562616ff8d68d93b64287ef3a32","3692e7e6671257c977ead43a7dd405288f46dfef@us.af.mil","(PUP-1840) Add parser function digest: uses digest_algorithm to hash, not strictly md5\n\nPuppet has an md5 parser function, which returns the MD5 digest of its\nargument. On hosts configured for compliance with U.S. Federal\nInformation Processing Standard (FIPS) 140-2, attempts to use the MD5\nalgorithm cause errors, because MD5 is no longer FIPS Approved. This\npatch adds a parser function called digest, which returns the digest\nof its argument using the algorithm named by the digest_algorithm\nsetting in puppet.conf. Therefore, where md5 may fail on some hosts,\nthe digest function should always return a value; but the value may\nvary if the digest_algorithm setting is changed.","Jared Jennings",true]],"size":5,"ref":"refs/heads/fix/master/digest-parser-function-20140319","head":"13223b9b5052b562616ff8d68d93b64287ef3a32"}