logging updated
auth roles logic updated.