In addition to notes above about IIS & PHP reading network shares, here's one solution that works better for me.
in the management console I created a folder where my "read_dir" script runs. click on properties then select the security tab. here you can set the anonymous account to the standard IUSR_$computername% , BUT.. in this case I chose another account that I set up for reading my shares. (make sure login name and password match the credantials you set on the remote machin ;-))
I use this to read a dir and it's contents into a searchable database. and it works like a charm...