storage: Avoid using `strlen` to count bytes

For PHP installations that have `mbstring.func_overload` enabled (set to a
value including `2`), the `strlen` function will be overloaded to use the
`mb_strlen` equivalent. Problematically, the internal encoding of `UTF-8`
will be applied to all file content, which will count UTF-8 characters
rather than bytes. This will cause the data to be saved correctly; however,
the `size` recorded in the %file table will be recorded incorrectly.

This patch allows the backend to report the size of the contents saved with
the request and provides a failsafe mechanism which will use the mbstring
equivalent if available, and the mbstring version is coded to use the `8bit`
as the encoding which will prevent reading characters.

References:
https://github.com/osTicket/osTicket-1.8/issues/552
storage: Support de-duplication in the mail channel (again)
Merge pull request #811 from greezybacon/issue/552

storage: Avoid using `strlen` to count bytes

Reviewed-By: Peter Rotich <peter@osticket.com>
Add reference UniversalClassLoader for plugins
tnef: Fix major issue iterating over attr streams

The original logic would read the count of attributes in the stream and then
read the first attribute in the constructor of TnefAttributeStreamReader.
Then the iterator interface would call ::rewind() before iterating to the
first item. rewind() set the @pos attribute to zero, which would cause the
attribute count (4-byte int) to be interpreted incorrectly as part of the
first attribute.

The new logic sets the position at 4 after rewind()ing, and does not read
the first attribute twice. It also properly detects the end of the attribute
stream by the number of attributes advertised as the first four bytes of the
stream (read into the @count attribute initially).
Merge pull request #825 from greezybacon/issue/tnef-bad-rewind

tnef: Fix major issue iterating over attar streams

Reviewed-By: Peter Rotich <peter@osticket.com>