Use the same names for variables as the rest of the code in rlm_rest encoders

Add more error checking around curl_easy_escape

Make the encoder code clearer