MCPcopy Create free account
hub / github.com/cuberite/cuberite / SendNeedAuth

Method SendNeedAuth

src/HTTPServer/HTTPConnection.cpp:47–52  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

45
46
47void cHTTPConnection::SendNeedAuth(const AString & a_Realm)
48{
49 AppendPrintf(m_OutgoingData, "HTTP/1.1 401 Unauthorized\r\nWWW-Authenticate: Basic realm=\"%s\"\r\nContent-Length: 0\r\n\r\n", a_Realm.c_str());
50 m_HTTPServer.NotifyConnectionWrite(*this);
51 m_State = wcsRecvHeaders;
52}
53
54
55

Callers 2

HandleWebadminRequestMethod · 0.80
OnRequestFinishedMethod · 0.80

Calls 2

c_strMethod · 0.80
NotifyConnectionWriteMethod · 0.80

Tested by

no test coverage detected