Allowguest=no && sip trunk fail

I have an interesting issue and I am not sure if it is my configuration or an issue with asterisk.

Below is a copy of my sip.conf….which works fine. The problem comes when I use the realtime table for my trunk….When ‘allowguest=no’, asterisk sends a fake rejection for device message, if the provider is scripted as below it is fine.

[general]
allowguest=no
srvlookup=no
udpbindaddr=0.0.0.0
tcpenable=yes
videosupport=yes
register =>username:password@proxy.voip.co.uk:5060/VOIP
rtcachefriends=yes
callcounter=yes
notifycid=yes
canreinvite = nonat
dtmfmode=auto
alwaysauthreject=yes

[VOIP]
type= peer
context=Trunks
host=single-01.proxy.voip.co.uk
name= username
defaultuser= username
secret= password
insecure=invite

In realtime table ast_sipfriends the fields are:

defaultuser : username
type : peer
name : VOIP
secret : password
context : Trunks
host : single-01.proxy.voip.co.uk
insecure : port,invite
registersip : yes
canreinvite : no

Any ideas?

Regards

Darren