Cannot define a rule with a port range

Bug #1626849 reported by jean-christophe manciot
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Gufw
Invalid
Undecided
Unassigned

Bug Description

Ubuntu 16.04 4.4.0-38
Gufw 16.04.1

If I try to define a port range using a : as delimiter as explained by the help message which appears when hovering the mouse over the port field, it is impossible to save the rule: the add button remains greyed out: https://drive.google.com/file/d/0B6XxNd5c3zV_SmkxUjA1ZVJqdFU/view?usp=sharing
If I use a - instead, the rule can be saved but is rejected as error: "port 5900-5902 > ERROR: Bad port '5900-5902'"

There is no way out of this issue.

Revision history for this message
costales (costales) wrote :

Hi, if the add button is disabled is because you can't add that rule because a groups of parameters (try to remove the IP, change things until you see it enabled).
Best regards.

Changed in gui-ufw:
status: New → Invalid
Revision history for this message
jean-christophe manciot (manciot-jeanchristophe) wrote :

You can't be any deafer. Denying an issue won't make it go away.
Cf. attachment.

Revision history for this message
jean-christophe manciot (manciot-jeanchristophe) wrote :

It seems that the '-' delimiter has been recently implemented, so at least we have a solution now. But the help string is still incorrect.

Revision history for this message
Vadim Peretokin (vperetokin) wrote :

This is still an issue - as soon as you use a colon to specify a port range, the "Add" button gets disabled: http://imgur.com/oqDpBOs

Changed in gui-ufw:
status: Invalid → New
Revision history for this message
costales (costales) wrote :

Yes, this is a ufw limitation. Thanks for the feedback!

Changed in gui-ufw:
status: New → Invalid
Revision history for this message
jean-christophe manciot (manciot-jeanchristophe) wrote :

Deafness is the real issue here :-(

Revision history for this message
Ghostbird (ghostbird-) wrote :

The dash delimiter does not work, for the same real underlying problem, which is that UFW cannot handle port ranges for both TCP and UDP simultaneously.

The difference is that if you use the dash, the "Add" button is enabled, but pressing it only shows an error message in the status bar of the root Gufw window (rather obscure)

The solution:

As soon as you switch the protocol selection to either TCP or UDP the "Add" button is enabled, and the UI works.

The fix:

As soon as you type a dash/colon in the port range specification, the protocol specification should default to the next valid option TCP and the "Both" option should not be selectable.

Revision history for this message
Ghostbird (ghostbird-) wrote :

Of course a better fix would be that in this case the GUI is smart and creates two matching rules, one for TCP and one for UDP.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.