Project

General

Profile

New adaptor using VOMS security context

Added by Scardaci Diego almost 12 years ago

Dear Guys,
we are devoloping a new job adaptor. This adaptor should use the VOMS security context.

In the adaptor we added the adaptor.properties file were we specified the class of the new job adaptor.

We added the adaptor in the lib folder of the jsaga installation.

When we tried to use it we got an error creating the JobService object. We used a session containg a VOMS security context. Below the error:

AuthenticationFailed: Security context class 'fr.in2p3.jsaga.adaptor.security.impl.UserPassSecurityCredential' not supported for protocol: condor

...
session = SessionFactory.createSession(false);
context = ContextFactory.createContext("VOMS");
context.setAttribute(Context.USERPROXY,"/tmp/x509up_100"); //put here your proxy path
session.addContext(context);
...
URL serviceURL = URLFactory.createURL("condor://lrt01.ct.infn.it");
service = JobFactory.createJobService(session, serviceURL);
...

Why JSAGA is looking for UserPassSecurityCredential if we are using the VOMS security context?

The steps we performed (add the adaptor.properties file inside the new adaptor and copy it in the jsaga lib folder) are enough to install the new adaptor in JSAGA?

Cheers,
Diego


Replies (5)

RE: New adaptor using VOMS security context - Added by Schwarz Lionel almost 12 years ago

Hi Diego,
The type (class) of credentials supported by the adaptor is defined in the method getSupportedSecurityCredentialClasses()

The class(es) returned by this method should match the class of the credential created by your context.

In your case, if you want to use the VOMS context, you have to set:

public Class[] getSupportedSecurityCredentialClasses() {
    return new Class[]{GSSCredentialSecurityCredential.class};
}

Is that the case?

RE: New adaptor using VOMS security context - Added by Scardaci Diego almost 12 years ago

Hi Lionel,
we already followed the way you suggested but, unexpectedly, we got the following exception:

AuthenticationFailed: Security context class 'fr.in2p3.jsaga.adaptor.security.impl.UserPassSecurityCredential' not supported for protocol: condor

Cheers,
Diego

RE: New adaptor using VOMS security context - Added by Scardaci Diego almost 12 years ago

Hi Lionel,
I found an error in my test code.

The problem disappeared when I fixed it.

Thanks for your support.

Cheers,
Diego

RE: New adaptor using VOMS security context - Added by Schwarz Lionel almost 12 years ago

Hi Diego,
Just in case this could be useful to others, could you please explain what you fixed in your code?
Thanks
Lio

RE: New adaptor using VOMS security context - Added by Scardaci Diego almost 12 years ago

Hi Lionel,
it was an error on my building environment. I included a library not more present in my classpath and I got a building error. It didn't depend on JSAGA.

Cheers,
Diego

Ps: Sorry for the delay in my answer :)

    (1-5/5)