The error message you are getting is accurate. In order to use Basic Authentication, you must use SSL. This means that a) Your need to use an http library that supports SSL and b) you have to change the URL you are using (within the getLists.php script):
Tom M Group Product Manager – Content Editing Constant Contact
View API documentation, code samples, get your API key.