finaly I found a solution
so pfsense does not create correct pf rules on wan when there is another
wan connection
basicaly it does create those rules (from /tmp/rules.debug)
User-defined aliases follow
User-defined rules follow
pass in quick on $wan from any to any keep state label "USER_RULE"
pass in quick on $OPT1 reply-to (le2 y.y.y.y) from any to any keep state label "USER_RULE"
but the rule should be like this
User-defined rules follow
pass in quick on $wan reply-to (le0 x.x.x.x) from any to any keep state label "USER_RULE"
pass in quick on $OPT1 reply-to (le2 y.y.y.y) from any to any keep state label "USER_RULE"
so I had to make a change in the file /etc/inc/filter.inc
on the line 1581 from this
if(($rule['gateway'] == "") and ($ri != "") and ($rg != "") and (stristr($rule['interface'],"opt") == true)) {
to this
if(($rule['gateway'] == "") and ($ri != "") and ($rg != "")) {
so this way rules are created correctly