Improvement requests :  K-Meleon Web Browser Forum
Use this forum to talk about a feature you're missing. 
UserAgent string
Posted by: UberLord
Date: January 13, 2002 11:34PM

Well, seeing as I can't add more to bug #132 I thought I'd mention it here. Below is what's been said so far

uberlord Added At 01/10/02 14:32:23:
I know there's an option to change the useragent, but a K-Melon identifier should *always* be included in the useragent regardless of the user entry.

-

amutch Added At 01/10/02 20:19:21:
Why would a server need to differntiate between the two? I mean, I'm all for letting people know we are out there but what's the technical reason for doing it?
--

jeff Added At 01/12/02 17:20:36:
Nope, k-meleon should not *always* be included in the user agent...that'd make "emulating" other browsers impossible.

However, k-meleon *should* identify itself as K-Meleon somewhere in the default useragent-vendor string. I'm not sure if mozilla has a preference to set this yet. I'm pretty sure it didn't when I coded the useragent strings, or else it was mutually exclusive of setting any other useragent strings.

Now, if there is a "vendor" preference, then those who are inclined to make k-meleon *always* contain k-meleon somewhere in the useragent sting, but it would probably not be a preference I'd want to add to the GUI.

[Changed Status from "Unconfirmed" to "Open"]
[Changed Owner from "Brian" to "jeff"]

@ jeff - Opera 6.0 contains Opera in its User agent string even when emulating other browsers. It simply bolts Opera/6 at the end of the string - this seems to work well. Mozilla does not have an option to change the useragent in 0.9.7, but its possible to distinguish between this and NetScape 6 because NetScape6 puts NetScape/6 in the string. I think K-Melon should do the same

@ amutch - Technically the server should not *have* to differentiate between the two seeing as it uses Gecko for rendering - I just like to know what browser is looking at my site

*shrugs*

K-Melon is the only browser I've seen so far where it's impossible to determine as K-Melon from the useragent string - i just don't like it IMHO (the useragent - not k-melon - lol)

Options: ReplyQuote
Re: UserAgent string
Posted by: po
Date: January 14, 2002 12:08AM

well, to be fair, that's a decidedly server-side perspective... winking smiley

i think it should definitely be possible to user precisely whatever you want for the useragent string, but i guess maybe making all the options available from the GUI contain a tip-off wouldn't hurt anything, if it truly does work for opera... i don't know anything about that. my two cents.

Options: ReplyQuote
Re: UserAgent string
Posted by: andres
Date: January 14, 2002 11:04AM

I have been using

user_pref("general.useragent.override", "Mozilla/5.0 K-Meleon/0.6 (Windows; U; Win98; en) Netscape6/6.1");

with no problems whatsoever. The machines still think I'm using Netscape 6 winking smiley

Options: ReplyQuote
Re: UserAgent string
Posted by: Andrew
Date: January 14, 2002 02:31PM

I'm still not clear on what the real issue is here. Yes, I want people to know that K-Meleon is being used. But other than the issue of usage, is there a reason for tagging the browser as K-Meleon?

Andrew

Options: ReplyQuote
Re: UserAgent string
Posted by: UberLord
Date: January 14, 2002 11:29PM

Here's a reason - I support an web-based data capture program written in PHP. Recently, a client asked if I could block all browsers with a nice message that were NOT on his list.

After implementing my change (basing it all on the UserAgent string) I tested my code against every browser I could find for every OS that I had. Now my client doesn't want to allow K-Melon through because his technical support team don't know about it - regardless of the fact that they allow NetScape 6 and Mozilla through.

Now, this isn't a particulary big problem because I doubt if any K-Melon users would ever goto that intranet site. It works 100% with my site - but thats not the point. My Client which I'm developing for doesn't like it. The Client pays my company who in turn pay my wages.

Reason enough?

Options: ReplyQuote
Re: UserAgent string
Posted by: Deft
Date: January 18, 2002 12:15AM

Uberlord,

That is a good reason, but it is of course technically impossible, as it will always be possible to fake what browser you are using. Possibly you could tell the client simply that you have coded it to deny unlisted browsers but that it's not possible to ensure people don't go around it?

Options: ReplyQuote
Re: UserAgent string
Posted by: UberLord
Date: January 21, 2002 01:52PM

Sure you can always fake the string. But I'm after trapping browsers, not crackers.

My Client is aware that there is not much I can do about people faking a user agent string if they really wanted to. The point here is that why does K-Melon even have the option for entering your own user agent string? Is there a reason why this option exists? Really kinda defeats the purpose behind the user agent string if you give the option to abuse it

Options: ReplyQuote
Re: UserAgent string
Posted by: Andrew
Date: January 21, 2002 03:22PM

UberLord,

The reason for the option is that there are times that for Javascript, browser sniffing, etc. you need to be able to emulate one of the other browsers. While your client is looking to specfically block K-Meleon, other sites are just lazy and block K-Meleon inadvertently. Some people also like the privacy aspect of being able to hide their UserAgent. Sure, it is prone to abuse but I think many people view browser sniffing and the unwillingness to support standards compliant code as abuse too.
smiling smiley
I would just tell the client that you've blocked it as best as you can.

Andrew

Options: ReplyQuote
Re: UserAgent string
Posted by: UberLord
Date: January 25, 2002 01:10AM

Andrew

I still do not see the problem. According to the standard found at http://www.w3c.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.43 , there is nothing wrong with adding the token KMelon/0.6 at the end of the string - thats all I ask. So it should't break any javascript apps (which use the navigator object or netscapes ua.js script). As to emulating, Opera eumlates 4 other browsers - including mozilla. In all cases it still puts the token Opera/6 in the string and this hasn't broken any javascript sniffing.

Uber

Options: ReplyQuote
Re: UserAgent string
Posted by: Andrew
Date: January 25, 2002 02:27AM

UberLord,

I think we are talking past each other here. I agree that, if practical, the K-Meleon token be added to the UserAgent string. However, I didn't agree that we shouldn't provide the option to allow users to modify the UserAgent to their own setting. While you are correct about JS issues, there is other browser sniffing going on that is breaking in K-Meleon, not for legitimate reasons but because of bad code. One of the things that K-Meleon has emphasized is customization. While some people may abuse that, I would not want to remove the option.

Andrew

Options: ReplyQuote
Re: UserAgent string
Posted by: 133t
Date: March 03, 2002 02:44AM

Well if you add the KMelon/0.6 to the end it should work fine because the server agents will see the first part and the KMeleon tag at the end wont affect it. Like this for the UserAgent string:

Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:0.9.5) Gecko/20011011 KMelon/0.6

Options: ReplyQuote
Re: UserAgent string
Posted by: Kevin
Date: March 04, 2002 05:28PM

a factor in my choice of kmeleon is the fact i can change the user string. i think the user agent string should be able to be modified with out a kmeleon tag for the simple fact that if you want to visit a site that only lets one or two browser you should of that right. perhaps a option to add a kmeleon identifier at the end of the modified user string as for the risk of getting a page that was not desgned to standards and therefore broken well that is a risk your going to have to take if yoou modfie a user sting. besdies getting a broken page is better then not getting that page at all.

Options: ReplyQuote


K-Meleon forum is powered by Phorum.