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

Support security field at Operation level #434

Closed
smoya opened this issue Jan 5, 2022 · 5 comments
Closed

Support security field at Operation level #434

smoya opened this issue Jan 5, 2022 · 5 comments
Labels
enhancement New feature or request stale

Comments

@smoya
Copy link
Member

smoya commented Jan 5, 2022

Reason/Context

Part of asyncapi/spec#584.

Description

Support security field containing an array of SecurityRequirement at Operation level.

As this is a good candidate to be in v2.3.0 release, the PR should be created from and targeting 2022-01-release branch.

As far as I see, the change we need to do is to add a new function called security into the operation model. I think we can copy the one from the server found in https://github.com/asyncapi/parser-js/blob/2022-01-release/lib/models/server.js#L65-L72

@sekharbans-ebay
Copy link

Reason/Context

Part of asyncapi/spec#584.

Description

Support security field containing an array of SecurityRequirement at Operation level.

As this is a good candidate to be in v2.3.0 release, the PR should be created from and targeting 2022-01-release branch.

As far as I see, the change we need to do is to add a new function called security into the operation model. I think we can copy the one from the server found in https://github.com/asyncapi/parser-js/blob/2022-01-release/lib/models/server.js#L65-L72

Ack. Is simply copying the function ok? Would you in addition like ServerSecurityRequirement (server-security-requirement.js) renamed to 'SecurityRequirement' and reused for both server and operation - or a OperationSecurityRequirement equivalent created?

@magicmatatjahu
Copy link
Member

@sekharbans-ebay Hi!

Ack. Is simply copying the function ok? Would you in addition like ServerSecurityRequirement (server-security-requirement.js) renamed to 'SecurityRequirement' and reused for both server and operation - or a OperationSecurityRequirement equivalent created?

as I see server-security-requirement.js is empty class, so you can create equivalent the OperationSecurityRequirement class. If in the future something additional will appear in the ServerSecurityRequirement class, we will create a separate class that will be extended both in ServerSecurityRequirement and in OperationSecurityRequirement classes, don't worry :)

@sekharbans-ebay
Copy link

Thanks so much Lokesh!
Hi @smoya, @magicmatatjahu, @derberg - request review please

@github-actions
Copy link

This issue has been automatically marked as stale because it has not had recent activity 😴

It will be closed in 120 days if no further activity occurs. To unstale this issue, add a comment with a detailed explanation.

There can be many reasons why some specific issue has no activity. The most probable cause is lack of time, not lack of interest. AsyncAPI Initiative is a Linux Foundation project not owned by a single for-profit company. It is a community-driven initiative ruled under open governance model.

Let us figure out together how to push this issue forward. Connect with us through one of many communication channels we established here.

Thank you for your patience ❤️

@github-actions github-actions bot added the stale label May 15, 2022
@magicmatatjahu
Copy link
Member

Handled by #505

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request stale
Projects
None yet
Development

No branches or pull requests

3 participants