You can take steps not to get banned such as using PSNPatch. This disables PSN access until you enable it with L3+R3+R2 from the XMB.
When you enable PSN access it disables things Sony can potentially detect such as CFW syscalls, it doesn't 100% make you safe, however it certainly helps.
You can't really blame Sony for banning people with CFW, many people use it to cheat online. However unlike Microsoft if you are careful they are a lot less likely to ban.