Change default realname to not advertise ZNC #1011

Open
opened 2026-10-05 04:58:25 +02:00 by adam · 1 comment
Owner

Right now ZNC will use the string "ZNC - http://znc.in" as realname if the user hasn't set one. Unfortunately this makes it difficult for other clients to figure out whether the realname is meaningful or not. Clients who want to display the realname need to resort to deny-lists to avoid showing the default realname.

A widely implemented practice is to set the realname to the nickname if the user hasn't set a custom one. This allows other clients to easily figure out the "no custom realname" case without resorting to hacks.

Would you accept a patch to implement this behavior in ZNC?

Apologies if this has already been discussed. I haven't found any past issue about it.

Ref https://github.com/znc/znc/issues/818 which AFAIK was the last time the realname was changed.

Right now ZNC will use the string "ZNC - http://znc.in" as realname if the user hasn't set one. Unfortunately this makes it difficult for other clients to figure out whether the realname is meaningful or not. Clients who want to display the realname need to resort to deny-lists to avoid showing the default realname. A widely implemented practice is to set the realname to the nickname if the user hasn't set a custom one. This allows other clients to easily figure out the "no custom realname" case without resorting to hacks. Would you accept a patch to implement this behavior in ZNC? Apologies if this has already been discussed. I haven't found any past issue about it. Ref https://github.com/znc/znc/issues/818 which AFAIK was the last time the realname was changed. <!-- github-sync-id:1199120209 -->
Author
Owner

If you're compiling ZNC from source, you can always change this line from m_sRealName(""), to m_sRealName(m_sCleanUsername + " using ZNC"), and this will set the default realname as something like PeGaSuS using ZNC.

If you want to use only the ZNC username, then set it to be m_sRealName(m_sCleanUsername).

This is a little hacky but can be used until someone submits a patch to ZNC or the team changes it.

Cheers

If you're compiling ZNC from source, you can always change [this line](https://github.com/znc/znc/blob/master/src/User.cpp#L68) from `m_sRealName(""),` to `m_sRealName(m_sCleanUsername + " using ZNC"),` and this will set the default realname as something like `PeGaSuS using ZNC`. If you want to use only the ZNC username, then set it to be `m_sRealName(m_sCleanUsername)`. This is a little hacky but can be used until someone submits a patch to ZNC or the team changes it. Cheers <!-- github-comment-id:1094336113 -->
Sign in to join this conversation.
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: adam/znc#1011