Skip to content
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

Consider extending algorithms and cipher specs in MslConstants #144

Open
wmiaw opened this issue Feb 22, 2017 · 2 comments
Open

Consider extending algorithms and cipher specs in MslConstants #144

wmiaw opened this issue Feb 22, 2017 · 2 comments
Assignees

Comments

@wmiaw
Copy link
Contributor

wmiaw commented Feb 22, 2017

Similar to how the authentication and keyx schemes can be extended by the MSL configuration layer, doing the same for the compression and crypto enums currently held in MslConstants will probably also be useful.

MslUtils would need to allow compression algorithms to be installed as well (maybe similar to Base64). Perhaps a compression class should be created explicitly to support compression implementations instead of continuing to mix it into MslUtils.

@wmiaw wmiaw self-assigned this Feb 22, 2017
@quidryan
Copy link
Contributor

Base64 was done on a global static level. It would be preferred to have compression algorithms configurable via an object instead of an static, something along the lines of MslContext (an object we provide to MSL).

@wmiaw
Copy link
Contributor Author

wmiaw commented Mar 16, 2017

The approach I've used is to use injection (e.g. MslContext) when there is context that needs to be carried for the operation, whereas standalone instances are global statics like Base64 and many other language library APIs, or like logging solutions.

I think compression would fall into the category of a standalone instance that could be used anywhere independent of context. Do you have an example of how Base64 would have benefited from being pulled off of MslContext? Doing so would also require passing MslContext into even more functions than it currently is provided to.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants