httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bennett, Tony" <Bennett.T...@con-way.com>
Subject RE: [users@httpd] Android device ID not show on access_log
Date Fri, 07 Dec 2012 15:46:52 GMT
FYI:  On my DroidX, I have found that the User-Agent sent to apache is different based upon
which browser on Android that you use:

Firefox produces:
   "Mozilla/5.0 (Android; Mobile; rv:17.0) Gecko/17.0 Firefox/17.0"

The built-in browser produces:

    "Mozilla/5.0 (Linux; U; Android 2.3.4; en-us; DROIDX Build/4.5.1_57_DX8-51) AppleWebKit/533.1
(KHTML, like Gecko) Version/4.0 Mobile Safari/533.1"


-----Original Message-----
From: J.Lance Wilkinson [mailto:jlw12@psu.edu] 
Sent: Friday, December 07, 2012 5:16 AM
To: users@httpd.apache.org
Cc: jlw12@psu.edu
Subject: Re: [users@httpd] Android device ID not show on access_log

Chau Pham wrote:
> Thank you so much, both of you who answered me,
> I was wrong when not mentioned about the header.
>  
> the header, it is "User-Agent" passed to apache server(version  2.2.15)
> in apache configuration, i used:
>  
> LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" 
> " combined

	I use the same version of HTTPD.   MY log files, when I include that
	element in the LogFormat, present the entire string of the user agent
	(not a fragment in the middle like you're describing).   Are you
	examining the actual log files, or are you looking at something
	that has been run through a log file interpreter of some sort, since
	you're not only reporting not seeing the "device id" but also seem to
	suggest the user agent information logged doesn't have the prefixing
	"Mozilla/5.0" you're cited in your client side header.

	OR do you possibly have an intervening proxy or something that's
	replacing the User Agent being passed -- where does this
	"stagefright/1.2" you're citing come from instead of "Mozilla/5.0"?

	e.g., here's one of my log file entries for an Android client (edited
	to obscure privacy info and wrapped into xx lines to fit reasonable
	platen widths):

XX.XXX.XXX.XXX - - [29/Nov/2012:22:21:36 -0500]
	"GET /cgi-bin/fizzbin.php?card=qhears HTTP/1.1" 302 349
		"http://xxx.yyy.zzz/cgi-bin/ssredirpg?D=BCT"
			"Mozilla/5.0 (Linux; U; Android 4.0.4; en-us; SGH-T999
				Build/IMM76D) AppleWebKit/534.30 (KHTML, like
					Gecko) Version/4.0 Mobile
						Safari/534.30"

	As you can see, Device ID is there in the raw log file.  My LogFormat
	directive is as follows (again, wrapped for clarity):

LogFormat
     "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined

>  
> The option "%{User-Agent}i" is to display header,
>  
> it works fine for computer, laptop, and apple(iphone, ipad) device
> however when I use Android then access_log in service side prints out:
>  
> 172.16.33.124 - - [07/Dec/2012:13:29:37 +0900] "GET 
> /data/playgirls-14.ts HTTP/1.1" 200 2103156 "-" "stagefright/1.2 
> (Linux;Android 4.0.4)"
>  
>  
> - client side, the header is:
>  
> 
> Mozilla/5.0 (Linux; U; Android 4.0.4; ko-kr; SHW-M380W Build/IMM76D) 
> AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Safari/534.30


-- 
J.Lance Wilkinson ("Lance")		InterNet: Lance.Wilkinson@psu.edu
Systems Design Specialist - Lead	Phone: (814) 865-4870
Digital Library Technologies		FAX:   (814) 863-3560
E3 Paterno Library
Penn State University
University Park, PA 16802
http://ucs.psu.edu/home/jlw12@psu.edu?fmt=freebusy

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message