Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Undefined Index" for HTTP_USER_AGENT and HTTP_HOST #3740

Closed
ghost opened this issue Jun 15, 2013 · 5 comments
Closed

"Undefined Index" for HTTP_USER_AGENT and HTTP_HOST #3740

ghost opened this issue Jun 15, 2013 · 5 comments
Assignees

Comments

@ghost
Copy link

ghost commented Jun 15, 2013

Hi,

two users at the forums:

https://forum.owncloud.org/viewtopic.php?f=23&t=12792
https://forum.owncloud.org/viewtopic.php?f=23&t=11835

reporting that they are getting those Undefined Index errors in their logfiles. This is probably just a cosmetic problem caused by crawlers which are hitting the server.

HTTP_USER_AGENT
Firewalls may filter it or people may configure their clients to omit it.
http://stackoverflow.com/questions/14130830/php-undefined-index-http-user-agent

HTTP_HOST
http://stackoverflow.com/questions/13351948/php-notice-undefined-index-http-host-in-var-script-php-on-line-8
http://bytes.com/topic/php/answers/825248-undefined-index-http_host

Expected behaviour

No fatal errors should be shown in the logfiles

Actual behaviour

Fatal errors are should in the logfiles

Steps to reproduce

No steps to reproduce

Server configuration

Operating system: Debian 7.0

Web server: Apache 2.2.22

Database: SQLite

PHP version: 5.4.4-14

ownCloud version: 5.0.7 / 5.0.6

Logs

{"app":"PHP","message":"Undefined index: HTTP_HOST at \/var\/www\/owncloud\/lib\/request.php#42","level":2,"time":1370802985}
Fatal  PHP Undefined index: HTTP_USER_AGENT at /home/owncloud.mydomain.com/settings/includes.php#73 
@ghost ghost assigned DeepDiver1975 Jun 15, 2013
@DeepDiver1975
Copy link
Member

Fatal PHP Undefined index: HTTP_USER_AGENT at /home/owncloud.mydomain.com/settings/includes.php#73

settings/includes.php is not a file maintained by ownCloud - where is it coming from? THX

@ghost
Copy link
Author

ghost commented Jun 17, 2013

@DeepDiver1975

I'm the user with the HTTP_USER_AGENT problem, just checked my installation and there is NO file with the name includes.php in that folder.. when I'm logged in as ADMIN through IE10 I can see in the OC log on the webpage that every time I visit/update the page the line appears in the logfile..

Fatal PHP Undefined index: HTTP_USER_AGENT at /home/owncloud.mydomain.com/settings/includes.php#73 June 17, 2013 17:36

Fatal PHP Undefined index: HTTP_USER_AGENT at /home/owncloud.mydomain.com/settings/includes.php#73 June 17, 2013 17:35

BUT!! this only seems to happend when I'm logged in as Admin. I tried to log in with my personal account and navigate around in the webinterface of ownCloud. When I check the logfile for that time period there are no errors/fatal PHP.. But then I logged on as Admin, the errors started to appear in the logfile..

@jancborchardt
Copy link
Member

I’m closing this issue because it has been inactive for a few months. This probably means that the issue is not reproducible or it has been fixed in a newer version.

Please reopen if you still encounter this issue with the latest stable version (currently ownCloud 5.0.10) and then please use the issue template. You an also contribute directly by providing a patch – see the developer manual. :)

Thank you!

@ghost
Copy link
Author

ghost commented Aug 17, 2013

I can confirm that the issue with HTTP_USER_AGENT has been resolved in 5.0.10, just updated my installation and there are no more error messages to be found in the logfiles.

Thanks guys!

@jancborchardt
Copy link
Member

@Mannerheim thank you for confirming!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants