qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v4 1/5] util: add base64 decoding function


From: Eric Blake
Subject: Re: [Qemu-devel] [PATCH v4 1/5] util: add base64 decoding function
Date: Wed, 9 Dec 2015 08:26:08 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0

On 12/09/2015 07:08 AM, Daniel P. Berrange wrote:
> The standard glib provided g_base64_decode doesn't provide any
> kind of sensible error checking on its input. Add a QEMU custom
> wrapper qbase64_decode which can be used with untrustworthy
> input that can contain invalid base64 characters, embedded
> NUL characters, or not be NUL terminated at all.
> 
> Signed-off-by: Daniel P. Berrange <address@hidden>
> ---
>  include/qemu/base64.h |  58 +++++++++++++++++++++++++++
>  tests/.gitignore      |   1 +
>  tests/Makefile        |   3 ++
>  tests/test-base64.c   | 109 
> ++++++++++++++++++++++++++++++++++++++++++++++++++
>  util/Makefile.objs    |   1 +
>  util/base64.c         |  60 +++++++++++++++++++++++++++
>  6 files changed, 232 insertions(+)
>  create mode 100644 include/qemu/base64.h
>  create mode 100644 tests/test-base64.c
>  create mode 100644 util/base64.c

Reviewed-by: Eric Blake <address@hidden>

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]