Bug fixes and switch to prov/deprov.