Coder Social home page Coder Social logo

Comments (10)

jfarcand avatar jfarcand commented on June 17, 2024

Sure, that's a good idea...I don't have the set up to test that, so I will need your help to confirm it's still work. Just curious, have you try changing code to see if that works? Merci.

from async-http-client.

fabienbancharel avatar fabienbancharel commented on June 17, 2024

As I am primary a Gatling user, I had just take a look at async-http-client yesterday. But yes, I should be able to change code and rebuild in few days.
By the way, the code of our working JUnit is inspired by the same source linked in the javadoc, so it should be compatible.
I will keep you informed.
Fabien.

from async-http-client.

fabienbancharel avatar fabienbancharel commented on June 17, 2024

Hello,
After few hours fighting with Wireshark, I can tell it wont be just a modification in SpnegoEngine.
In our setup, we have a multi domain controler, and I can see in normal scenario (kerberos using connected user) that Server Name and REALM are different.
But as soon I try to specify user principal in realm, I can see in Wireshark, that Server Name is the same as REALM, so I have a "no tgt found" error.

I try to force SPN (Server / Service Principal Name) in manager.createContext, but it has no effect.

Any idea of where I should look at ?
Thanks,
Fabien.

from async-http-client.

slandelle avatar slandelle commented on June 17, 2024

Gatling requests can take a authRealm or ntlmAuth with per user specific data.

from async-http-client.

dmak avatar dmak commented on June 17, 2024

I have the same challenge as described in initial post by @fabienbancharel. Currently org.asynchttpclient.spnego.SpnegoEngine uses the credentials of the user who is logged into the system (or who has issued kinit -f). Apparently I would like to use another user which is configured via login.config. More over, the granted ticket could get expired e.g. during the Gatling run, however there is no ability to refresh it. Another interesting case is when there are several functional users and SpnegoEngine wants to decide which of them to use for which domain.

This brings me to idea that there should be a away to replace SpnegoEngine implementation with some custom one. For example, SpnegoEngine#instance() method could use java.util.ServiceLoader helper to locate such custom implementation (this approach needs introduction of some interface with only method String generateToken(String server)).

from async-http-client.

slandelle avatar slandelle commented on June 17, 2024

The core issue with Spnego and other enterprisey auth schemes is that I have neither knowledge, needs, nor such environment at hand for testing :( So I'm afraid I won't be able to investigate and help on such topics.

from async-http-client.

dmak avatar dmak commented on June 17, 2024

I don't expect SpnegoEngine to implement all corner cases. I would like somehow to inject my implementation of token provider. That is possible by lookup using java.util.ServiceLoader, or having public setter SpnegoEngine#setInstance(...). This is very small effort: just define interface/API plus add public setter.

from async-http-client.

slandelle avatar slandelle commented on June 17, 2024

@dmak Then, if you know what you're doing, please send a PR :)

from async-http-client.

dmak avatar dmak commented on June 17, 2024

I agree, thanks for your comment. If I get some time to prepare PR, I'll certainly do it.

from async-http-client.

slandelle avatar slandelle commented on June 17, 2024

Would be great!

from async-http-client.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.