Getting User-Agent through J2ME Client

Hi, i think most of the developers here might have come across this problem.
I have a servlet that will get the client's User-Agent headers value when the client access it. When i access the servlet through a phone browser, the header will give me the phone's user agent. But when i access the same servlet through my J2ME client, the header will return a value of 'UNTRUSTED/1.0' string which doesn't contain any user agent info.
I understand that in JSR implementation the 'UNTRUSTED' string will be appended to the User Agent header, but the original user agent value is not there. Does anyone knows what is the reason behind this?
Thanx.
FooShyn

first:
- do not multipost the same message
second:
- did you put headers on your connection in your application?
- and the only useragent that you can get is the useragent defined in the app...
for example:
try {
      c = (HttpConnection)Connector.open(url);
      c.setRequestMethod(HttpConnection.GET);
      c.setRequestProperty("IF-Modified-Since", "10 Nov 2000 17:29:12 GMT");
      c.setRequestProperty("User-Agent","Profile/MIDP-1.0 Confirguration/CLDC-1.0");
      c.setRequestProperty("Content-Language",      "en-CA");
      os = c.openOutputStream();
...taken from http://developers.sun.com/techtopics/mobility/midp/articles/network/ThirdExample.java

Similar Messages

  • Get User Agent (Browser) in Webdynpro 7.01

    Hello Community,
    Some time ago, I already asked this question. Then, we were on NW04. That was the Thread: [Old Thread|Get User Agent (Browser) in Webdynpro; 
    The solution to retrieve the User-Agent was:
    HttpServletRequest request =((IWebContextAdapter) WDWebContextAdapter.getWebContextAdapter()).getHttpServletRequest();
    Now, "IWebContextAdapter" does not work anymore. So I'm in need of another solution. The suggestion of
    HttpServletRequest request = (HttpServletRequest)WDProtocolAdapter.getProtocolAdapter().getRequestObject();
    String value = request.getHeader("<Param Name>");
    in the old thread still throws a "ClassCastException".
    I have also found this Thread: [Other Thread|Get User Agent;
    But here the suggestion is
    HttpServletRequest request = WDProtocolAdapter.getProtocolAdapter().getRequestObject().getProtocolRequest();      
    String userAgent = request.getHeader("User-Agent");
    what doesn't work, because it seems, there is no method "getProtocolRequest()".
    I'd be glad, if anyone would suggest a working way of how to retrieve the User Agent in webdynpro NW 7.0 EHP 1 SPS 04.
    Thank you very much,
    Best regards,
    Christian

    Hi Christian,
    Can you try using this line of code. You can directly get the value of the request object using this.
    WDProtocolAdapter.getProtocolAdapter().getRequestObject().getParameter("parameter_name");
    // There is getParameterMap() method in which you can know what all parameters are available to be captured.
    Map parameterMap =   WDProtocolAdapter.getProtocolAdapter().getRequestObject().getParameterMap();
    I hope this helps.
    Thanks and Regards,
    Pravesh

  • User-agent information

    Hello,
    Do you known, how to get user-agent inoformation with JavaScript about client application? For example about Adobe Reader?
    Thank you very much.

    Better yet:
    xfa.host.appType
    xfa.host.name
    xfa.host.version
    xfa.host... (see previous post)

  • Mobile RD Clients - User-Agent string

    Anyone happen to know what, if any, user-agent string the RD client for Android (and\or IOS) is using when connecting via an RD Gateway?
    The Windows RD client uses "MS-RDGateway/1.0" but it appears that the Android client (at least) does not, and I can't for the life of me get a packet capture to decrypt the traffic.
    Thanks

    Got this one sorted - looks like internal RemoteAppAndDesktop connections connect via 3389 through the RDGateway.
    Here's what I ended up with: http://blogs.serioustek.net/post/2014/10/04/load-balancing-remote-desktop-gateway-with-citrix-netscaler-part-2.aspx 

  • How to get iphones / ipad user agent for internet access

    Hi.
    We recently setup some wireless, and I'm wondering how I can get iphones and ipads connected to the internet without prompting for a username and password. Even if it does prompt and we put in our domain credentials, things don't work.. it's like it heavily restricts access. However if you put DOMAINNAME\ in front of your user name, then it seems to work.
    Without making static IP reservations and attaching those ip's to no authentication in IronPort... isn't there a way to assign these devices to a policy via their user agent string? Problem is finding that string amongst different versions of iphones and ipads.
    I visited www.ipchicken.com on my iphone and it said Browser: Mozilla/5.0 (iPhone; U; CPU iPhone OS 4_3_2 like Mac OS X; en-us)
    AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8H7 Safari/6533.18.5
    What part of this do I copy into the user agents field for my no autnentication identity that I'm trying to alter? I tried putting AppleWebKit in, but it still blocks almost everything.
    Right now in this Allowed User Agents identiy i have Windows Update checked, as well as these:
    (MSOffice\x2014)
    Microsoft NCSI
    SSLSoapClient
    AppleWebKit (does not seem to work)
    Thanks for the help!

    I think I figured it out.  Followed this closely:
    https://ironport.custhelp.com/cgi-bin/ironport.cfg/php/enduser/std_adp.php?p_faqid=1426&p_sid=ODIeCGuk&p_lva=1713&p_li=cF91c2VyaWQ9MXJvblAwcnQmcF9wYXNzd2Q9Zm8wQmE1
    Also do you guys know if the custom user agent field can accept wildcards?  Problem is, every version of iOS for iPhone 1, 3G, 3GS, 4, and iPad 1 & 2, or ipod touch (various generations) all have variations in their user strings.  If I could just do a blanket statement for like *iphone* , *ipad*, etc.... that would be easier.
    So are there any wildcards or txt masks that can be put in and interpreted in the custom user agents field?

  • How to get no.of users in a specific client

    HI,
       I need to find the no of users in a specific client , but i don't have accounts to all the clients.  I tried from one client where i have the account and executed SE16N and table usr02  got only client specific users list. And as per my understanding USR02 is a client speicific table.
      What is the best to find the no of  users for all the clients  , is it possible from SQL query lik select count(*)from usr02 where mandt etc.. ? or is there any best way ?
    Regards
    Veeramalla.

    Hi venkatesh,
    Incase you can access the database you can take the dump of user count in all the clients using the below mentioned queries
    Select count(bname) from <schema>.usr02 where mandt='xxx';
    You need to run this for each client.
    Another alternative is to create an aBAP program in the client for which u have access to get the details.
    Code could have the following lines
    data: number(6); clientno(3);
    parameters: clientlist like t000-mandt;  //fill in this clientlist parameter with the list of clients u have in ur system
    clientno= 1
    loop
    if clientno < 40
       Select count(bname) into number from <schema>.usr02 where mandt= clientlist(clientno);
        clientno = clientno + 1
        clear number;
    else
      exit;
    endloop.

  • How to get the system property - user.name from a client system

    Hi All,
    I have an application which would enable active users from the domain of the company. I want to get the name of the client from the system. I tried to run it on the local machine from Jdeveloper, it returned me the correct user name. But when the application is deployed on the Oracle Application server, and i hit the URL of the application, it returns the server URL.
    I understand that the JSP works on the server side here but help me out to get a solution. I want to read the user name from the client side.
    Thanks in advance!
    Akhil

    Akhil,
    I hope this will never work. Think about your requirement for a second....
    This would mean an application is able to see my user credentials without my knowledge. It's bad enough the know my IP if I'm not using TOR.
    To get your requirement to work you have to redefine it a bit. The user have to log in to your application. The application holds the name together with an ID of the session to know the user in further requests.
    Thats a basic security theme, described in the dos [Adding Security to a Fusion Web Application|http://download.oracle.com/docs/cd/E12839_01/web.1111/b31974/adding_security.htm] .
    Timo

  • How to enable SCCM 2012 clients to get Windows Updates through SSL VPN

    I would like my SCCM 2012 client laptops to get Windows Updates through SSL VPN.
    I suppose I need to add VPN Subnet in my boundary and boundary group.
    What other setting I need to enable?
    At this moment, on the 'Software Update Point Component Properties' "Allow intranet-only client connections" radio button is active. Do I neeed to select "Allow both intranet and internet client connections" and Enable SSL communications
    for the WSUS server?
    or are there something else I need to check?

    No, a VPN client is no different than a client connected internally as far as the network is concerned and as far as ConfigMgr is concerned there is no way to explicitly know any different. Internet clients literally are those that connect via the Internet
    using IBCM.
    Jason | http://blog.configmgrftw.com

  • To get list of users using universe designer client tools

    Hi Experts,
    Is there any way we can get the list of users using universe designer client tool.
    Thanks,
    Shiva Gunturu

    Hi Shiva,
    Refer to chapter 12 section "User events enabled for clients"
    http://help.sap.com/businessobject/product_guides/boexir31SP3/en/xi31_sp3_bip_admin_en.pdf
    In XI 3.1 client auditing is a bit limited, you may need to do some testing to determine if it is possible to audit what you are looking for.
    Hope it helps
    Thanks
    Toby
    http://help.sap.com/businessobject/product_guides/boexir31SP3/en/xi31_sp3_bip_admin_en.pdf

  • Using IE but getting Mozilla/4.0  in user-agent header

    I am using IE but am getting following while printing headers. Why?
    Name: user-agent
    Value: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1)

    This string is correct. You're using a mozillacompatible (Moz 4.0) useragent IE 6.0 (MSIE 6.0) on Windows XP (NT 5.1). For FireFox it should look like:Mozilla/5.0 (Windows; U; Windows NT 5.1; nl; rv:1.8.1.4) Gecko/20070515 Firefox/2.0.0.4Maybe you need to read something more about the useragent strings. This has actually nothing to do with Java nor servlets.

  • Can we get user's phone number through coding

    HI, I want to know that, how can we get user's phone number through coding and is it possible to send sms to some number without concerning to user. I required this for developing the mobile tracker application which will detect that the phone is stolen.

    The developer forums are here: http://devforums.apple.com
    Documentation for iOS developers is here: http://developer.apple.com/devcenter/ios/index.action

  • [svn:bz-trunk] 9714: Bug: BLZ-424 - Incorrect user-agent string for Opera 10 in flex.messaging. client.UserAgentSettings

    Revision: 9714
    Author:   [email protected]
    Date:     2009-08-27 14:20:06 -0700 (Thu, 27 Aug 2009)
    Log Message:
    Bug: BLZ-424 - Incorrect user-agent string for Opera 10 in flex.messaging.client.UserAgentSettings
    QA: Yes
    Doc: No
    Ticket Links:
        http://bugs.adobe.com/jira/browse/BLZ-424
    Modified Paths:
        blazeds/trunk/modules/core/src/flex/messaging/client/UserAgentSettings.java
        blazeds/trunk/resources/config/services-config.xml

  • When ever we opened HFM Application through workspace, getting struck and through client is going good

    When ever we opened HFM Application through workspace, getting struck and through client is going good. Any guess on this.. please share.
    We have tried to Reset IIS, Recycle Services & Reboot Servers -- After this some time will works good , Then again isue repeats.
    Appriciate your help!
    Regards,
    RSV

    Yeah the issue seem to be with IIS,
    Try launching the application through the url
    http://hfmwebserver/hfm/logon/processlogon.asp?workspace=false&username=admin&password=password  replacing hfmwebserver with web server you have in your env and username and password respectively to see if there is some improper registration of Web Server with HFM.
    Also check IIS worker process settings.
    Thanks
    Amith

  • Trying to get Firefox to open in User Agent "Internet Explorer"

    I run an Internet Cafe and have recently installed Ubuntu 10.04 over Micro$oft.
    I HAVE to give customers an alternative to Live Messenger.
    I have TokBox setup .. but gives problems now & then.
    I need to cover all bases or lose customers.
    The only viable alternative I have found is '''EBuddy'''.
    Now the problem is .. when I log in using Internet Explorer and I connect to a contact - I can see the start video call "button".
    Any other browser and the webcam button does not show.
    All of the Firefox & Seamonkey User Agent Switchers I have tried work .. but I cannot expect the customer to know that they need to switch User Agent before they can use the webcam.
    I need to Launch either Firefox or Seamonkey (preferably Seamonkey - if the fix is to be a permanent one) in Internet Explorer mode.
    A permanent "fix" for Firefox was suggested on the Ubuntu Forum ...
    1. Open about:config
    2. Right-click, choose "New" > "String"
    3. Type "general.useragent.override" (no parentheses) into the "New String Value" dialog box that appears and press "Enter." Type or copy and paste the desired new user agent string into the "Enter String Value" box (in this case "Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1)" )
    When you're done, copy that Firefox profile to all of your computers (the .mozilla folder)
    I tried this on Seamonkey .. but it did not have the desired effect = no start video call button.
    There is a Proxy Tool add on for Seamonkey which can change the user agent and this works. Same thing for Firefox.
    But the user agent is back to default on browser re-start.
    In an ideal world I would like to create a Launcher on Ubuntu desktop which would open either Firefox or Seamonkey on the E Buddy sign in page and the User Agent would automatically be set to IE8 or 9.

    Try to set the user agent via a user.js file.
    *http://kb.mozillazine.org/user.js_file
    user_pref("general.useragent.override", "<IE user agent>");

  • Windows Server 2012 Group Policy Block USB Storage devices @ User Level Not getting applied on a Domain Client machine with Windows Server 2008 R2. Why?

    Hello,
    I have a Windows Server 2012 R2.
    I have configured the Group Policy on it to block the usage of USB - Storage Devices @ user level on the client machines. It works properly for my Windows 7 client machines but it's not working on one of the machine having Windows Server 2008 R2 installed
    on it (this machine is also a domain client in the same domain).
    I will really be thankful if anyone can suggest some solution to this issue.
    Please feel free to write back in-case I have missed anything obvious to be shared.
    Thanks!
    -Vinay Pugalia
    If a post answers your question, please click "Mark As Answer" on that post or
    "Vote as Helpful".
    Web : Inkey Solutions
    Blog : My Blog
    Email : Vinay Pugalia

    Hi,
    Any update?
    Just checking in to see if the suggestions were helpful. Please let us know if you would like further assistance.
    Best Regards,
    Andy Qi
    TechNet
    Subscriber Support
    If you are TechNet
    Subscription user and have any feedback on our support quality, please send your feedbackhere.
    Andy Qi
    TechNet Community Support

Maybe you are looking for

  • Create materialized view with specific column sizes

    Hi all, I'm trying to create a materialized view with a specific a column size. Something like create materialized view test_mv refresh force on demand as select id,        cast(my_compound_field as nvarchar2(50)) from ( select id,               fiel

  • I need a CTP sample

    hello , I am a newbie to CRM. I need information about CTP ( capable to promise) in e-selling order scenario..if possible could you send me some screenshots that show what is CPT ?.. i'm also looking for any  tutorials or papers about realtion betwee

  • What is the latest on the EP migration tools?

    I am still looking for the tools for migration from EP 6.0 SP2 to the NW version of EP.  Someone mentioned earlier they were planned for release on 2/16/2005 but there is nothing on the service marketplace yet.  Can anyone provide any info here? Than

  • Error compiling "Undefined symbols for architecture armv6:"

    Hey, I seem to be getting errors like this a lot... I only just started making apps yesterday, so they are all still very basic, but I was wondering if I am doing something wrong when I import frameworks? This may be caused from something else entire

  • How to update IPhone 4 to IOS 5 ?

    Hello teams, I tried to update my iPhone 4 (iOS 4.3.3) to iOS 5 and it seems I lost everything after the update. (calendar, notes, contacts, sms history, photos and music). I hope you can help me to retrieve my data. Here is what I did : Started iTun