-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Security Schemes are too loose #221
Comments
I agree. What do you think should be mandatory for Consumers to support, within a reduced set of security schemes (#220)? I think I'm right in saying that WebThings currently only uses the On the Consumer side, WebThings Gateway essentially only supports the We'd definitely welcome a more achievable finite list of requirements to support for the Android app and wot-adapter Consumers. |
This is improved thanks to PR #305 . However, we still need to be specific about the use of single security schemes, like where to put username password in BasicAuth or which OAuth2 flow |
Schemes should be moved to the HTTP section |
@egekorkan can you please suggest a resolution for this issue. Recommendation could be based on node-wot and Webthings. |
Currently, node-wot implements the security schemes with the following flexibility:
|
There's a lot of nuance here though...
In conclusion I don't think it's enough for us to simply say that an implementation "supports" a particular security scheme. We need to be able to demonstrate that in a situation where a Consumer has no advanced knowledge of a given Thing:
Ideally we need to demonstrate this between different implementations from different vendors. My aim is to achieve this for WebThings Gateway as a Producer and WebThings Cloud as a Consumer by the end of April. It would be great if we could achieve it with node-wot (integrated into a Thing implementation) as a Producer and WebThings Cloud as a Consumer, or WebThings Gateway as a Producer and node-wot (integrated into a Consumer application) as a Consumer. Are there any other WoT Profile implementations we can use for testing? * WebThings Gateway currently uses JSON Web Tokens more like session tokens in that it stores all issued tokens on the server side and checks that they exist on each request, and tokens only expire if they are manually revoked. That isn't really how JWTs are meant to be used. As I understand it, the best practice for JWTs is that they should ideally have a very short expiration period (e.g. 10 minutes) and a refresh token should be issued with a long expiry date so that a client can request a new JWT when the current one expires. JWTs should not need to be stored on the server side, refresh tokens can have a longer expiry date and can be revoked if necessary (using either a whitelist or a blacklist). Currently WebThings Gateway does not issue refresh tokens at all. |
HTTP Profiles require the support of 4 security schemes. On top of that, there is no restriction on how to use them, i.e. where to put the credential information such as header, cookie or different OAuth2 flows. I think this makes it incredibly difficult to implement an HTTP Profile compliant consumer.
The text was updated successfully, but these errors were encountered: