src->lib, framework for authRequest method