I may be wrong, but I have a vague recall of a tick box on one site (Ancestry?) where you could permit your dna to be used in that way? Also, I wonder if the use of DNA in crime solving varies by country?
I’m sure someone will have some knowledge of the subject, but if not there is bound to be plenty of information on the internet.