fixes some credential stuff