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

[Access] DataProviders does not catch invalid arguments #7066

Open
Guitarheroua opened this issue Feb 19, 2025 · 1 comment · Fixed by #7081
Open

[Access] DataProviders does not catch invalid arguments #7066

Guitarheroua opened this issue Feb 19, 2025 · 1 comment · Fixed by #7081
Assignees
Labels
Bug Something isn't working S-Access

Comments

@Guitarheroua
Copy link
Contributor

🐞 Bug Report

The EventsDataPreovider does not notify clients about the invalid arguments. For example, if subscribe like the example below, the subscription is correctly created without any fail and error message:

{
    "action": "subscribe",
    "topic": "events",
    "arguments": {
        "heartbeat_interval": "10",
        "start_block_height": "103001001",
        "dummy": "dummy"
    }
}

Expected behaviour

It should be impossible to subscribe with invalid arguments and return an error in response.

@Guitarheroua Guitarheroua added Bug Something isn't working S-Access labels Feb 19, 2025
@illia-malachyn
Copy link
Contributor

illia-malachyn commented Feb 20, 2025

This problem shows up in every data provider. While parsing the arguments, providers look only for the needed fields, allowing users to pass additional fields that won't be validated. However, I'm unsure how bad it is and whether it's worth spending time on it.

@peterargue What do you think about it?

@illia-malachyn illia-malachyn self-assigned this Feb 20, 2025
@Guitarheroua Guitarheroua changed the title [Access] EventsDataProvider does not catch invalid arguments [Access] DataProviders does not catch invalid arguments Feb 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working S-Access
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants