Not having the original file to test with, I can only go by what you say. In your FOR loop, you go through each element in the array which you then Split() into yet another array on a full colon ':'. If the $line does not contain a colon, there is no $cPerms[1], hence 'out of bounds'.

Walk through in debug and query the vars to see what you are getting.
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.