Sometimes I think that shame comes from the people and things that are important to us, not so much from laws. We see people commit crimes who have no shame for them at all (which ironically, seems to defeat the purpose of the punishment). And from what I can tell, these emotions are from trying to... relate... to the people around you.
I guess some people don't care and are free that way, and there's those that care too much, in between are the rest of us going about our daily lives and just trying to get by