libgpo: port samba.gpo to python3