<p>Bitcoin Core doesn't seem to have an option to specify the source port for outgoing connections, so you probably can't assume anything about the source port.</p>

<p>However, if possible, you could configure your router to look for outgoing connections with <em>destination</em> port 8333, which will probably be the port used by most peers.</p>

CC BY-SA 3.0
2015-10-20T16:49:03.810Z
2015-10-20T16:49:03.810Z
Nate Eldredge
<p>According to <a href="https://bitcoin.stackexchange.com/questions/7810/port-forwarding-plus-bitcoin/7811#7811">this</a> it's possible to have incoming connections to Bitcoin client by forwarding port 8333 on the router. I was wondering if there is some specific port range Bitcoin Core uses for making outgoing connections which could be used as a triggering rule? This way when the client is not running, port would be closed, plus it could be used by different machines behind the router without configuration changes (I know I could forward different ports to different machines and then change the incoming port in client configs)</p>

<p>EDIT: </p>

<p>@NateEldredge is right. </p>

<p>My current setup is as follow:</p>

<p><code>Rule name: Bitcoin
Triggered range: 8333-8333
Forwarded range: 8333-8333</code></p>

<p>If Bitcoin Core is running the port is open (according to <a href="http://www.canyouseeme.org/" rel="nofollow noreferrer">http://www.canyouseeme.org/</a>). If it's closed the port is closed too.</p>

<p>The only catch is it won't work if all 8 outgoing connections will use non default port but it shouldn't happen too often if ever.</p>

CC BY-SA 3.0
2015-10-20T16:13:15.547Z
You could look for outgoing connections with *destination* port 8333, if your router supports that.
Nate Eldredge
CC BY-SA 3.0
2015-10-20T16:26:59.740Z
@NateEldredge My router doesn't specify if it expects source or destination port as triggering port but it seems it's the second case and you are right. Please convert your comment to an answer so I can accept it.
MeTTeO
<connection><peer-discovery><port>
How to trigger port for Bitcoin client (e.g. 8333)
MeTTeO
# How to trigger port for Bitcoin client (e.g. 8333)

(Asked by: username_0 on 2015-10-20)

According to [this](https://bitcoin.stackexchange.com/questions/7810/port-forwarding-plus-bitcoin/7811#7811) it's possible to have incoming connections to Bitcoin client by forwarding port 8333 on the router. I was wondering if there is some specific port range Bitcoin Core uses for making outgoing connections which could be used as a triggering rule? This way when the client is not running, port would be closed, plus it could be used by different machines behind the router without configuration changes (I know I could forward different ports to different machines and then change the incoming port in client configs)

EDIT:

@NateEldredge is right.

My current setup is as follow:

`Rule name: Bitcoin
Triggered range: 8333-8333
Forwarded range: 8333-8333`

If Bitcoin Core is running the port is open (according to <http://www.canyouseeme.org/>). If it's closed the port is closed too.

The only catch is it won't work if all 8 outgoing connections will use non default port but it shouldn't happen too often if ever.

**Tags:** connection, peer-discovery, port

> **Comments:**
> **username_1**: You could look for outgoing connections with *destination* port 8333, if your router supports that.  
> **username_0**: @NateEldredge My router doesn't specify if it expects source or destination port as triggering port but it seems it's the second case and you are right. Please convert your comment to an answer so I can accept it.  

---

## 1 answers

### Answer by username_1 on 2015-10-20. Score: 3 | Accepted answer

Bitcoin Core doesn't seem to have an option to specify the source port for outgoing connections, so you probably can't assume anything about the source port.

However, if possible, you could configure your router to look for outgoing connections with *destination* port 8333, which will probably be the port used by most peers.


---

