fix certificate assignment and website metadata storage