# HG changeset patch # User Sebastien Jodogne # Date 1349959178 -7200 # Node ID aa6c8a942952384c6bf213c02fde421d21f7c52a # Parent f1aeec53795b6abdf2cb0fde3a5a5153b3d7a577 http client password diff -r f1aeec53795b -r aa6c8a942952 OrthancCppClient/HttpClient.cpp --- a/OrthancCppClient/HttpClient.cpp Thu Oct 11 13:02:32 2012 +0200 +++ b/OrthancCppClient/HttpClient.cpp Thu Oct 11 14:39:38 2012 +0200 @@ -197,4 +197,12 @@ return false; } } + + + void HttpClient::SetPassword(const char* username, + const char* password) + { + std::string s = std::string(username) + ":" + std::string(password); + CheckCode(curl_easy_setopt(pimpl_->curl_, CURLOPT_USERPWD, s.c_str())); + } } diff -r f1aeec53795b -r aa6c8a942952 OrthancCppClient/HttpClient.h --- a/OrthancCppClient/HttpClient.h Thu Oct 11 13:02:32 2012 +0200 +++ b/OrthancCppClient/HttpClient.h Thu Oct 11 14:39:38 2012 +0200 @@ -109,5 +109,7 @@ return HttpException::GetDescription(lastStatus_); } + void SetPassword(const char* username, + const char* password); }; } diff -r f1aeec53795b -r aa6c8a942952 Resources/Configuration.json --- a/Resources/Configuration.json Thu Oct 11 13:02:32 2012 +0200 +++ b/Resources/Configuration.json Thu Oct 11 14:39:38 2012 +0200 @@ -25,7 +25,7 @@ "DicomAet" : "ORTHANC", // Check whether the called AET corresponds during a DICOM request - "DicomCheckCalledAet" : false, + "DicomCheckCalledAet" : true, // The DICOM port "DicomPort" : 4242,