Implement getppa function.