Using Dialplan Variables in SIP.conf - possible?

In trying to clean up my long Sip.conf file I would like to get as much as possible into templates but am having trouble with setting a password to be a seed plus the extension through a variable
Below is what I tried which did not work in that the device would NOT register with a password of “myseedpassword12345”

Any ideas what I did wrong or is this just not possible?

Thanks
Bill

in Sip.conf…

;templates

test_template
type=friend
qualify=no
context=test
host=dynamic
canreinvite=no
Secret=myseedpassword+${EXTEN}

; then further down the file I create a device using the template
12345
; -------------secret is omitted since it is template but it should be myseedpassword12345 ----------

According my experience, it is much better to use MySQL tables for registering users.
What looks wrong for me, is using $EXTEN in sip.conf - I am not sure you can use this variable in sip.conf.

Never seen any evidence of variable substitution in a conf file. They’re pretty simple.

Like the first reply said, using Asterisk Dynamic Realtime is the way to go. You can then populate the passwords with a simple query.

I haven’t tried this, but I don’t believe you need the +.

in the extensions.conf it works like:
if VAR = 1234 then myseedpassword${VAR} = myseedpasword1234, but myseedpassword+${VAR} = myseedpassword+1234.