Skip to content

Commit

Permalink
[server] Fix wrong debug output name and added HTTP_AUTHORIZATION
Browse files Browse the repository at this point in the history
  • Loading branch information
elpaso committed Jan 12, 2017
1 parent c9a8e5b commit c484742
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions src/server/qgsserver.cpp
Expand Up @@ -158,18 +158,18 @@ void QgsServer::printRequestParameters( const QMap< QString, QString>& parameter
*/
void QgsServer::printRequestInfos()
{
QgsMessageLog::logMessage( QStringLiteral( "********************new request***************" ), QStringLiteral( "Server" ), QgsMessageLog::INFO );
QgsMessageLog::logMessage( QStringLiteral( "******************** New request ***************" ), QStringLiteral( "Server" ), QgsMessageLog::INFO );
if ( getenv( "REMOTE_ADDR" ) )
{
QgsMessageLog::logMessage( "remote ip: " + QString( getenv( "REMOTE_ADDR" ) ), QStringLiteral( "Server" ), QgsMessageLog::INFO );
QgsMessageLog::logMessage( "REMOTE_ADDR: " + QString( getenv( "REMOTE_ADDR" ) ), QStringLiteral( "Server" ), QgsMessageLog::INFO );
}
if ( getenv( "REMOTE_HOST" ) )
{
QgsMessageLog::logMessage( "remote ip: " + QString( getenv( "REMOTE_HOST" ) ), QStringLiteral( "Server" ), QgsMessageLog::INFO );
QgsMessageLog::logMessage( "REMOTE_HOST: " + QString( getenv( "REMOTE_HOST" ) ), QStringLiteral( "Server" ), QgsMessageLog::INFO );
}
if ( getenv( "REMOTE_USER" ) )
{
QgsMessageLog::logMessage( "remote user: " + QString( getenv( "REMOTE_USER" ) ), QStringLiteral( "Server" ), QgsMessageLog::INFO );
QgsMessageLog::logMessage( "REMOTE_USER: " + QString( getenv( "REMOTE_USER" ) ), QStringLiteral( "Server" ), QgsMessageLog::INFO );
}
if ( getenv( "REMOTE_IDENT" ) )
{
Expand Down Expand Up @@ -199,6 +199,10 @@ void QgsServer::printRequestInfos()
{
QgsMessageLog::logMessage( "NO_PROXY: " + QString( getenv( "NO_PROXY" ) ), QStringLiteral( "Server" ), QgsMessageLog::INFO );
}
if ( getenv( "HTTP_AUTHORIZATION" ) )
{
QgsMessageLog::logMessage( "HTTP_AUTHORIZATION: " + QString( getenv( "HTTP_AUTHORIZATION" ) ), QStringLiteral( "Server" ), QgsMessageLog::INFO );
}
}

/**
Expand Down

5 comments on commit c484742

@rldhont
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Has to be backported ?

@elpaso
Copy link
Contributor Author

@elpaso elpaso commented on c484742 Jan 13, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@rldhont I don't know if it worth, it's just all about debug info: fixing typos and adding HTTP_AUTHORIZATION to the list of debug infos. Line 168 was plain wrong though and could be considered as a bug.
BTW, backporting would be harmless and straightforward.

@rldhont
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@elpaso I will do it

@elpaso
Copy link
Contributor Author

@elpaso elpaso commented on c484742 Jan 13, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@rldhont
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

Please sign in to comment.