What I observe is that with the second command, the app rule isn't added at all even though ufw said it was. Ie:
$ sudo ufw allow from 192.168.1.0/24 to 192.168.1.0/24 app OpenSSH
Rules updated
$ sudo ufw allow out from 192.168.1.0/24 to 192.168.1.0/24 app OpenSSH
Rules updated
$ sudo ufw status
Status: active
To Action From
-- ------ ----
192.168.1.0/24 OpenSSH ALLOW 192.168.1.0/24
What I observe is that with the second command, the app rule isn't added at all even though ufw said it was. Ie:
$ sudo ufw allow from 192.168.1.0/24 to 192.168.1.0/24 app OpenSSH
Rules updated
$ sudo ufw allow out from 192.168.1.0/24 to 192.168.1.0/24 app OpenSSH
Rules updated
$ sudo ufw status
Status: active
To Action From
-- ------ ----
192.168.1.0/24 OpenSSH ALLOW 192.168.1.0/24