Skip to content

Add config file access for pluginsย #236

@mjmartineau

Description

@mjmartineau

Is your feature request related to a problem? Please describe.
I'm working on the ndiffports plugin, and need a way to configure the 'n' (number of ports)

Describe the solution you'd like
It would be ideal to have an API exposed to plugins where they could query for config values that are stored in mptcpd.conf, without being able to modify the in-memory copy of the mptcpd core settings. Some wrappers around l_settings_*() calls is probably sufficient.

It's not critical to deny plugins access to any settings (they are in the same memory space as the core, after all), but it does make sense to make it easy to retrieve plugin settings and hard to accidentally corrupt core settings.

Describe alternatives you've considered
Creating a whole separate config parsing infrastructure using l_settings. This would duplicate a lot of core configuration handling code, and different plugins could diverge in how they handled config files.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions