esapi-java-legacy icon indicating copy to clipboard operation
esapi-java-legacy copied to clipboard

java.lang.NoClassDefFoundError: org/owasp/esapi/errors/EncodingException

Open meg23 opened this issue 10 years ago • 9 comments

From [email protected] on April 20, 2011 02:52:37

What steps will reproduce the problem? 1.Use Validator.validateInput method for some validation. some people are facing error 2. Error comes java.lang.NoClassDefFoundError: org/owasp/esapi/errors/EncodingException 3. What is the expected output? What do you see instead? Class not found error should not come. java.lang.NoClassDefFoundError: org/owasp/esapi/errors/EncodingException What version of the product are you using? On what operating system? esapi-2.0_rc10 Does this issue affect only a specified browser or set of browsers? Please provide any additional information below. The class is there in classpath. I don't see why this error should be coming.

Original issue: http://code.google.com/p/owasp-esapi-java/issues/detail?id=218

meg23 avatar Nov 13 '14 18:11 meg23

From [email protected] on April 19, 2011 23:53:21

I would also need to know, when the final reviewed version of API be released?

meg23 avatar Nov 13 '14 18:11 meg23

Is this issue resolved? Any workaround to fix this one in application?

shahshikha630 avatar Jan 25 '24 05:01 shahshikha630

This issue doesn't have enough information provided to duplicate it. Perhaps you can provide a test case to replicate the issue? If so, please do so.

-kevin

On Thu, Jan 25, 2024, 12:28 AM shahshikha630 @.***> wrote:

Is this issue resolved? Any workaround to fix this one in application?

— Reply to this email directly, view it on GitHub https://github.com/ESAPI/esapi-java-legacy/issues/227#issuecomment-1909382196, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAO6PG3HIWSFF3AIUQQQF2TYQHUQHAVCNFSM4AXLF7U2U5DIOJSWCZC7NNSXTN2JONZXKZKDN5WW2ZLOOQ5TCOJQHEZTQMRRHE3A . You are receiving this because you are subscribed to this thread.Message ID: @.***>

kwwall avatar Jan 25 '24 07:01 kwwall

This issue always turns out to be a local environmental issue. research what causes NoClassDefFound and solve your class path problem.

xeno6696 avatar Jan 25 '24 13:01 xeno6696

In my application, the functionality is to upload an excel file. After upgrading my application to spring framework 5.3.15, this functionality broke. My application is on JDK 8. I upgraded esapi library to the latest one but still getting the same thing. I checked my classpath, the esapi is there. It is giving me below error:

io.netty.handler.codec.DecoderException: java.lang.NoClassDefFoundError: org/owasp/esapi/errors/EncodingException
	at io.netty.handler.codec.ByteToMessageDecoder.callDecode(ByteToMessageDecoder.java:278) ~[netty-all-4.0.24.Final.jar:4.0.24.Final]
	at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:147) ~[netty-all-4.0.24.Final.jar:4.0.24.Final]

shahshikha630 avatar Jan 29 '24 06:01 shahshikha630

This is an issue with Netty. You need to ask them. They’re using ESAPI and whatever you’re doing is conflicting with their usage.

xeno6696 avatar Jan 29 '24 11:01 xeno6696

If you can construct a dummy application that reproduces this, I can help troubleshoot but otherwise I’d have to be present in your cube.

xeno6696 avatar Jan 29 '24 11:01 xeno6696

Might be worth pointing out that the netty 4.0.24-Final version is 10 years old and has no direct dependencies on ESAPI https://mvnrepository.com/artifact/io.netty/netty-all/4.0.24.Final https://repo1.maven.org/maven2/io/netty/netty-all/4.0.24.Final/netty-all-4.0.24.Final.pom

I've poked through several of the netty projects under io.netty for that version and I do not see any direct reference to ESAPI.

Based on the stack and the lack of a direct dependency, My guess is that there is an in-house decoder implementation that's been plugged into netty that uses ESAPI to support the process.

As @xeno6696 stated though, this appears to be environmental and difficult to diagnose from the current information.

jeremiahjstacey avatar Jan 29 '24 22:01 jeremiahjstacey

Indeed, that is largely why I asked for a test case to replicate this issue. We probably should have closed this long ago as being unable to reproduce and just didn't notice it since it was so old. (Sort of like me, but that's a story for another time. 😜)

-kevin

On Mon, Jan 29, 2024, 5:20 PM jeremiahjstacey @.***> wrote:

Might be worth pointing out that the netty 4.0.24-Final version is 10 years old and has no direct dependencies on ESAPI https://mvnrepository.com/artifact/io.netty/netty-all/4.0.24.Final

https://repo1.maven.org/maven2/io/netty/netty-all/4.0.24.Final/netty-all-4.0.24.Final.pom

I've poked through several of the netty projects under io.netty https://mvnrepository.com/artifact/io.netty for that version and I do not see any direct reference to ESAPI.

Based on the stack and the lack of a direct dependency, My guess is that there is an in-house decoder implementation that's been plugged into netty that uses ESAPI to support the process.

As @xeno6696 https://github.com/xeno6696 stated though, this appears to be environmental and difficult to diagnose from the current information.

— Reply to this email directly, view it on GitHub https://github.com/ESAPI/esapi-java-legacy/issues/227#issuecomment-1915676373, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAO6PGZRJIDOTBHA7PSQ7XLYRAOCDAVCNFSM4AXLF7U2U5DIOJSWCZC7NNSXTN2JONZXKZKDN5WW2ZLOOQ5TCOJRGU3DONRTG4ZQ . You are receiving this because you commented.Message ID: @.***>

kwwall avatar Jan 29 '24 23:01 kwwall