Startup initialization.
If "$REQUEST_METHOD" == "POST" and "$CONTENT_TYPE" is empty or either "application/x-www-form-urlencoded" or "multipart/form-data", and "fDoNotParseContent" flag is not set, then retrieve and parse entries from the input stream "istr". If "$CONTENT_TYPE" is empty, the contents is not stripped from the stream but remains available (pushed back) whether or not the form parsing was successful.
If "$REQUEST_METHOD" is undefined then try to retrieve the request's entries from the 1st cmd.-line argument, and do not use "$QUERY_STRING" and "istr" at all.
Definition at line 703 of file ncbicgi.hpp.
◆ THostMap ◆ TInvalidFlag ◆ TIter ◆ TMap ◆ TRange ◆ TReader ◆ TSet ◆ TState ◆ ECgiPropSet of "standard" HTTP request properties.
Definition at line 378 of file ncbicgi.hpp.
◆ ECheckResult Enumerator eCheck_Valid eCheck_SkipInvalid eCheck_StoreInvalidDefinition at line 331 of file ncbicgi.hpp.
◆ EContentType ◆ ECookieEncoding Enumerator eCookieEnc_Url eCookieEnc_QuoteDefinition at line 185 of file ncbicgi.hpp.
◆ EFieldType Enumerator eField_Name eField_Value eField_OtherDefinition at line 165 of file ncbicgi.hpp.
◆ EInvalidFlag Enumerator fValid fInvalid_Name fInvalid_Value fInvalid_AnyDefinition at line 143 of file ncbicgi.hpp.
◆ EMultipartMode Enumerator eMultipart_none eMultipart_mixed eMultipart_related eMultipart_replaceDefinition at line 98 of file ncbicgir.hpp.
◆ EOnBadCookieHow to handle badly formed cookies.
Enumerator eOnBadCookie_ThrowExceptionThrow exception, ignore bad cookie.
eOnBadCookie_SkipAndErrorReport error, ignore bad cookie.
eOnBadCookie_SkipSilently ignore bad cookie.
eOnBadCookie_StoreAndErrorReport error, store bad cookie as-is.
eOnBadCookie_StoreStore bad cookie without URL-decoding.
Definition at line 228 of file ncbicgi.hpp.
◆ EOnCharsetErrorAction to perform if the explicit charset is not supported.
Enumerator eCharsetError_IgnoreIgnore unknown charset (try to autodetect)
eCharsetError_ThrowThrow exception if charset is not supported.
Definition at line 499 of file ncbicgi.hpp.
◆ EReadTerminator Enumerator eRT_Delimiter eRT_EOF eRT_LengthBound eRT_PartialDelimiterDefinition at line 105 of file cgi_entry_reader.hpp.
◆ ERequestMethodStandard request methods.
Enumerator eMethod_GET eMethod_POST eMethod_HEAD eMethod_PUT eMethod_DELETE eMethod_OPTIONS eMethod_TRACE eMethod_CONNECT eMethod_OtherUnknown method, use GetRequestMethodName to read.
Definition at line 905 of file ncbicgi.hpp.
◆ ESessionCreateMode Enumerator eCreateIfNotExistIf Session does not exist the new one will be created.
eDontCreateIfNotExistIf Session does not exist the exception will be thrown.
Do not try to load or create session
eDontLoadDefinition at line 835 of file ncbicgi.hpp.
◆ EState ◆ EWriteMethodWhether the cookie is sent as a part of HTTP request or HTTP response.
Enumerator eHTTPResponse eHTTPRequestDefinition at line 85 of file ncbicgi.hpp.
◆ Flags Enumerator fIndexesNotEntriesdo not handle indexes as regular FORM entries with empty value
fIgnoreQueryStringdo not parse $QUERY_STRING (or cmd.line if $REQUEST_METHOD not def)
fOwnEnvironmentown the passed "env" (and destroy it in the destructor)
fDoNotParseContentdo not automatically parse the request's content body (from "istr")
fCaseInsensitiveArgsuse case insensitive CGI arguments
fCookies_UnencodedDo not use URL-encoding/decoding for cookies.
fCookies_SpaceAsHexUse hex code for encoding spaces rather than '+'.
fSaveRequestContentSave request content (available through GetContent())
fIgnorePageHitIdDo not check if page hit id is present, do not generate one if it's missing.
fSkipDiagPropertiesSet client-ip and session-id properties for logging.
fSetDiagPropertiesOld (deprecated) flag controlling diag properties.
fParseInputOnDemandEnable on-demand parsing via GetNextEntry()
fSemicolonIsNotArgDelimiterDo not treat semicolon as query string argument separator.
fDisableTrackingCookieDo not set outgoing tracking cookie.
This can also be done per-request using CCgiResponce::DisableTrackingCookie().
fIncludePreparsedEntriesWhen parsing input on demand iterate all existing entries (e.g.
those read from QUERY_STRING) before parsing POST data.
Disable parsing input as 'indexed' query (RFC3875) even if no '=' is present.
Definition at line 704 of file ncbicgi.hpp.
◆ AbortChunkedTransfer() void CCgiResponse::AbortChunkedTransfer ( void ) ◆ AcceptRangesBytes() bool CCgiResponse::AcceptRangesBytes ( void ) const ◆ Add() [1/5] ◆ Add() [2/5] ◆ Add() [3/5]All Add() functions: if the added cookie has the same {name, domain, path} as an already existing one then the new cookie will override the old one.
Definition at line 383 of file ncbicgi.cpp.
References _TROUBLE, _VERIFY, CCgiCookies::eOnBadCookie_Skip, CCgiCookies::eOnBadCookie_SkipAndError, CCgiCookies::eOnBadCookie_Store, CCgiCookies::eOnBadCookie_StoreAndError, CCgiCookies::eOnBadCookie_ThrowException, ERR_POST_X, CCgiCookies::Find(), set< Key, Compare >::insert(), CCgiCookies::m_Cookies, NULL, CCgiCookie::SetDomain(), CCgiCookie::SetPath(), CCgiCookie::SetValue(), and rapidjson::value.
Referenced by CCgiCookies::Add(), CCgiApplication::AddLBCookie(), CCgiCookies::CCgiCookies(), ReadCgiCookies(), CCgiResponse::WriteHeader(), and CCgiRequest::x_Init().
◆ Add() [4/5] ◆ Add() [5/5]Update with a HTTP request like string: "name1=value1; name2=value2; ...".
Definition at line 504 of file ncbicgi.cpp.
References _ASSERT, _TROUBLE, CCgiCookies::Add(), CCgiCookies::eCheck_SkipInvalid, CCgiCookies::eCheck_StoreInvalid, CCgiCookies::eCheck_Valid, CCgiCookie::eField_Name, CCgiCookie::eField_Value, CCgiCookies::eOnBadCookie_Skip, CCgiCookies::eOnBadCookie_SkipAndError, CCgiCookies::eOnBadCookie_Store, CCgiCookies::eOnBadCookie_StoreAndError, CCgiCookies::eOnBadCookie_ThrowException, ERR_POST_X, NStr::eTrunc_End, NStr::eUrlDec_All, NStr::eUrlDec_Percent, NStr::eUrlEnc_PercentOnly, CCgiCookie::fInvalid_Name, CCgiCookie::fInvalid_Value, kEmptyStr, CCgiCookies::m_EncodeFlag, msg(), NCBI_THROW2, NPOS, NStr::PrintableString(), NStr::Replace(), s_GetCookieNameBannedSymbols(), CCgiCookie::SetInvalid(), str(), NStr::TruncateSpacesInPlace(), NStr::URLDecode(), val, and CCgiCookies::x_CheckField().
◆ AddDefinitions() [1/2] void CRefArgs::AddDefinitions ( const string & definitions ) ◆ AddDefinitions() [2/2] ◆ AddEntry() [1/2] ◆ AddEntry() [2/2] ◆ AddTrailer() ◆ BeginPart() [1/2]Definition at line 481 of file ncbicgir.cpp.
References _ASSERT, CCgiResponse::eMultipart_none, CCgiResponse::eMultipart_replace, ERR_POST_X, CCgiResponse::GetHeaderValue(), HTTP_EOL, CCgiResponse::m_BetweenParts, CCgiResponse::m_Boundary, CCgiResponse::m_IsMultipart, Printable(), ncbi::grid::netcache::search::fields::size, CCgiResponse::sm_ContentDispoName, CCgiResponse::sm_ContentTypeDefault, CCgiResponse::sm_ContentTypeName, CCgiResponse::sm_FilenamePrefix, type, and Warning().
◆ BeginPart() [2/2] ◆ c_str() const char* CCgiEntry::c_str ( ) const inline ◆ CalcChecksum()Definition at line 1771 of file ncbicgi.cpp.
References CChecksum::AddLine(), AStrEquiv(), eCgi_QueryString, eCgi_RequestMethod, eCgi_ScriptName, eCgi_ServerName, eCgi_ServerPort, CChecksum::eMD5, entries, CNcbiApplicationAPI::GetProgramDisplayName(), CCgiRequest::GetProperty(), CNcbiApplication::Instance(), ITERATE, CCgiRequest::ParseEntries(), and CChecksum::WriteChecksumData().
Referenced by CCgiApplication::GetResultFromCache(), and CCgiApplication::SaveResultToCache().
◆ CanSendTrailer() bool CCgiResponse::CanSendTrailer ( void ) const ◆ CCgiCookie() [1/2] ◆ CCgiCookie() [2/2]Throw the "invalid_argument" if "name" or "value" have invalid format.
Definition at line 159 of file ncbicgi.cpp.
References kZeroTime, CCgiCookie::m_Expires, CCgiCookie::m_HttpOnly, CCgiCookie::m_Name, CCgiCookie::m_Secure, NCBI_THROW2, CCgiCookie::SetDomain(), CCgiCookie::SetPath(), CCgiCookie::SetValue(), and rapidjson::value.
◆ CCgiCookies() [1/4]prohibit default initialization and assignment
◆ CCgiCookies() [2/4] ◆ CCgiCookies() [3/4] CCgiCookies::CCgiCookies ( EUrlEncode encode_flag ) inlineUse the specified method of string encoding.
Definition at line 1078 of file ncbicgi.hpp.
◆ CCgiCookies() [4/4] CCgiCookies::CCgiCookies ( void ) inline ◆ CCgiEntry() [1/3] ◆ CCgiEntry() [2/3] ◆ CCgiEntry() [3/3] ◆ CCgiEntryReader() ◆ CCgiEntryReaderContext()Definition at line 179 of file cgi_entry_reader.cpp.
References CCER, CT_EOF, CT_EQ_INT_TYPE, CT_INT_TYPE, CCgiEntryReaderContext::eCT_Multipart, CCgiEntryReaderContext::eCT_Null, CCgiEntryReaderContext::eCT_URLEncoded, NStr::eNocase, CCgiEntryReaderContext::eRT_EOF, NStr::FindNoCase(), kBoundaryTag, CCgiEntryReaderContext::m_Boundary, CCgiEntryReaderContext::m_ContentType, CCgiEntryReaderContext::m_In, NCBI_THROW, next(), NPOS, s_MatchesBoundary(), NStr::StartsWith(), and CCgiEntryReaderContext::x_DelimitedRead().
◆ CCgiRequest() [1/4] CCgiRequest::CCgiRequest ( CNcbiIstream & is, TFlags flags =0
, size_t errbuf_size = 256
) ◆ CCgiRequest() [2/4]
prohibit default initialization and assignment
◆ CCgiRequest() [3/4] ◆ CCgiRequest() [4/4] ◆ CCgiResponse() [1/2] ◆ CCgiResponse() [2/2] ◆ CExtraEntryCollector() CExtraEntryCollector::CExtraEntryCollector ( void ) inlineDefinition at line 662 of file ncbicgi.hpp.
◆ Clear() void CCgiCookies::Clear ( void ) ◆ compare() [1/2] int CCgiEntry::compare ( const char * s ) const inline ◆ compare() [2/2] ◆ Cookies() [1/2] ◆ Cookies() [2/2] ◆ CopyAttributes() ◆ CRefArgs()Create referrer parser from a set of definitions.
Definition at line 60 of file ref_args.cpp.
References CRefArgs::AddDefinitions().
◆ Deserialize()Definition at line 1586 of file ncbicgi.cpp.
References flags, CCgiRequest::GetCookies(), CCgiRequest::GetEntries(), CCgiRequest::GetIndexes(), CCgiRequest::m_Env, CCgiRequest::m_OwnEnv, CCgiRequest::m_QueryStringParsed, NULL, ReadCgiCookies(), ReadContainer(), ReadEnvironment(), ReadMap(), true, CCgiRequest::x_ProcessInputStream(), and CCgiRequest::x_ProcessQueryString().
Referenced by CCgiRequest::CCgiRequest().
◆ DisableTrackingCookie() void CCgiResponse::DisableTrackingCookie ( void ) ◆ empty() bool CCgiEntry::empty ( ) const inline ◆ Empty() bool CCgiCookies::Empty ( void ) const inline ◆ EndLastPart() [1/2] ◆ EndLastPart() [2/2] void CCgiResponse::EndLastPart ( void ) inline ◆ EndPart() [1/2] ◆ EndPart() [2/2] void CCgiResponse::EndPart ( void ) inline ◆ Finalize() void CCgiResponse::Finalize ( void ) const ◆ find() [1/3] ◆ find() [2/3] ◆ Find() [1/4]Return NULL if cannot find this exact cookie.
Definition at line 689 of file ncbicgi.cpp.
References _ASSERT, AStrEquiv(), set< Key, Compare >::begin(), set< Key, Compare >::end(), CCgiCookies::m_Cookies, and s_CookieLess().
Referenced by CCgiCookies::Add(), CCgiCookies::Find(), CCgiCookies::Remove(), CCgiSession::RetrieveSessionId(), CCgiContext::RetrieveTrackingId(), s_CheckCookieForTID(), CHttpRequest::x_GetCookieValue(), CCgiRequest::x_InitRequestContext(), and CCgiApplication::x_OnEvent().
◆ Find() [2/4] ◆ Find() [3/4] ◆ Find() [4/4]Return the first matched cookie with name "name", or NULL if there is no such cookie(s).
Also, if "range" is non-NULL then assign its "first" and "second" fields to the beginning and the end of the range of cookies matching the name "name". NOTE: if there is a cookie with empty domain and path then this cookie is guaranteed to be returned.
Definition at line 720 of file ncbicgi.cpp.
References set< Key, Compare >::begin(), set< Key, Compare >::end(), and CCgiCookies::m_Cookies.
◆ find() [3/3] ◆ find_first_of() [1/2] ◆ find_first_of() [2/2] ◆ FinishChunkedTransfer() void CCgiResponse::FinishChunkedTransfer ( void ) ◆ Flush() void CCgiResponse::Flush ( void ) const ◆ GetAll() ◆ GetAllCookiesHttpOnly() bool CCgiCookies::GetAllCookiesHttpOnly ( void ) const inline ◆ GetAllCookiesSecure() bool CCgiCookies::GetAllCookiesSecure ( void ) const inline ◆ GetArgs() ◆ GetCGIEntries()Get full set of arguments (both GET and POST), URL-encoded.
A &-separated list of exclusions can be set in CGI_LOG_EXCLUDE_ARGS variable or [CGI] LOG_EXCLUDE_ARGS value in ini file.
Definition at line 1648 of file ncbicgi.cpp.
References CEntryCollector_Base::AddEntry(), ERR_POST, Error(), NStr::fSplit_MergeDelimiters, NStr::fSplit_Truncate, if(), ITERATE, kEmptyStr, CCgiRequest::m_Entries, CCgiRequest::m_Indexes, NStr::Split(), NStr::SplitInTwo(), string, NStr::StringToInt(), and val.
Referenced by CCgiRequest::GetCGIEntriesStr(), and CCgiApplication::x_OnEvent().
◆ GetCGIEntriesStr() string CCgiRequest::GetCGIEntriesStr ( void ) const ◆ GetChunkedTransferEnabled() bool CCgiResponse::GetChunkedTransferEnabled ( void ) const ◆ GetChunkSize() size_t CCgiResponse::GetChunkSize ( void ) static ◆ GetClientTrackingEnv() const char *const * CCgiRequest::GetClientTrackingEnv ( void ) const ◆ GetContent() ◆ GetContentLength() size_t CCgiRequest::GetContentLength ( void ) const ◆ GetContentType() [1/2] ◆ GetContentType() [2/2] string CCgiResponse::GetContentType ( void ) const inline ◆ GetCookies() [1/2] ◆ GetCookies() [2/2] ◆ GetDefaultDefinitions() string CRefArgs::GetDefaultDefinitions ( void ) staticGet default set of search engine definitions.
Definition at line 45 of file ref_args.cpp.
◆ GetDomain() ◆ GetEntries() [1/2] ◆ GetEntries() [2/2]Get a set of entries(decoded) received from the client.
Also includes "indexes" if "indexes_as_entries" in the constructor was TRUE (default). NOTE: In the "fParseInputOnDemand" mode not all of the entries may be loaded at the time of the call.
Definition at line 1181 of file ncbicgi.hpp.
References CCgiRequest::m_Entries.
Referenced by CCgiContext::AddRequestValue(), CPager::CPager(), CSelection::CSelection(), CCgiRequest::Deserialize(), CPager::GetDisplayedPage(), CCgiRequest::GetEntry(), CPager::GetPageSize(), CGridCgiContext::GetRequestEntryValue(), CCgiContext::GetRequestValue(), CPager::IsPagerCommand(), main(), CCgi2RCgiApp::ProcessRequest(), CCgiRedirectApplication::RemapEntries(), CCgiContext::RemoveRequestValues(), CGlTestApplication::Render(), CSeqTestApplication::Render(), CCgiRequest::Serialize(), CBlastHitMatrixCGIApplication::x_GetCGIContextParams(), CAlnMultiCGIApplication::x_PreProcess(), and CSoapServerApplication::x_ProcessWsdlRequest().
◆ GetEntry()Get entry value by name.
NOTE 1: There can be more than one entry with the same name; only one of these entry will be returned. To get all matches use GetEntries() and "multimap::" member functions. NOTE 2: In the "fParseInputOnDemand" mode not all of the entries may be loaded at the time of the call, so – use GetPossiblyUnparsedEntry() instead.
Definition at line 1449 of file ncbicgi.cpp.
References multimap_checker< Container >::end(), multimap_checker< Container >::find(), CSafeStatic< T, Callbacks >::Get(), and CCgiRequest::GetEntries().
Referenced by CCgiStatistics::Compose_Entries(), CCgiApplication::ConfigureDiagDestination(), CCgiApplication::ConfigureDiagFormat(), CCgiApplication::ConfigureDiagThreshold(), CCgiContext::ProcessCORSRequest(), CFastCgiMTSampleRequestProcessor::ProcessRequest(), CNetCacheBlobFetchApp::ProcessRequest(), CCgiSampleApplication::ProcessRequest(), CCgiSessionSampleApplication::ProcessRequest(), CCgiFontTestApp::Render(), ReportJSONVersion(), CCgiSession::RetrieveSessionId(), s_CheckRequestEntryForTID(), s_WriteHeader(), TestDelay(), CCgiApplication::x_ProcessAdminRequest(), CCgiApplication::x_ProcessHelpRequest(), and CCgiApplication::x_ProcessVersionRequest().
◆ GetEnvironment() ◆ GetExpDate() [1/2] bool CCgiCookie::GetExpDate ( tm * exp_date ) const ◆ GetExpDate() [2/2] string CCgiCookie::GetExpDate ( void ) const ◆ GetFilename() ◆ GetHeaderValue() ◆ GetHttpOnly() bool CCgiCookie::GetHttpOnly ( void ) const inline ◆ GetIndexes() [1/2] ◆ GetIndexes() [2/2] ◆ GetInputFD() int CCgiRequest::GetInputFD ( void ) const inline ◆ GetInputStream() ◆ GetMultipartMode() ◆ GetName() ◆ GetNextEntry() [1/2]Definition at line 233 of file cgi_entry_reader.cpp.
References _ASSERT, CCgiEntryReaderContext::CCgiEntryReader, CCgiEntryReaderContext::eCT_Multipart, CCgiEntryReaderContext::eCT_Null, CCgiEntryReaderContext::eCT_URLEncoded, multimap_checker< Container >::end(), multimap_checker< Container >::insert(), CCgiEntryReaderContext::m_ContentType, CCgiEntryReaderContext::m_CurrentEntry, CCgiEntryReaderContext::m_CurrentReader, CCgiEntryReaderContext::m_Out, CCgiEntryReaderContext::m_OutIter, CCgiEntryReaderContext::m_OutIterated, CCgiEntryReaderContext::m_Position, CCgiEntry::SetValue(), rapidjson::value, CCgiEntryReaderContext::x_FlushCurrentEntry(), CCgiEntryReaderContext::x_ReadMultipartHeaders(), and CCgiEntryReaderContext::x_ReadURLEncodedEntry().
Referenced by CCgiRequest::GetNextEntry().
◆ GetNextEntry() [2/2] ◆ GetOutput()Get output stream (NULL here means "no output stream").
Definition at line 239 of file ncbicgir.cpp.
References CCgiResponse::AcceptRangesBytes(), CCgiRequest::eMethod_HEAD, ERR_POST_X, CCgiResponse::HaveContentRange(), CCgiResponse::m_HeaderWritten, CCgiResponse::m_Output, CCgiResponse::m_RequestMethod, CCgiResponse::m_ThrowOnBadOutput, and CCgiResponse::SetThrowOnBadOutput().
Referenced by CCgiResponse::Flush(), CCgiResponse::out(), CCgiRequestProcessor::ProcessHelpRequest(), CCgiRequestProcessor::ProcessVersionRequest(), and CCgiApplication::x_OnEvent().
◆ GetOutputFD() int CCgiResponse::GetOutputFD ( void ) const inline ◆ GetPath() ◆ GetPosition() unsigned int CCgiEntry::GetPosition ( void ) const inline ◆ GetPossiblyUnparsedEntry() ◆ GetProperty()Get value of a "standard" property (return empty string if not defined)
Definition at line 1432 of file ncbicgi.cpp.
References CCgiRequest::GetPropertyName(), and CCgiRequest::x_GetPropertyByName().
Referenced by CCgiRequest::CalcChecksum(), CCgiUserAgent::CCgiUserAgent(), CGridCgiContext::CGridCgiContext(), CCgiRequest::GetContentLength(), CCgiRequest::GetRequestMethodName(), CCgiContext::GetSelfURL(), CGridCgiApplication::IsCachingNeeded(), CCgiRequestProcessor::ParseAcceptHeader(), s_GetCgiTunnel2GridUrl(), CCgiRequest::x_Init(), CCgiApplication::x_OnEvent(), CCgiApplication::x_ProcessAdminRequest(), CCgiRequest::x_ProcessInputStream(), and CCgiRequest::x_ProcessQueryString().
◆ GetPropertyName() ◆ GetQueryString()Find query string in the referrer.
Definition at line 101 of file ref_args.cpp.
References ERR_POST_X, NStr::FindNoCase(), CUrl::GetArgs(), CUrl::GetHost(), CUrlArgs::GetValue(), CUrl::HaveArgs(), CUrlArgs::IsSetValue(), ITERATE, kEmptyStr, CRefArgs::m_HostMap, NPOS, and Warning().
◆ GetRandomProperty()Get value of a random client property; if "http" is TRUE then add prefix "HTTP_" to the property name.
NOTE: usually, the value is extracted from the environment variable named "$[HTTP]_<key>". Be advised, however, that in the case of FastCGI application, the set (and values) of env.variables change from request to request, and they differ from those returned by CNcbiApplication::GetEnvironment()!
Definition at line 1438 of file ncbicgi.cpp.
References ncbi::grid::netcache::search::fields::key, and CCgiRequest::x_GetPropertyByName().
Referenced by CCgiResponse::CanSendTrailer(), CGridCgiContext::CGridCgiContext(), CCgiContext::GetSelfURL(), CCgiContext::ProcessCORSRequest(), CCgiRequestProcessor::ValidateSynchronizationToken(), CCgiRequest::x_InitRequestContext(), CCgiContext::x_IsSecure(), and CCgiApplication::x_OnEvent().
◆ GetRequestMethod()Get request method.
Definition at line 1810 of file ncbicgi.cpp.
References AStrEquiv(), CCgiRequest::eMethod_CONNECT, CCgiRequest::eMethod_DELETE, CCgiRequest::eMethod_GET, CCgiRequest::eMethod_HEAD, CCgiRequest::eMethod_OPTIONS, CCgiRequest::eMethod_Other, CCgiRequest::eMethod_POST, CCgiRequest::eMethod_PUT, CCgiRequest::eMethod_TRACE, CCgiRequest::GetRequestMethodName(), and i.
Referenced by CCgiContext::ProcessCORSRequest(), CCgiSampleApplication::ProcessPrintEnvironment(), CFastCgiMTSampleRequestProcessor::ProcessRequest(), CCgiSampleApplication::ProcessRequest(), CCgiApplication::x_DoneHeadRequest(), CCgiApplication::x_ProcessAdminRequest(), CCgiApplication::x_ProcessHelpRequest(), and CCgiApplication::x_ProcessVersionRequest().
◆ GetRequestMethodName() const string & CCgiRequest::GetRequestMethodName ( void ) const ◆ GetSecure() bool CCgiCookie::GetSecure ( void ) const inline ◆ GetSession() ◆ GetTrackingCookie() const string& CCgiRequest::GetTrackingCookie ( void ) const inline ◆ GetTrailerValue() ◆ GetUrlEncodeFlag() EUrlEncode CCgiCookies::GetUrlEncodeFlag ( void ) const inline ◆ GetValue() [1/2]Get the value as a string, (necessarily) prefetching it all if applicable; the result remains available for future calls to GetValue and relatives.
Definition at line 470 of file ncbicgi.hpp.
References CCgiEntry::m_Data, and CCgiEntry::x_ForceComplete().
Referenced by CCgiEntry::c_str(), CCgiEntry::compare(), CCgiStatistics::Compose_Entries(), CCgiEntry::empty(), CCgiEntry::find(), CCgiEntry::find_first_of(), CCgiEntry::GetValueAsUTF8(), CCgiEntry::GetValueStream(), CCgiEntry::operator const CTempStringEx(), CCgiEntry::operator const string &(), operator+(), operator<<(), CCgiEntry::operator=(), CCgiEntry::operator==(), CCgiSession::RetrieveSessionId(), CCgiContext::RetrieveTrackingId(), s_CheckRequestEntryForTID(), CCgiEntry::size(), CCgiEntry::substr(), CContElemConverter< CCgiEntry >::ToString(), CDisplaySeqalign::x_DisplayAlignSortInfo(), CDisplaySeqalign::x_FormatAlignSortInfo(), CDisplaySeqalign::x_MapDefLine(), and CDisplaySeqalign::x_ShowAlnvecInfoTemplate().
◆ GetValue() [2/2] ◆ GetValueAsUTF8() ◆ GetValueReader() IReader * CCgiEntry::GetValueReader ( ) inlineGet the value via a reader, potentially on the fly – in which case the caller takes ownership of the source, and subsequent calls to GetValue and relatives will yield NO data.
(In either case, the caller owns the resulting object.)
Definition at line 1136 of file ncbicgi.hpp.
References CCgiEntry::m_Data.
◆ GetValueStream() ◆ HaveContentRange() bool CCgiResponse::HaveContentRange ( void ) const ◆ HaveHeaderValue() ◆ HaveTrailer() ◆ IncludePreparsedEntries() void CCgiEntryReaderContext::IncludePreparsedEntries ( void ) ◆ InitCORSHeaders()This method is called automatically by CCgiContext.
Initialize cross-origin resource sharing (CORS) headers.
Definition at line 592 of file ncbicgir.cpp.
◆ IsHeaderWritten() bool CCgiResponse::IsHeaderWritten ( void ) const inline ◆ IsInvalid() ◆ IsListedHost() ◆ IsRawCgi() bool CCgiResponse::IsRawCgi ( void ) const inline ◆ NCBI_PARAM_DECL() [1/2] CCgiResponse::NCBI_PARAM_DECL ( bool , CGI , ExceptionAfterHEAD ) private ◆ NCBI_PARAM_DECL() [2/2] CCgiResponse::NCBI_PARAM_DECL ( bool , CGI , ThrowOnBadOutput ) private ◆ NCBI_PARAM_TYPE() [1/2] typedef CCgiResponse::NCBI_PARAM_TYPE ( CGI , ExceptionAfterHEAD ) private ◆ NCBI_PARAM_TYPE() [2/2] typedef CCgiResponse::NCBI_PARAM_TYPE ( CGI , ThrowOnBadOutput ) private ◆ operator const CTempStringEx() ◆ operator const string &() ◆ operator string &() CCgiEntry::operator string & ( ) inline ◆ operator!=() [1/3] ◆ operator!=() [2/3] ◆ operator!=() [3/3] ◆ operator()() ◆ operator+() [1/2] ◆ operator+() [2/2] ◆ operator<() ◆ operator<<() [1/3] ◆ operator<<() [2/3] ◆ operator<<() [3/3] ◆ operator=() [1/5] ◆ operator=() [2/5] ◆ operator=() [3/5] ◆ operator=() [4/5] ◆ operator=() [5/5] ◆ operator==() [1/3] ◆ operator==() [2/3] bool CCgiEntry::operator== ( const char * v ) const inline ◆ operator==() [3/3] ◆ out()Get output stream. Throw exception if GetOutput() is NULL.
Definition at line 257 of file ncbicgir.cpp.
References CCgiResponse::GetOutput(), CCgiResponse::m_Output, and THROW1_TRACE.
Referenced by CCgiResponse::BeginPart(), CCgiResponse::EndLastPart(), CCgiResponse::EndPart(), CCgi2RCgiApp::ListenJobs(), main(), CAsBodyDiagFactory::New(), CCgiSampleApplication::ProcessPrintEnvironment(), CFastCgiMTSampleRequestProcessor::ProcessRequest(), CGlCgiImageApplication::ProcessRequest(), CCgiRedirectApplication::ProcessRequest(), CGridCgiApplication::ProcessRequest(), CNetCacheBlobFetchApp::ProcessRequest(), CBlastHitMatrixCGIApplication::ProcessRequest(), CCgiSampleApplication::ProcessRequest(), CCgiSessionSampleApplication::ProcessRequest(), CCgi2RCgiApp::ReadJob(), CCgi2RCgiApp::RenderPage(), ReportJSONVersion(), s_Demo(), CGridCgiContext::SetCompleteResponse(), CCgiResponse::WriteHeader(), CGlCgiImageApplication::x_HandleError(), CSoapServerApplication::x_ProcessSoapRequest(), CSoapServerApplication::x_ProcessWsdlRequest(), and CCgiSessionSampleApplication::x_ShowConfigFile().
◆ ParseEntries()Decode the URL-encoded(FORM or ISINDEX) string "str" into a set of entries <"name", "value"> and add them to the "entries" set.
The new entries are added without overriding the original ones, even if they have the same names. FORM format: "name1=value1&.....", ('=' and 'value' are optional) ISINDEX format: "val1+val2+val3+....." If the "str" is in ISINDEX format then the entry "value" will be empty. On success, return zero; otherwise return location(1-based) of error
Definition at line 1530 of file ncbicgi.cpp.
References entries, CParseTemplException< TBase >::GetPos(), CUrlArgs_Parser::SetQueryString(), and str().
Referenced by CCgiRequest::CalcChecksum(), CFactory< Type >::CgiFactory(), CGridCgiContext::CGridCgiContext(), and CGridCgiApplication::IsCachingNeeded().
◆ ParseIndexes() ◆ ParseRemainingContent() void CCgiRequest::ParseRemainingContent ( void ) ◆ PendingCount() ERW_Result CCgiEntryReader::PendingCount ( size_t * count ) virtualVia parameter "count" (which is guaranteed to be supplied non-NULL) return the number of bytes that are ready to be read from the input device without blocking.
Return eRW_Success if the number of pending bytes has been stored at the location pointed to by "count". Return eRW_NotImplemented if the number cannot be determined. Otherwise, return other eRW_... condition to reflect the problem ("*count" does not need to be updated in the case of non-eRW_Success). Note that if reporting 0 bytes ready, the method may return either both eRW_Success and zero "*count", or return eRW_NotImplemented alone.
Implements IReader.
Definition at line 91 of file cgi_entry_reader.cpp.
References _ASSERT, count, CT_EQ_INT_TYPE, CT_TO_INT_TYPE, eRW_Eof, eRW_NotImplemented, eRW_Success, CCgiEntryReader::fHitBoundary, CCgiEntryReader::fHitCRLF, CCgiEntryReader::m_Buffer, CCgiEntryReader::m_Context, CCgiEntryReaderContext::m_In, and CCgiEntryReader::m_State.
◆ Read() ERW_Result CCgiEntryReader::Read ( void * buf, size_t count, size_t * bytes_read ) virtualRead as many as "count" bytes into a buffer pointed to by the "buf" argument.
Always store the number of bytes actually read (0 if read none) via the pointer "bytes_read", if provided non-NULL. Return non-eRW_Success code if EOF / error condition has been encountered during the operation (some data may have been read, nevertheless, and reflected in "*bytes_read"). Special case: if "count" is passed as 0, then the value of "buf" must be ignored, and no change should be made to the state of the input device (but may return non-eRW_Success to indicate that the input device has already been in an error condition).
Implements IReader.
Definition at line 67 of file cgi_entry_reader.cpp.
References _ASSERT, buf, count, CCgiEntryReaderContext::eCT_Multipart, eRW_Eof, eRW_Success, CCgiEntryReader::fHitBoundary, CCgiEntryReader::m_Buffer, CCgiEntryReaderContext::m_ContentType, CCgiEntryReader::m_Context, CCgiEntryReader::m_State, min(), n, and CCgiEntryReader::x_FillBuffer().
◆ Remove() [1/3] ◆ Remove() [2/3] ◆ Remove() [3/3] ◆ RemoveHeaderValue() void CCgiResponse::RemoveHeaderValue ( const string & name ) ◆ RemoveTrailer() void CCgiResponse::RemoveTrailer ( const string & name ) ◆ RequireWriteHeader() void CCgiResponse::RequireWriteHeader ( bool require ) inlineDefine if WriteHeader() must be called or can be skipped.
Definition at line 401 of file ncbicgir.hpp.
References CCgiResponse::m_RequireWriteHeader.
Referenced by CCgi2RCgiApp::ProcessRequest().
◆ Reset() void CCgiCookie::Reset ( void ) ◆ ResetInvalid() ◆ SData() [1/2] ◆ SData() [2/2] ◆ Serialize()Serialize/Deserialize a request to/from a stream.
Definition at line 1566 of file ncbicgi.cpp.
References buf, env, CCgiRequest::GetCookies(), CCgiRequest::GetEntries(), CCgiRequest::GetIndexes(), CCgiRequest::GetInputStream(), int, CCgiRequest::m_QueryStringParsed, WriteCgiCookies(), WriteContainer(), WriteEnvironment(), and WriteMap().
Referenced by CGI2GRID_ComposeHtmlPage(), CCgiApplication::SaveRequest(), and CCgi2RCgiApp::SubmitJob().
◆ SetAllCookiesHttpOnly() void CCgiCookies::SetAllCookiesHttpOnly ( bool value ) ◆ SetAllCookiesSecure() void CCgiCookies::SetAllCookiesSecure ( bool value ) ◆ SetCgiRequest() ◆ SetChunkedTransferEnabled() void CCgiResponse::SetChunkedTransferEnabled ( bool value ) ◆ SetContentType() [1/3] string& CCgiEntry::SetContentType ( ) inline ◆ SetContentType() [2/3] ◆ SetContentType() [3/3] void CCgiResponse::SetContentType ( const string & type ) inlineSet content type (text/html by default if not provided)
Definition at line 337 of file ncbicgir.hpp.
References CCgiResponse::SetHeaderValue(), and CCgiResponse::sm_ContentTypeName.
Referenced by CPsgCgiApp::Help(), CAsBodyDiagFactory::New(), CCgiRequestProcessor::ProcessAdminRequest_Base(), CCgiRequestProcessor::ProcessHelpRequest(), CGlCgiImageApplication::ProcessRequest(), CSoapServerApplication::ProcessRequest(), CCgi2RCgiApp::ProcessRequest(), CBlastHitMatrixCGIApplication::ProcessRequest(), CCgiRequestProcessor::ProcessVersionRequest(), ReportJSONVersion(), s_WriteHeader(), and CGlCgiImageApplication::x_HandleError().
◆ SetDomain() ◆ SetExceptionAfterHEAD() void CCgiResponse::SetExceptionAfterHEAD ( bool expt_after_head ) ◆ SetExpDate() void CCgiCookie::SetExpDate ( const tm & exp_date ) inline ◆ SetExpTime() void CCgiCookie::SetExpTime ( const CTime & exp_time ) ◆ SetFilename() [1/3] string& CCgiEntry::SetFilename ( void ) inline ◆ SetFilename() [2/3] ◆ SetFilename() [3/3] void CCgiResponse::SetFilename ( const string & name, size_t size =0
) ◆ SetHeaderValue() [1/3] ◆ SetHeaderValue() [2/3]
Definition at line 151 of file ncbicgir.cpp.
References CCgiResponse::m_HeaderValues, NCBI_THROW, CCgiResponse::RemoveHeaderValue(), rapidjson::value, and CCgiResponse::x_ValidateHeader().
Referenced by CCgi2RCgiApp::CheckIfJobDone(), CCgi2RCgiApp::DefineRefreshTags(), CCgi2RCgiApp::PopulatePage(), CCgiContext::ProcessCORSRequest(), CGridCgiApplication::RenderRefresh(), s_WriteHeader(), CCgiResponse::SetContentType(), CCgiResponse::SetFilename(), CCgiResponse::SetHeaderValue(), CCgiResponse::SetLocation(), CCgiResponse::SetRetryContext(), CCgiResponse::SetStatus(), and CCgiResponse::WriteHeader().
◆ SetHeaderValue() [3/3] void CCgiResponse::SetHeaderValue ( const string & name, const struct tm & value ) ◆ SetHttpOnly() void CCgiCookie::SetHttpOnly ( bool http_only ) inline ◆ SetInputStream() ◆ SetInvalid() ◆ SetLocation() ◆ SetMultipartMode() ◆ SetOutput() ◆ SetPath() ◆ SetPosition() [1/2] unsigned int& CCgiEntry::SetPosition ( void ) inline ◆ SetPosition() [2/2] void CCgiEntry::SetPosition ( int p ) inline ◆ SetRawCgi() void CCgiResponse::SetRawCgi ( bool is_raw ) inline ◆ SetRequestMethod() ◆ SetRetryContext() ◆ SetSecure() [1/2] void CCgiCookie::SetSecure ( bool secure ) inline ◆ SetSecure() [2/2] void CCgiCookies::SetSecure ( bool secure ) inline ◆ SetStatus() ◆ SetThrowOnBadOutput() void CCgiResponse::SetThrowOnBadOutput ( bool throw_on_bad_output ) ◆ SetTrackingCookie() [1/2] void CCgiRequest::SetTrackingCookie ( const string & cookie_value ) inline ◆ SetTrackingCookie() [2/2] ◆ SetTrailerValue() ◆ SetUrlEncodeFlag() void CCgiCookies::SetUrlEncodeFlag ( EUrlEncode encode_flag ) inline ◆ SetValue() [1/5] string& CCgiEntry::SetValue ( void ) inline ◆ SetValue() [2/5] ◆ SetValue() [3/5] ◆ SetValue() [4/5] ◆ SetValue() [5/5] void CCgiEntry::SetValue ( IReader * r ) inline ◆ size() ◆ substr() ◆ Write() [1/2] ◆ Write() [2/2]Compose and write to output stream "os":
Definition at line 232 of file ncbicgi.cpp.
References CCgiCookie::eField_Name, CCgiCookie::eField_Value, CCgiCookie::eHTTPResponse, CCgiCookie::fInvalid_Name, CCgiCookie::fInvalid_Value, CCgiCookie::GetExpDate(), HTTP_EOL, CCgiCookie::m_Domain, CCgiCookie::m_HttpOnly, CCgiCookie::m_InvalidFlag, CCgiCookie::m_Name, CCgiCookie::m_Path, CCgiCookie::m_Secure, CCgiCookie::m_Value, NCBI_THROW2, NStr::PrintableString(), and CCgiCookie::x_EncodeCookie().
Referenced by operator<<().
◆ WriteHeader() [1/2]Definition at line 266 of file ncbicgir.cpp.
References CCgiCookies::Add(), CCgiException::e200_Ok, CRequestStatus::e204_NoContent, CCgiStreamWrapper::eBlockWrites, CCgiStreamWrapper::eChunkedWrites, CCgiUserAgent::eEngine_IE, CCgiRequest::eMethod_HEAD, map_checker< Container >::empty(), CCgiCookies::Empty(), CCgiResponse::eMultipart_mixed, CCgiResponse::eMultipart_none, CCgiResponse::eMultipart_related, CCgiResponse::eMultipart_replace, map_checker< Container >::end(), NStr::eNocase, NStr::EqualNocase(), ERR_POST_X_ONCE, failure, NStr::FindNoCase(), CCgiCookies::GetAllCookiesHttpOnly(), CCgiCookies::GetAllCookiesSecure(), CCgiResponse::GetChunkedTransferEnabled(), GetDiagContext(), CCgiResponse::GetHeaderValue(), CRequestContext::GetNextSubHitID(), CDiagContext::GetRequestContext(), CRequestContext::GetRequestStatus(), CCgiSession::GetSessionCookie(), CCgiResponse::HaveHeaderValue(), HTTP_EOL, i, CCgiResponse::IsRawCgi(), ITERATE, map_checker< Container >::lower_bound(), CCgiResponse::m_Boundary, CCgiResponse::m_Cookies, CCgiResponse::m_DisableTrackingCookie, CCgiResponse::m_ExceptionAfterHEAD, CCgiResponse::m_HeaderValues, CCgiResponse::m_HeaderWritten, CCgiResponse::m_IsMultipart, CCgiResponse::m_JQuery_Callback, CCgiResponse::m_Output, CCgiResponse::m_RequestMethod, CCgiResponse::m_Session, CCgiResponse::m_TrackingCookie, CCgiResponse::m_TrailerValues, NCBI_CGI_THROW_WITH_STATUS, NCBI_THROW, NPOS, NStr::ReplaceInPlace(), CCgiResponse::SetHeaderValue(), CCgiCookie::SetHttpOnly(), CCgiCookie::SetSecure(), CCgiStreamWrapper::SetWriterMode(), CCgiResponse::sm_CacheControl, CCgiResponse::sm_ContentTypeDefault, CCgiResponse::sm_ContentTypeMixed, CCgiResponse::sm_ContentTypeName, CCgiResponse::sm_ContentTypeRelated, CCgiResponse::sm_ContentTypeXMR, CCgiResponse::sm_HTTPStatusDefault, CCgiResponse::sm_HTTPStatusName, NStr::StartsWith(), and Warning().
◆ WriteHeader() [2/2]Write HTTP response header to the output stream.
Definition at line 396 of file ncbicgir.hpp.
References CCgiResponse::out().
Referenced by CPsgCgiApp::Help(), main(), CAsBodyDiagFactory::New(), CCgiRequestProcessor::ProcessAdminRequest_Base(), CCgiContext::ProcessCORSRequest(), CCgiRequestProcessor::ProcessHelpRequest(), CCgiSampleApplication::ProcessPrintEnvironment(), CFastCgiMTSampleRequestProcessor::ProcessRequest(), CGlCgiImageApplication::ProcessRequest(), CCgiRedirectApplication::ProcessRequest(), CGridCgiApplication::ProcessRequest(), CBlastHitMatrixCGIApplication::ProcessRequest(), CCgiSampleApplication::ProcessRequest(), CCgiSessionSampleApplication::ProcessRequest(), CCgiRequestProcessor::ProcessVersionRequest(), CCgi2RCgiApp::RenderPage(), ReportJSONVersion(), s_Demo(), s_WriteHeader(), CGlCgiImageApplication::x_HandleError(), CSoapServerApplication::x_ProcessSoapRequest(), CSoapServerApplication::x_ProcessWsdlRequest(), and CCgiSessionSampleApplication::x_ShowConfigFile().
◆ x_CheckField() [1/2]Definition at line 453 of file ncbicgi.cpp.
References _TROUBLE, CCgiCookies::eCheck_SkipInvalid, CCgiCookies::eCheck_StoreInvalid, CCgiCookies::eCheck_Valid, CCgiCookies::eOnBadCookie_Skip, CCgiCookies::eOnBadCookie_SkipAndError, CCgiCookies::eOnBadCookie_Store, CCgiCookies::eOnBadCookie_StoreAndError, CCgiCookies::eOnBadCookie_ThrowException, ERR_POST_X, str(), and CCgiCookie::x_CheckField().
Referenced by CCgiCookies::Add().
◆ x_CheckField() [2/2] ◆ x_ClientSupportsChunkedTransfer() ◆ x_DelimitedRead()Definition at line 298 of file cgi_entry_reader.cpp.
References _ASSERT, _TROUBLE, _VERIFY, buffer, CT_EOF, CT_EQ_INT_TYPE, CT_INT_TYPE, CT_TO_CHAR_TYPE, CT_TO_INT_TYPE, CCgiEntryReaderContext::eCT_Multipart, CCgiEntryReaderContext::eCT_URLEncoded, NStr::EndsWith(), CCgiEntryReaderContext::eRT_Delimiter, CCgiEntryReaderContext::eRT_EOF, CCgiEntryReaderContext::eRT_LengthBound, CCgiEntryReaderContext::eRT_PartialDelimiter, HTTP_EOL, CCgiRequest::kContentLengthUnknown, CCgiEntryReaderContext::m_Boundary, CCgiEntryReaderContext::m_BytePos, CCgiEntryReaderContext::m_ContentLength, CCgiEntryReaderContext::m_ContentLog, CCgiEntryReaderContext::m_ContentType, CCgiEntryReaderContext::m_In, min(), n, NcbiGetline(), next(), and NPOS.
Referenced by CCgiEntryReaderContext::CCgiEntryReaderContext(), CCgiEntryReader::x_FillBuffer(), CCgiEntryReaderContext::x_ReadMultipartHeaders(), and CCgiEntryReaderContext::x_ReadURLEncodedEntry().
◆ x_EncodeCookie() ◆ x_FillBuffer() void CCgiEntryReader::x_FillBuffer ( SIZE_TYPE count ) privateDefinition at line 112 of file cgi_entry_reader.cpp.
References count, CCgiEntryReaderContext::eRT_Delimiter, CCgiEntryReaderContext::eRT_EOF, CCgiEntryReaderContext::eRT_LengthBound, CCgiEntryReaderContext::eRT_PartialDelimiter, CCgiEntryReader::fHitBoundary, CCgiEntryReader::fHitCR, CCgiEntryReader::fHitCRLF, CCgiEntryReader::fHitLF, CCgiEntryReader::fUnread, CCgiEntryReaderContext::m_Boundary, CCgiEntryReader::m_Buffer, CCgiEntryReader::m_Context, CCgiEntryReader::m_State, max(), min(), n, NPOS, s_MatchesBoundary(), CCgiEntryReaderContext::x_DelimitedRead(), and CCgiEntryReader::x_HitBoundary().
Referenced by CCgiEntryReader::Read(), and CCgiEntryReader::x_Flush().
◆ x_Flush() void CCgiEntryReader::x_Flush ( void ) inlineprivate ◆ x_FlushCurrentEntry() void CCgiEntryReaderContext::x_FlushCurrentEntry ( void ) private ◆ x_ForceComplete() void CCgiEntry::x_ForceComplete ( ) const inlineprivate ◆ x_ForceUnique() void CCgiEntry::x_ForceUnique ( ) inlineprivate ◆ x_GetCharset() string CCgiEntry::x_GetCharset ( void ) const private ◆ x_GetPropertyByName() ◆ x_GetString() ◆ x_HitBoundary() void CCgiEntryReader::x_HitBoundary ( bool final ) private ◆ x_Init()the real constructor code
Definition at line 1094 of file ncbicgi.cpp.
References _ASSERT, CCgiCookies::Add(), eCgi_HttpCookie, eCgi_NProperties, multimap_checker< Container >::end(), NStr::EndsWith(), env, ERR_POST_X, eUrlEncode_None, eUrlEncode_PercentOnly, CCgiRequest::fCookies_SpaceAsHex, CCgiRequest::fCookies_Unencoded, multimap_checker< Container >::find(), flags, CCgiRequest::fOwnEnvironment, CCgiRequest::GetProperty(), CCgiRequest::GetPropertyName(), i, ITERATE, kEmptyStr, CCgiRequest::m_Cookies, CCgiRequest::m_Entries, CCgiRequest::m_Env, CCgiRequest::m_OwnEnv, NCBI_RETHROW, s_AddEntry(), CCgiCookies::SetUrlEncodeFlag(), Warning(), CCgiRequest::x_GetPropertyByName(), CCgiRequest::x_InitRequestContext(), CCgiRequest::x_ProcessInputStream(), CCgiRequest::x_ProcessQueryString(), and CCgiRequest::x_SetClientIpProperty().
Referenced by CCgiRequest::CCgiRequest().
◆ x_InitRequestContext() void CCgiRequest::x_InitRequestContext ( TFlags flags ) privateSet the properties of CRequestContext (HitId, Dtab etc.).
Definition at line 1258 of file ncbicgi.cpp.
References CRequestContext_PassThrough::Deserialize(), CRequestContext_PassThrough::eFormat_UrlEncoded, CRequestContext::eHitID_Request, eNcbiStrings_PHID, multimap_checker< Container >::equal_range(), CCgiRequest::fIgnorePageHitId, CCgiCookies::Find(), flags, g_GetNcbiString(), CCgiRequest::GetRandomProperty(), CDiagContext::GetRequestContext(), CRequestContext::IsSetDtab(), CRequestContext::IsSetHitID(), CRequestContext::IsSetProperty(), CCgiRequest::m_Cookies, CCgiRequest::m_Entries, CRequestContext::SelectLastHitID(), CRequestContext::SetDtab(), CRequestContext::SetHitID(), CRequestContext::SetProperty(), and CCgiRequest::x_GetPropertyByName().
Referenced by CCgiRequest::CCgiRequest(), and CCgiRequest::x_Init().
◆ x_ProcessInputStream()Parse input stream if needed.
Definition at line 1332 of file ncbicgi.cpp.
References AStrEquiv(), buf, eCgi_ContentType, eCgi_RequestMethod, eRead, CCgiRequest::fDoNotParseContent, CCgiRequest::fIncludePreparsedEntries, flags, CCgiRequest::fParseInputOnDemand, CCgiRequest::fSaveRequestContent, CCgiRequest::GetContentLength(), CCgiRequest::GetProperty(), CCgiEntryReaderContext::IncludePreparsedEntries(), CCgiRequest::m_Content, CCgiRequest::m_Entries, CCgiRequest::m_EntryReaderContext, CCgiRequest::m_Input, CCgiRequest::m_InputFD, CCgiRequest::m_OwnInput, NCBI_CATCH_ALL_X, NCBI_THROW2, NcbiCin, NcbiStreamCopy(), CCgiRequest::ParseRemainingContent(), CStreamUtils::Pushback(), NStr::StartsWith(), and STDIN_FILENO.
Referenced by CCgiRequest::Deserialize(), and CCgiRequest::x_Init().
◆ x_ProcessQueryString()Parse entries or indexes from "$QUERY_STRING" or cmd.-line args.
Definition at line 1307 of file ncbicgi.cpp.
References eCgi_QueryString, eCgi_RequestMethod, ctll::empty(), CCgiRequest::fIgnoreQueryString, flags, CCgiRequest::GetProperty(), CCgiRequest::m_Entries, CCgiRequest::m_Indexes, CCgiRequest::m_QueryStringParsed, NULL, CUrlArgs_Parser::SetQueryString(), and CNcbiArguments::Size().
Referenced by CCgiRequest::Deserialize(), and CCgiRequest::x_Init().
◆ x_ReadMultipartHeaders() void CCgiEntryReaderContext::x_ReadMultipartHeaders ( string & name, string & filename, string & content_type ) privateDefinition at line 470 of file cgi_entry_reader.cpp.
References _TROUBLE, CCER, NStr::CompareNocase(), eEntry, NStr::EqualNocase(), ERR_POST_X, CCgiEntryReaderContext::eRT_Delimiter, CCgiEntryReaderContext::eRT_EOF, CCgiEntryReaderContext::eRT_LengthBound, CCgiEntryReaderContext::eRT_PartialDelimiter, kContentDisposition, kContentType, CCgiEntryReaderContext::m_BytePos, NCBI_THROW2, NPOS, s_FindAttribute(), Warning(), and CCgiEntryReaderContext::x_DelimitedRead().
Referenced by CCgiEntryReaderContext::GetNextEntry().
◆ x_ReadURLEncodedEntry() void CCgiEntryReaderContext::x_ReadURLEncodedEntry ( string & name, string & value ) privateDefinition at line 417 of file cgi_entry_reader.cpp.
References CCgiEntryReaderContext::eCT_Null, ERR_POST, CCgiEntryReaderContext::eRT_EOF, ITERATE, CCgiEntryReaderContext::m_ContentType, CCgiEntryReaderContext::m_ContentTypeDeclared, CCgiEntryReaderContext::m_In, NPOS, NStr::PrintableString(), NStr::URLDecodeInPlace(), rapidjson::value, Warning(), and CCgiEntryReaderContext::x_DelimitedRead().
Referenced by CCgiEntryReaderContext::GetNextEntry().
◆ x_RestoreOutputExceptions() void CCgiResponse::x_RestoreOutputExceptions ( void ) private ◆ x_RetrieveSessionId() string CCgiRequest::x_RetrieveSessionId ( ) const private ◆ x_SetClientIpProperty() void CCgiRequest::x_SetClientIpProperty ( TFlags flags ) const private ◆ x_SetSession() [1/2] void CCgiRequest::x_SetSession ( CCgiSession & session ) inline ◆ x_SetSession() [2/2] ◆ x_ValidateHeader() ◆ ~CCgiCookies() CCgiCookies::~CCgiCookies ( void ) inline ◆ ~CCgiEntryReader() CCgiEntryReader::~CCgiEntryReader ( ) private ◆ ~CCgiEntryReaderContext() CCgiEntryReaderContext::~CCgiEntryReaderContext ( ) ◆ ~CCgiRequest() CCgiRequest::~CCgiRequest ( void ) ◆ ~CCgiResponse() CCgiResponse::~CCgiResponse ( void ) ◆ ~CEntryCollector_Base() virtual CEntryCollector_Base::~CEntryCollector_Base ( void ) inlinevirtualDefinition at line 652 of file ncbicgi.hpp.
◆ ~CExtraEntryCollector() CExtraEntryCollector::~CExtraEntryCollector ( void ) inlineoverrideDefinition at line 663 of file ncbicgi.hpp.
◆ ~CRefArgs() CRefArgs::~CRefArgs ( void )Definition at line 66 of file ref_args.cpp.
◆ CGI ◆ kContentLengthUnknown const size_t CCgiRequest::kContentLengthUnknown = (size_t)(-1) static ◆ m_AllHttpOnly bool CCgiCookies::m_AllHttpOnly private ◆ m_AllSecure bool CCgiCookies::m_AllSecure private ◆ m_Args ◆ m_BetweenParts bool CCgiResponse::m_BetweenParts protected ◆ m_Boundary [1/2] string CCgiEntryReaderContext::m_Boundary private ◆ m_Boundary [2/2] string CCgiResponse::m_Boundary protected ◆ m_Buffer string CCgiEntryReader::m_Buffer private ◆ m_BytePos ◆ m_ChunkedTransfer bool CCgiResponse::m_ChunkedTransfer private ◆ m_Content unique_ptr<string> CCgiRequest::m_Content private ◆ m_ContentLength size_t CCgiEntryReaderContext::m_ContentLength private ◆ m_ContentLog string* CCgiEntryReaderContext::m_ContentLog private ◆ m_ContentType [1/2] ◆ m_ContentType [2/2] ◆ m_ContentTypeDeclared bool CCgiEntryReaderContext::m_ContentTypeDeclared private ◆ m_Context ◆ m_Cookies [1/3] TSet CCgiCookies::m_Cookies private ◆ m_Cookies [2/3] ◆ m_Cookies [3/3] ◆ m_CurrentEntry CCgiEntry* CCgiEntryReaderContext::m_CurrentEntry private ◆ m_CurrentReader TReader* CCgiEntryReaderContext::m_CurrentReader private ◆ m_DataDefinition at line 604 of file ncbicgi.hpp.
Referenced by CCgiEntry::GetContentType(), CCgiEntry::GetFilename(), CCgiEntry::GetPosition(), CCgiEntry::GetValue(), CCgiEntry::GetValueReader(), CCgiEntry::GetValueStream(), CCgiEntry::SetContentType(), CCgiEntry::SetFilename(), CCgiEntry::SetPosition(), CCgiEntry::SetValue(), CCgiEntry::x_ForceComplete(), and CCgiEntry::x_ForceUnique().
◆ m_DisableTrackingCookie bool CCgiResponse::m_DisableTrackingCookie private ◆ m_Domain ◆ m_EncodeFlag ◆ m_Entries ◆ m_EntryReaderContext ◆ m_Env ◆ m_ErrBufSize size_t CCgiRequest::m_ErrBufSize privateRequest initialization error buffer size; when initialization code hits unexpected EOF it will try to add diagnostics and print out accumulated request buffer 0 in this variable means no buffer diagnostics.
Definition at line 949 of file ncbicgi.hpp.
◆ m_ExceptionAfterHEAD TCGI_ExceptionAfterHEAD CCgiResponse::m_ExceptionAfterHEAD private ◆ m_Expires ◆ m_Filename ◆ m_HeaderValues TMap CCgiResponse::m_HeaderValues protected ◆ m_HeaderWritten bool CCgiResponse::m_HeaderWritten mutableprotected ◆ m_HostMap ◆ m_HttpOnly bool CCgiCookie::m_HttpOnly private ◆ m_In ◆ m_Indexes ◆ m_Input ◆ m_InputFD int CCgiRequest::m_InputFD private ◆ m_InvalidFlag ◆ m_IsMultipart ◆ m_IsRawCgi bool CCgiResponse::m_IsRawCgi protected ◆ m_JQuery_Callback string CCgiResponse::m_JQuery_Callback private ◆ m_Name ◆ m_Out ◆ m_OutIter ◆ m_OutIterated bool CCgiEntryReaderContext::m_OutIterated private ◆ m_Output ◆ m_OutputExpt CNcbiOstream::iostate CCgiResponse::m_OutputExpt protected ◆ m_OutputFD int CCgiResponse::m_OutputFD protected ◆ m_OwnEnv ◆ m_OwnInput bool CCgiRequest::m_OwnInput private ◆ m_Path ◆ m_Position [1/2] unsigned int CCgiEntryReaderContext::m_Position private ◆ m_Position [2/2] unsigned int CCgiEntry::SData::m_PositionDefinition at line 437 of file ncbicgi.hpp.
◆ m_QueryStringParsed bool CCgiRequest::m_QueryStringParsed private ◆ m_Reader ◆ m_Request ◆ m_RequestMethod ◆ m_RequireWriteHeader bool CCgiResponse::m_RequireWriteHeader protected ◆ m_Secure [1/2] bool CCgiCookie::m_Secure private ◆ m_Secure [2/2] bool CCgiCookies::m_Secure private ◆ m_Session [1/2] ◆ m_Session [2/2] ◆ m_State TState CCgiEntryReader::m_State private ◆ m_ThrowOnBadOutput TCGI_ThrowOnBadOutput CCgiResponse::m_ThrowOnBadOutput private ◆ m_TrackingCookie [1/2] string CCgiRequest::m_TrackingCookie private ◆ m_TrackingCookie [2/2] unique_ptr<CCgiCookie> CCgiResponse::m_TrackingCookie private ◆ m_TrackingEnvHolder ◆ m_TrailerEnabled unique_ptr<bool> CCgiResponse::m_TrailerEnabled mutableprivate ◆ m_TrailerValues TMap CCgiResponse::m_TrailerValues protected ◆ m_Value [1/2] ◆ m_Value [2/2] ◆ NCBI_XCGI_EXPORTParameter to control error handling of incoming cookies.
Does not affect error handling of outgoing cookies set by the application.
Definition at line 357 of file ncbicgi.hpp.
◆ On_Bad_Cookie ◆ sm_AcceptRanges const char * CCgiResponse::sm_AcceptRanges = "Accept-Ranges" staticprotected ◆ sm_AcceptRangesBytes const char * CCgiResponse::sm_AcceptRangesBytes = "bytes" staticprotected ◆ sm_BoundaryPrefix const char * CCgiResponse::sm_BoundaryPrefix = "NCBI_CGI_Boundary_" staticprotected ◆ sm_CacheControl const char * CCgiResponse::sm_CacheControl = "Cache-Control" staticprotected ◆ sm_ContentDispoName const char * CCgiResponse::sm_ContentDispoName = "Content-Disposition" staticprotected ◆ sm_ContentRange const char * CCgiResponse::sm_ContentRange = "Content-Range" staticprotected ◆ sm_ContentTypeDefault const char * CCgiResponse::sm_ContentTypeDefault = "text/html" staticprotected ◆ sm_ContentTypeMixed const char * CCgiResponse::sm_ContentTypeMixed = "multipart/mixed" staticprotected ◆ sm_ContentTypeName const char * CCgiResponse::sm_ContentTypeName = "Content-Type" staticprotected ◆ sm_ContentTypeRelated const char * CCgiResponse::sm_ContentTypeRelated = "multipart/related" staticprotected ◆ sm_ContentTypeXMR const char * CCgiResponse::sm_ContentTypeXMR = "multipart/x-mixed-replace" staticprotected ◆ sm_FilenamePrefix const char * CCgiResponse::sm_FilenamePrefix = "attachment; filename=\"" staticprotected ◆ sm_HTTPStatusDefault const char * CCgiResponse::sm_HTTPStatusDefault = "200 OK" staticprotected ◆ sm_HTTPStatusName const char * CCgiResponse::sm_HTTPStatusName = "Status" staticprotected ◆ sm_LocationName const char * CCgiResponse::sm_LocationName = "Location" staticprotected ◆ CCgiApplication ◆ CCgiContext ◆ CCgiCookies ◆ CCgiEntryReader ◆ CCgiEntryReaderContextRetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4