IBM Support

JR40606: CMVC 213549 - PREVENT A NULLPOINTER EXCEPTION HAPPENING WHEN THE USER-AGENT HEADER FROM THE HTTP REQUEST IS NULL.

Subscribe

You can track all active APARs for this component.

 

APAR status

  • Closed as program error.

Error description

  • In WebSphere Commerce, the null User-Agent HTTP request is not
    being handled correctly. When an HTTP request with a null
    User-Agent header is submitted to access a store home page, a
    blank page will be returned and meanwhile a
    java.lang.NullPointerException having the following stack trace
    gets thrown:
    
    00000025 CommerceSrvr  E
    com.ibm.commerce.webcontroller.RuntimeServletFilter
    doFilterAction CMN0409E: The following error occurred during
    processing:
    "java.lang.NullPointerException".java.lang.NullPointerException
        at java.util.Hashtable.get(Hashtable.java:518)
        at
    com.ibm.commerce.foundation.internal.server.services.httpdevice.
    config.DeviceConfiguration$DeviceLookupTable.get(DeviceConfigura
    tion.java:161)
        at
    com.ibm.commerce.foundation.internal.server.services.httpdevice.
    config.DeviceConfiguration.getDevice(DeviceConfiguration.java:40
    2)
        at
    com.ibm.commerce.foundation.internal.server.services.httpdevice.
    impl.DeviceConfigurationServiceSourceImpl.getDevice(DeviceConfig
    urationServiceSourceImpl.java:75)
        at
    com.ibm.commerce.foundation.internal.server.services.httpdevice.
    DeviceService.getDevice(DeviceService.java:106)
        at
    com.ibm.commerce.webcontroller.RuntimeServletFilter.doFilterActi
    on(RuntimeServletFilter.java:339)
        at
    com.ibm.commerce.webcontroller.RuntimeServletFilter.access$0(Run
    timeServletFilter.java:247)
        at
    com.ibm.commerce.webcontroller.RuntimeServletFilter$1.run(Runtim
    eServletFilter.java:210)
        at
    com.ibm.commerce.webcontroller.RuntimeServletFilter.doFilter(Run
    timeServletFilter.java:231)
        at
    com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(Fi
    lterInstanceWrapper.java:188)
        at
    com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebApp
    FilterChain.java:116)
        at
    com.ibm.ws.webcontainer.filter.WebAppFilterChain._doFilter(WebAp
    pFilterChain.java:77)
        at
    com.ibm.ws.webcontainer.filter.WebAppFilterManager.doFilter(WebA
    ppFilterManager.java:908)
        at
    com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(Ser
    vletWrapper.java:934)
        at
    com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(Ser
    vletWrapper.java:502)
        at
    com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.handleRequest
    (ServletWrapperImpl.java:179)
        at
    com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:
    3933)
        at
    com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.j
    ava:276)
        at
    com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.
    java:931)
        at
    com.ibm.ws.webcontainer.WSWebContainer.handleRequest(WSWebContai
    ner.java:1583)
        at
    com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLin
    k.java:186)
        at
    com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscr
    imination(HttpInboundLink.java:452)
        at
    com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewRe
    quest(HttpInboundLink.java:511)
        at
    com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.processRequ
    est(HttpInboundLink.java:305)
        at
    com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complet
    e(HttpICLReadCallback.java:78)
        at
    com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureComp
    leted(AioReadCompletionListener.java:165)
        at
    com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyn
    cFuture.java:217)
        at
    com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncC
    hannelFuture.java:161)
        at
    com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138)
        at
    com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204)
        at
    com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHand
    ler.java:775)
        at
    com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905)
        at
    com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1604)
    

Local fix

Problem summary

  • USERS AFFECTED:
    WebSphere Commerce users on v7.0
    
    PROBLEM ABSTRACT:
    A null User-Agent header from an HTTP request causes a
    NullPointerException
    
    BUSINESS IMPACT:
    Not able to access the store when the User-Agent in the HTTP
    header of a request is null
    
    RECOMMENDATION:
    

Problem conclusion

  • The problem happens when WebSphere Commerce is trying to perform
    device mapping lookup and observes the null user-agent string.
    The fix is to check if the user agent is null, and if so, do not
    perform the device mapping lookup.
    -------------------------------------------------------------
    The latest available maintenance information can be obtained
    from the Recommended Fixes for WebSphere Commerce technote:
    http://www.ibm.com/support/docview.wss?rs=3046&uid=swg21261296
    

Temporary fix

Comments

APAR Information

  • APAR number

    JR40606

  • Reported component name

    WC BUS EDITION

  • Reported component ID

    5724I3800

  • Reported release

    700

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt

  • Submitted date

    2011-09-09

  • Closed date

    2011-10-28

  • Last modified date

    2011-10-28

  • APAR is sysrouted FROM one or more of the following:

  • APAR is sysrouted TO one or more of the following:

Fix information

  • Fixed component name

    WC BUS EDITION

  • Fixed component ID

    5724I3800

Applicable component levels

  • R700 PSY

       UP

[{"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Product":{"code":"SSYSYL","label":"WebSphere Commerce Enterprise"},"Component":"","ARM Category":[],"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"7.0","Edition":"","Line of Business":{"code":"","label":""}}]

Document Information

Modified date:
28 October 2011