I think they only uses commercial DNA database such as ancestry.com. Those are when you already agree to submit your DNA sample into a public domain, because not just you can access to such information.
Now whether or not they should be able to do that would be another issue, but the lawyer side of me would think that no one should ever give up their DNA sample voluntary.
It was studied in law school actually. If you want to know more, read this blog
https://sites.psu.edu/dhlaw/2010/05/30/dna-versus-fingerprints/
But in case you want a short answer, there were 2 reasons.
1.) The scare of misusing it. Since this is so identifiable, misusing it would be an issue
2.) Fear of manipulation of DNA, again, with such an unique identified (I think the comparison ratio is now down to a few billions to 1 chance), the fear of manipulation is quite out there.