This has little to do with scripting so possibly in the wrong forum. However, I will provide as much help as I am able.
In the case of an eggdrop bot on an external linux shell the variable username should be set to your shell login name. This will then become the bot's identd on IRC. This is an extract from the .conf file for one of my bots (Colossus) which resides on a linux shell where my login username is terminus :-
# This setting defines the username the bot uses on IRC. This setting has
# no effect if an ident daemon is running on your bot's machine.
set username "terminus"
A network /whois gives the following response :-
Colossus is
terminus@server.go.thud.me.uk * Noone shall pass
For a windrop bot, the situation is somewhat different. Generally you would set the variable username to something you want to see as the bot's identd on IRC and ensure that winident1.2.tcl was loaded, as per the following extracts from the .conf file of my windrop bot (osmosis).
# This setting defines the username the bot uses on IRC. This setting has
# no effect if an ident daemon is running on your bot's machine.
set username "osmosis"
# Ident script for Windrop by FireEgl@EFnet <
FireEgl@LinuxFan.com>
# uses username value for ident name by default
# read the start of script for more documentation
# uncomment (remove # in front of line) next line to activate
source scripts/winident1.2.tcl
For some reason there is a Tcl statement in winident1.2.tcl which ultimately causes the identd to become the value of username plus 3 random characters. This is the statement :-
set ident(username) "$username***"
I removed the three asterisks (*) in this statement and restarted the windrop bot. This is now the output from a network /whois :-
osmosis is
osmosis@cpc2-oldh2-0-0-cust793.manc.cable.ntl.com * osmosis
So, in response, I suspect you are running a windrop bot and that winident1.2.tcl is giving you the three random characters. I have no idea why the author of winident1.2.tcl randomises the identd by default, unless perhaps it is to avoid the appearance of clones in the case of more than one windrop bot from the same ip address.