Bug 64257

Summary: Need ProxyHTMLIgnoreAttribute directive to skip stripping of custom tag atttributes
Product: Apache httpd-2 Reporter: John David <jdavid1>
Component: mod_proxy_htmlAssignee: Apache HTTPD Bugs Mailing List <bugs>
Status: NEW ---    
Severity: major    
Priority: P2    
Version: 2.4.6   
Target Milestone: ---   
Hardware: PC   
OS: All   

Description John David 2020-03-22 17:54:51 UTC
I created a reverse proxy on an opengrok application with relative easy using the mod_proxy_html package. That was until I realized the parser was stripping out attributes used by the opengrok server to do things like 'show more/less' content. When I turned trace on, I see things like this 'AH01418: Bogus HTML attribute data-toggle-state of span dropped' during the page rendering. Having a directive to tell the SAX parser to ignore the custom tag attributes listed would work perfectly.
e.g.
ProxyHTMLIgnoreAttribute data-toggle-state data-priority ...

I did a search and couldn't find a satisfactory workaround.
Setting 'ProxyHTMLDocType HTML Legacacy' does horrible things to the page styling.

As it is, I will have to scrap mod_proxy_html and rewrite the url's as I hit them.
Comment 1 John David 2020-03-23 14:34:17 UTC
The data-* attribute is used to store custom data private to the page or application.
The data-* attribute gives us the ability to embed custom data attributes on all HTML elements.

It seems that the data-* custom attribute is allowed for all HTML tags. You are removing them.