Top Description Fields Constructors Methods
org.apache.catalina.filters

public Class WebdavFixFilter

extends GenericFilter
Class Inheritance
Imports
java.io.IOException, jakarta.servlet.FilterChain, .GenericFilter, .ServletException, .ServletRequest, .ServletResponse, jakarta.servlet.http.HttpServletRequest, .HttpServletResponse, org.apache.tomcat.util.res.StringManager

Filter that attempts to force MS WebDAV clients connecting on port 80 to use a WebDAV client that actually works. Other workarounds that might help include: Generally each different version of the MS client has a different set of problems.

Todo

Update this filter to recognise specific MS clients and apply the appropriate workarounds for that particular client

As a filter, this is configured in web.xml like any other Filter. You usually want to map this filter to whatever your WebDAV servlet is mapped to.

In addition to the issues fixed by this Filter, the following issues have also been observed that cannot be fixed by this filter. Where possible the filter will add an message to the logs.

XP x64 SP2 (MiniRedir Version 3790)

Field Summary

Modifier and TypeField and Description
private static final long
protected static final StringManager
private static final String
private static final String
private static final String

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
private String
public void
doFilter(ServletRequest
The request to process
request
,
ServletResponse
The response associated with the request
response
,
FilterChain
Provides access to the next filter in the chain for this filter to pass the request and response to for further processing
chain
)

Implements jakarta.servlet.Filter.doFilter.

Check for the broken MS WebDAV client and if detected issue a re-direct that hopefully will cause the non-broken client to be used.

Inherited from jakarta.servlet.GenericFilter:
getFilterConfiggetFilterNamegetInitParametergetInitParameterNamesgetServletContextinitinit

Field Detail

serialVersionUIDback to summary
private static final long serialVersionUID

Hides jakarta.servlet.GenericFilter.serialVersionUID.

smback to summary
protected static final StringManager sm
UA_MINIDIR_5_1_2600back to summary
private static final String UA_MINIDIR_5_1_2600
UA_MINIDIR_5_2_3790back to summary
private static final String UA_MINIDIR_5_2_3790
UA_MINIDIR_STARTback to summary
private static final String UA_MINIDIR_START

Constructor Detail

WebdavFixFilterback to summary
public WebdavFixFilter()

Method Detail

buildRedirectback to summary
private String buildRedirect(HttpServletRequest request)
doFilterback to summary
public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws IOException, ServletException

Implements jakarta.servlet.Filter.doFilter.

Check for the broken MS WebDAV client and if detected issue a re-direct that hopefully will cause the non-broken client to be used.

Parameters
request:ServletRequest

Doc from jakarta.servlet.Filter.doFilter.

The request to process

response:ServletResponse

Doc from jakarta.servlet.Filter.doFilter.

The response associated with the request

chain:FilterChain

Doc from jakarta.servlet.Filter.doFilter.

Provides access to the next filter in the chain for this filter to pass the request and response to for further processing

Annotations
@Override
Exceptions
IOException:

Doc from jakarta.servlet.Filter.doFilter.

if an I/O error occurs during this filter's processing of the request

ServletException:

Doc from jakarta.servlet.Filter.doFilter.

if the processing fails for any other reason