List Info

Thread: Detached with peculiar URIs




Detached with peculiar URIs
user name
2007-08-06 21:14:02
Hi,

I'm having trouble on creating a Detached signature of resources referenced by files URI's and FTP URI's.
After looking the sources files I decided to create tests for these situations.
I had modified the tests on the following tests: org.apache.xml.security.test.signature.CreateSignatureTest ; and javax.xml.crypto.test.dsig.DetachedTest.
I'm sending these files for analysis.
The testDetachedFileURI of the CreateSignatureTest test case passes with the following modification on the org.apache.xml.security.utils.resolver.implementations.ResolverLocalFilesystem class:

On the method engineResolve, the uriNew is instantiated by this way:

         URI uriNew = null;
         if(BaseURI != null && !BaseURI.equals(";")) {
   ;          uriNew = new URI(new URI(BaseURI), uri.getNodeValue());
  ;      } else {
       ;     uriNew = new URI(uri.getNodeValue());
     ;   }

instead of this:

URI uriNew = new URI(new URI(BaseURI), uri.getNodeValue());

I cannot make the other tests to pass. Please, if anyone already done this kind of detached signatures, send me some example, maybe I'm doing something wrong.
Sorry about my english...

Thank you.
André Luiz Cardoso.
  
  
  
[1]

about | contact  Other archives ( Real Estate discussion Medical topics )