Comments (7)
Hello Nabil,
I currently don't have plans to implement any of the advanced mode features.
If anyone else wants to do it I would of course accept pull requests.
If you don't need fine grained authentication you could probably set up SSL with client side authentification to restrict the allowed clients.
from jawampa.
Hey,
I'd plan to work on this over the next week, at the very least client-side.
I'm basically thinking of implementing something like this:
WampClientBuilder()
.withUri('ws://acme.org:8080/ws')
.withAuthentication(WampCra.fromUserAndSecret('fooUser', 'barSecret')
.build();
The WampCra would be a ClientSideAuthentication, i.E. a class which can hold some authentication specific code (e.g. the user and the secret for the WampCra authentication, or the access token for the gitlab oauth authentication I have implemented at our GGS-fork for crossbar) with an abstract method "onChallenge". This should make it easy to implement all the authentications client-side.
I'll see how I add the router-side of the authentications. Probably similar, with a ServerSideAuthentication, so we can add some integration tests (i.E. if the FooAuthServerSide.onHello sends a certain challenge, FooAuthClientSide.onChallenge and FooAuchServerSide.onAuthenticate must work out well enough. It'll be somewhat tricky to get working, but it shouldn't be too hard).
Feel free to stop me, otherwise I'll throw pull requests around.
from jawampa.
Hi @Tetha, thanks for offering your contribution. You are welcome to implement features of the advanced mode like authentication. However what I want to see is that all implemented features are correctly working and are implemented in a clean and understandable fashion. Otherwise I would rather have only basic features instead of half-broken advanced features. If you feel you are up to the task - please continue.
What you should look out for is that ordering and the new states are correct. E.g. that the connected event is only dispatched after authentication is finished (if authentication is required by the user), that afaik the GOODBYE/ABORT message have slightly different semantics for the authentication case and that all messages and state transitions are handled in the correct thread.
I would propose that we finish the client side first and then discuss about server side?
I'm also not really sure if and how authentication and other advanced mode features should be handled with regards to the feature announcement stuff in the WAMP specification. Currently feature announcement and negotiation are not really used by the library. But it might be necessary to support it (and also probably to make it configurable) if more advanced mode features get implemented.
Just took a really short look about what you(?) are doing in https://github.com/GoodgameStudios/jawampa/commits/master. The first commits seem to be only partly about the authentication feature but do also change a bigger part of the structure of the library. That might of course make sense (haven't looked at it in detail) - but I feel that this should have been seperatly.
As this has however now already happened I think it makes most sense that you just continue incorporating your changes and after you have finished you can send some more explanations and I can take a look.
from jawampa.
Just took a really short look about what you(?) are doing in https://github.com/GoodgameStudios/jawampa/commits/master.
More me and my team. We're mostly working on splitting up the WampClient and WampRouter classes, since they are huge and very hard to understand. You can see the final iteration of this on the MessageHandler-Branch, where I'm working on introducing individual message handlers for the various roles in the WAMP protocol. These should end up small and focussed and allows us to easily extend the library for further messages and roles in the wamp protocol.
from jawampa.
@Tetha, any update on the WampCRA implementation?
from jawampa.
@rashedir: Please take a look at the goodgame studios fork. We're running two applications on that code base and so far, it's looking stable.
As a whole, we got a bit carried away with the refactoring, since we need a number of the advanced features and will probably add a few router-specific features as well. I'm currently considering my options there - @Matthias247 if you want to chime in, let me now. I'm open for discussion or decision from your side here.
from jawampa.
@Tetha: Yes the GoodGameStudio fork works pretty well as I have been using it for the past couple of weeks or so. Today I hit a snag when wanting to use some features currently supported by Matthias247 Jawampa. Currently the GoodGameStudio fork is about 10 commits behind its parent. So just wondering if there is a plan merging the CRA feature in to the main branch.
from jawampa.
Related Issues (20)
- State not changed to disconnected when connection is lost HOT 1
- Poloniex sequences HOT 13
- ApplicationError(wamp.error.invalid_uri, [], {}) even when URI is completely valid HOT 1
- How can I send a self-defined Java-class object(client) to fit a C++ class (server) by RPC HOT 1
- Web Connection works well on emulator but fail on real devices HOT 3
- Android < 5.0, TLSv1.2 and jawampa
- Problem with varargs in Publish method HOT 2
- Getting publication succeeded callback while network is disconnected HOT 2
- Subscription Id / Event History
- Convert to rxjava 2. Any plans?
- Subscription SocketTimeoutException
- Application throws java.lang.ClassNotFoundException: jdk.internal.misc.Unsafe exception during the creation of the client instance HOT 1
- Can we publish topic on session connection
- Android doesn't work HOT 1
- Correct way to make a client run
- wss secure websocket connection problem
- How to influence the json encoding/decoding? JsonViews possible? HOT 1
- Jawampa crashes when connections is closed. HOT 3
- Authentication in jawampa
- Cannot connect to server only on Android 7.0
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from jawampa.