# Are direct messages to a peer through libp2p encrypted?

**URL:** <https://discuss.ipfs.tech/t/are-direct-messages-to-a-peer-through-libp2p-encrypted/3394>\
**Category:** js-ipfs\
**Tags:** js-ipfs\
**Created:** [July 13, 2018, 3:35pm UTC](https://discuss.ipfs.tech/t/are-direct-messages-to-a-peer-through-libp2p-encrypted/3394 "2018-07-13T15:35:11Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![owenauch](https://avatars.discourse-cdn.com/v4/letter/o/898d66/32.png) [@owenauch](https://discuss.ipfs.tech/u/owenauch)\
**Post date:** [July 13, 2018, 3:35pm UTC](https://discuss.ipfs.tech/t/are-direct-messages-to-a-peer-through-libp2p-encrypted/3394/1 "2018-07-13T15:35:11Z")

</div>

When I use libp2p under the hood of a normal IPFS node, are my direct messages to other peers encrypted?

---

<div class="post-metadata">

**Author:** ![josselinchevalay](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ipfs.tech/josselinchevalay/32/3078_2.png) [@josselinchevalay](https://discuss.ipfs.tech/u/josselinchevalay)\
**Post date:** [July 16, 2018, 7:10am UTC](https://discuss.ipfs.tech/t/are-direct-messages-to-a-peer-through-libp2p-encrypted/3394/2 "2018-07-16T07:10:58Z")

</div>

you can see that [https://github.com/ipfs-shipyard/ipfs-pubsub-room](https://github.com/ipfs-shipyard/ipfs-pubsub-room)

---

<div class="post-metadata">

**Author:** ![ddahl](https://sea2.discourse-cdn.com/flex020/user_avatar/discuss.ipfs.tech/ddahl/32/2397_2.png) [@ddahl](https://discuss.ipfs.tech/u/ddahl)\
**Post date:** [October 11, 2018, 2:55pm UTC](https://discuss.ipfs.tech/t/are-direct-messages-to-a-peer-through-libp2p-encrypted/3394/3 "2018-10-11T14:55:17Z")

</div>

See: [https://github.com/libp2p/specs/blob/master/pnet/Private-Networks-PSK-V1.md#cryptography-of-private-networks](https://github.com/libp2p/specs/blob/master/pnet/Private-Networks-PSK-V1.md#cryptography-of-private-networks) - I believe all of the peer communication is transport encrypted
