Possible explanation: In nature, animals are vulnerable when they are defecating, so pack animals often rely on others to watch their back while doing their business. Cats and dogs retain the instinct and hence, invade your privacy when you are doing your business and stare at you when they are doing theirs.