You can camp where you like in Scotland within reason. Wild camping isn't outlawed like Ongaland. Usual caveats about consideration, not leaving a trace etc.
Might be a bit out of your way but A night at Caerlaverock is always great, though better in winter when the birds are back. Yoiunused...