api auth fix for basic and jwt

makes sure we encrypt the jwt token using the correct secret
(from apiKey.properties) and make sure to check the secret key
for basic auth as well.
rename api auth method on application
Fix handling of client secret when searching for api keys

We don't send the secret over the wire but handle it locally.
Make sure client is authenticated only if the desired criteria is met
Add tests for getting api keys.
Merge pull request #71 from denibertovic/fix_api_token_signer

api auth fix for basic and jwt