Certificate bugfix