[IMP] allow LAN printing and manage firewall rules - #5
Conversation
96d3665 to
e4a28dc
Compare
7fe4abb to
db20b47
Compare
a81f51d to
48423c9
Compare
5e66d1c to
cc4e546
Compare
b778456 to
897e8a2
Compare
jipr-odoo
left a comment
There was a problem hiding this comment.
Wouldn't it be better to request firewall permission only when the user explicitly enables "Allow Network Printing" instead of prompting on the first launch? This avoids showing an elevation/UAC prompt to users who may never use network printing and keeps the permission request contextual.
| cm.Data.FirewallPromptCompleted = prompt | ||
| cm.Data.FirewallAccepted = accepted | ||
| if prompt { | ||
| cm.Data.OldPort = cm.Data.Port |
There was a problem hiding this comment.
OldPort is updated whenever prompt is true, even if the firewall configuration was cancelled or failed. Would it make more sense to update OldPort only after the firewall rule has been successfully configured?
cd87c9e to
0f65f86
Compare
| @@ -0,0 +1,18 @@ | |||
| package config | |||
|
|
|||
| func (cm *Manager) UpdateFirewallPreference(accepted bool) error { | |||
There was a problem hiding this comment.
One more (rare) case that I think we should handle:
If the user enables network access and later changes the printer port, printing will stop working, but the UI will still indicate that network printing is allowed. That can be misleading.
I suggest resetting the "Allow Network Printing" flag to false whenever the port changes, so the user is prompted to enable firewall access again for the new port.
c08bf38 to
74fbc5e
Compare
3025502 to
5d6a528
Compare
- Allow devices on the local network to trigger printing - Configure firewall rules when LAN access is enabled
5d6a528 to
8e2ff11
Compare
davidmonnom
left a comment
There was a problem hiding this comment.
We'll not tweak the device firewall from the application, the user should do it by himself.
task-6306338