Switching from the curl backend to the native module broke the system config-management commit-archive source-address parameter for some people because although it was intended for source addresses, it also worked for ports and interfaces because it directly passed the value to curl's --interface option. This unexpected/undocumented feature disappeared with the update, so it may be a good idea to make separate, explicit parameters like source-port and source-interface.
- Difficulty level
- Unknown (require assessment)
- Why the issue appeared?
- Will be filled on close
- Is it a breaking change?
- Perfectly compatible
- Issue type
- Improvement (missing useful functionality)
|In progress||FEATURE REQUEST||None||T3355 Remove all remaining legacy Vyatta code|
|Resolved||FEATURE REQUEST||erkin||T3356 Script for remote file transfers|
|Wontfix||erkin||T4090 Source port and interface support for `commit-archive`|
I personally think the interface part is high-effort, low-gain since you can simply use the address of the interface to the same effect, whereas simply providing an interface will force it to decide which address to use on dual-stack systems. It needs to pick between AF_INET and AF_INET6 when creating the socket before setsockopt()ing SO_BINDTODEVICE; although I think we can get away with doing what socket.create_connection() does. Even then, only the SFTP portion of the code directly uses socket — everything else relies on higher level libraries that only expose address and port options. (Also, using a single parameter for both addresses and interfaces is a bad idea, in my opinion, because it's probably more useful to resolve an FQDN string to an address rather than assume all strings are interfaces. But otherwise, we'd need to find a way to resolve conflict between address and interface parameters.) All in all, I don't think the interface parameter is a good idea at all but we'll see.
The port thing is trivial but I'm not sure if anyone would ever use it.
If anyone actually wants support for source port parameter, feel free to reopen this, but the interface parameter is a no-go. In the meantime, rewriting vyatta-config-mgmt takes precedence.