Changes to remove libcurl dependency

This PR contains the changes to remove libcurl dependency. Testing is in progress.