1
0
mirror of https://github.com/jordansissel/fpm synced 2025-04-19 13:18:03 +02:00
fpm/lib
Jordan Sissel 90b6058e14 Load gem specifications using YAML's safe loading
On older rubies, YAML.load _is_ the unsafe load method. At some point,
Ruby 3.1.0 / Psych 4(?) made two renames:

* YAML.load -> YAML.unsafe_load
* YAML.safe_load -> YAML.load

A quick test is to try converting a gem. This would fail if `YAML.load`
was the "safe" method because it would fail with this message:

    Tried to load unspecified class: Gem::Specification (Psych::DisallowedClass

`fpm -s gem -t empty rails` will crash on Ruby 3.1.0 prior to this
commit.

Fixes #1895

Add necessary classes to safely load yaml from gem specs
2022-05-19 20:15:52 -07:00
..
fpm Load gem specifications using YAML's safe loading 2022-05-19 20:15:52 -07:00
fpm.rb Introduce support for snap packages (#1490) 2018-10-16 15:59:17 -07:00