Fix CVE-2017-1000364 by backporting the patches for rpi3