# SOLVED : Newbie help - erc & authinfo not being read correctly?

**URL:** <https://forum.systemcrafters.net/t/solved-newbie-help-erc-authinfo-not-being-read-correctly/368>\
**Category:** Emacs\
**Created:** [February 28, 2024, 2:12am UTC](https://forum.systemcrafters.net/t/solved-newbie-help-erc-authinfo-not-being-read-correctly/368 "2024-02-28T02:12:48Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![moshh](https://avatars.discourse-cdn.com/v4/letter/m/e99b99/32.png) [@moshh](https://forum.systemcrafters.net/u/moshh)\
**Post date:** [February 28, 2024, 2:12am UTC](https://forum.systemcrafters.net/t/solved-newbie-help-erc-authinfo-not-being-read-correctly/368/1 "2024-02-28T02:12:49Z")

</div>

I am trying to setup ERC and have managed to get it to connect to libera without issue, not using my registered nick.

I do have my details stored in .authinfo.gpg, and that is being read correctly, because elfeed is working.

I have this line for libera  
`machine irc.libera.net login moshh password **** port 6697`  
and yet auth-source-debug reports

> auth-source-search: found 0 results (max 5000) matching (:user (“moshh”) :host (“irc.libera.chat”) :port (“irc”) :require (:secret) :max 5000)

I’ve received some help on the irc already and I apologise as I’ve forgotten peoples’ names. My function to connect is

```auto
  (defun erc-run-libera ()
    "Run ERC and connect to Libera"
    (interactive)
    (erc-tls :server "irc.libera.chat" :nick "moshh" :port "6697")
  )

```

any help would be greatly appreciated as I’m starting to tear my hair out (figuratively speaking)

UPDATE:  
Removing the `:port 6697` from the entries in my [config.org](http://config.org) got authinfo working.
