Problems to open port 162 (SNMP-TRAP)

Hi @fernandezjm, welcome to the forum.
This question is not really node-red specific and has been asked and answered many times (a quick search would reveal that).

So, you are right in that on linux, ports 1 - 1024 are privileged. The best way is to permit regular user/process to bind the port without sudo

Here are a few posts that might help...