Fixed ZAP authentication

- if ZAP server returns anything except 200, connection is closed
- all security tests now pass correctly
- test_security_curve now does proper client key authentication using test key
- test_security_plain now does proper password authentication
Merge pull request #642 from hintjens/master

Fixed ZAP authentication