https://yaml.org/type/binary.html indicates that YAML 1.1 documents should support a binary scalar tag (!!binary) and I believe that libyaml does support binary tags, although the Perl bindings here do not. They seem to be limited to just FLOAT and INT for scalars. The error looks like this.
mark@C02Z26EHLVDL dev % ysh -MYAML::XS < pillar.yaml
YAML::XS Error: bad tag found for scalar: 'tag:yaml.org,2002:binary' at /Users/mark/perl5/perlbrew/perls/perl-5.30.0/lib/site_perl/5.30.0/YAML/Shell.pm line 96, <STDIN> line 210803.
https://yaml.org/type/binary.html indicates that YAML 1.1 documents should support a binary scalar tag (!!binary) and I believe that libyaml does support binary tags, although the Perl bindings here do not. They seem to be limited to just FLOAT and INT for scalars. The error looks like this.