http://www.perlmonks.org?node_id=27641


in reply to How does Perl handle strings with embedded NULLs?

There are places where embedded \000 characters will get you into trouble, but Perl can read and write such files without problems, since Perl uses counted strings.

Be warned though that passing such strings to anything like a system routine (like open() or -x), that take null-terminated strings as arguments, you will have problems or security holes.