Questions tagged [user-agent]

A user agent is a piece of software (a software agent) that acts on behalf of a user. The term is often used to refer to browsers, and other software that sends network requests. In the HTTP protocol, a user agent identifies itself to the server using a user-agent string. The user-agent string is a string in the header of an HTTP request that identifies the browser, version, device, os, and other information about the device from which the request came.

A user agent is a piece of software (a software agent) that acts on behalf of a user. The term is often used to refer to browsers, and other software that sends network requests. In the HTTP protocol, a user agent identifies itself to the server using a user-agent string. The user-agent string is a string in the header of an HTTP request that identifies the browser, version, device, os, and other information about the device from which the request came.

The user-agent usually consists of the web browser type, the client operating system and device identifier (all with versions or builds). There is not particular standard in how to formulate an user-agent, but browser and device vendors typically standardize within their own scope.

Detection User-agent detection can be hard, especially in the mobile world. Identification of client capabilities usually cannot be done via the user-agent, but must be obtained by looking up the user-agent in a database. The defacto standard user-agent for a device is the one created by its web browser.

2389 questions
0
votes
1 answer

No browsers version found for Chrome

I was using code which I took from internet for scraping amazon. I got first error of 'Maximum amount of retry reached' I read that need to modify useragent credentials in some places. I modified to ; ua =…
xlmaster
  • 659
  • 7
  • 23
0
votes
1 answer

Linux Desktop User Agent Regular Expression?

Does anyone know a good catch-all for Linux user agents? I have a scenario where I need to block Google Tag Manager tags from firing for Linux users. The goal is to prevent Linux data from reaching Google Analytics. I don't want to impact Android…
0
votes
1 answer

Htaccess entry for blocking user agent not working

The user agent blocking code in my .htaccess file stopped working, though I didn't make any recent changes to it. To troubleshoot this I changed the user agent in FF and created a sub-directory with its own .htaccess file and one php file. In that…
user3052443
  • 758
  • 1
  • 7
  • 22
0
votes
2 answers

Webscrape e-commerce

I'm a beginner in webscraping using python - however I need to use it frequently. I'm trying to webscrape e-shop for mobiles to get item name & price. website: https://shop.orange.eg/en/mobiles-and-devices?IsMobile=false My code "using User-agent"…
0
votes
0 answers

Issue: Audit usage of navigator.userAgent, navigator.appVersion, and navigator.platform shown in the nodejs and chrome browser

I started a new project in node.js. am added a path(n point) localhost:5000/api/chats A page or script is accessing at least one of navigator.userAgent, navigator.appVersion, and navigator.platform. Starting in Chrome 101, the amount of information…
0
votes
1 answer

Java HttpHeaders - how to get user agent value?

HttpHeaders headers = new HttpHeaders(); headers.set("Accept", "application/json"); headers.set("User-Agent", "Mozilla/5.0..."); //note - value hard coded I am currently writing a JUnit test where I create a RestTemplate containing the above…
java12399900
  • 1,485
  • 7
  • 26
  • 56
0
votes
0 answers

AWS Amplify Redirect to another Cloudfront Distribution that has a Lambda Edge function

I have an app hosted and deployed on AWS Amplify. I created a separate cloudfront distribution that has a lambda@edge function to detect certain user-agents (for rich social sharing). In the "Rewrites and Redirects" section in Amplify App Settings,…
0
votes
0 answers

Extracting browser from user_agent from dataframe

I need to extract the browser name from a list of user_agents, which is stored as a column in a dataframe. I want to use the Python library user_agents (https://pypi.org/project/user-agents/), but I can't figure out how to apply the command…
0
votes
1 answer

CURLOPT_USERAGENT: Mozilla/5.0 vs Googlebot 2.1 - Is one faster?

Is there any difference in performance when using Googlebot vs Mozilla as the CURLOPT_USERAGENT? I'm hypothesizing that some pages might output simpler HTML when Googlebot is the useragent, but I don't really know.
Adam Capriola
  • 112
  • 1
  • 7
0
votes
2 answers

Cypress: user agent is picked up correctly, but logic tied to it not triggering

Objective: check navigator.userAgent do a simple UI change based on userAgent Findings: the logic works as intended on: real iOS device chrome emulator firefox emulator chrome firefox cypress (PROBLEM) Problem: in cypress, even…
Akber Iqbal
  • 14,487
  • 12
  • 48
  • 70
0
votes
2 answers

How to add device (isMobile) specific code to an SSG page in NextJS?

I have a NextJS app page that should be SSG. I'll fetch all the data that it needs during build time. But a small part of the code (social media share link) needs information about the device of the user. Basically, I want to know whether I'm on…
cbdeveloper
  • 27,898
  • 37
  • 155
  • 336
0
votes
0 answers

change name of user agent in flutter application

I write an application with flutter and want to change the user agent's name in it. can anyone help me how can I do that? I want to change my user agent to the name of my application. it returned : {"data":"Dart/2.16 (dart:io)"}
user17838882
  • 93
  • 2
  • 14
0
votes
1 answer

iframe's content and visibility based on a user-agent

So, I am making my own page (which is going to be an embedded