I just noticed that usernames on StackExchange sites aren't unique. For example, there's gilles and there's gilles. I assume that this behaviour is by design, but it seems to me that such a system would be open to shenanigans. Is there any mechanism in place to prevent malicious impersonation?
It's technically against the Terms of Service:
Under no circumstances will Subscriber use the Network or the Service to (a) send unsolicited e-mails, bulk mail, spam or other materials to users of the Network or any other individual, (b) harass, threaten, stalk or abuse any person or party, including other users of the Network, (c) create a false identity or to impersonate another person, or (d) knowingly post any false, inaccurate or incomplete material.
Unless somebody actually reports it, we're probably not going to notice/care, and it'd have to be an intentional attempt to confuse people: same name, gravatar, profile, etc.