readded three-legged auth for ios