Mercurial > hg > orthanc
comparison PalantirServer/main.cpp @ 34:96e57b863dd9
option to disallow remote access
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Thu, 30 Aug 2012 11:22:21 +0200 |
parents | cfe212a513c5 |
children |
comparison
equal
deleted
inserted
replaced
32:0c3e317f35e8 | 34:96e57b863dd9 |
---|---|
47 } | 47 } |
48 | 48 |
49 virtual void Handle(const std::vector<uint8_t>& dicomFile, | 49 virtual void Handle(const std::vector<uint8_t>& dicomFile, |
50 const DicomMap& dicomSummary, | 50 const DicomMap& dicomSummary, |
51 const Json::Value& dicomJson, | 51 const Json::Value& dicomJson, |
52 const std::string& distantAet) | 52 const std::string& remoteAet) |
53 { | 53 { |
54 std::string instanceUuid; | 54 std::string instanceUuid; |
55 if (dicomFile.size() > 0) | 55 if (dicomFile.size() > 0) |
56 { | 56 { |
57 index_.Store(instanceUuid, storage_, | 57 index_.Store(instanceUuid, storage_, |
58 reinterpret_cast<const char*>(&dicomFile[0]), dicomFile.size(), | 58 reinterpret_cast<const char*>(&dicomFile[0]), dicomFile.size(), |
59 dicomSummary, dicomJson, distantAet); | 59 dicomSummary, dicomJson, remoteAet); |
60 } | 60 } |
61 } | 61 } |
62 }; | 62 }; |
63 | 63 |
64 | 64 |
119 dicomServer.SetApplicationEntityTitle(GetGlobalStringParameter("DicomAet", "PALANTIR")); | 119 dicomServer.SetApplicationEntityTitle(GetGlobalStringParameter("DicomAet", "PALANTIR")); |
120 | 120 |
121 // HTTP server | 121 // HTTP server |
122 MongooseServer httpServer; | 122 MongooseServer httpServer; |
123 httpServer.SetPort(GetGlobalIntegerParameter("HttpPort", 8000)); | 123 httpServer.SetPort(GetGlobalIntegerParameter("HttpPort", 8000)); |
124 httpServer.SetRemoteAccessAllowed(GetGlobalBoolParameter("RemoteAccessAllowed", false)); | |
124 | 125 |
125 httpServer.SetAuthenticationEnabled(GetGlobalBoolParameter("AuthenticationEnabled", false)); | 126 httpServer.SetAuthenticationEnabled(GetGlobalBoolParameter("AuthenticationEnabled", false)); |
126 SetupRegisteredUsers(httpServer); | 127 SetupRegisteredUsers(httpServer); |
127 | 128 |
128 if (GetGlobalBoolParameter("SslEnabled", false)) | 129 if (GetGlobalBoolParameter("SslEnabled", false)) |