Why inputting 'nul' in windows cmd gives a certain error-message

4

Whenever I type 'nul' into the command prompt (whichever directory Im currently in) I get a "Windows Security"-popup saying this:

    Windows Security

    Your Internet Security settings prevented one or more files 
    from being opened.

    $uri$\nul

I know why opening nul would be an.. interesting concept (fyi: it´s impossible). But why is the box saying "Your internet security settings[..]"? The 'nul'-file has nothing to do with my internet security settings, as far as I know, at least.

EDIT: Also, why is the command prompt recognizing 'nul' as some sort of command? Shouldnt it error with (as it does with most other reserved keywords):

    ´X´ is not recognized as an internal or external command, operable program
    or batch file.

Marcus Hansson

Posted 2011-08-01T08:56:48.760

Reputation: 491

Answers

2

nul is being recognized as a command because it exists as far as standard file I/O functions are concerned, just like /dev/null exists. (Opening nul is possible, but the end result would likely be as if you opened a zero-length file.)

As for the notification – Windows uses different security levels called "zones" (local computer, Internet, intranet, trusted, restricted). When you download a file, most browsers mark it as coming from the "Internet" zone, so a confirmation is displayed even though the file is now on your disk. It's possible that nul for some reason belongs to the "Restricted" zone now. (Zones were initially limited to website contents in Internet Explorer, only later expanded to cover downloaded files and other things.)

user1686

Posted 2011-08-01T08:56:48.760

Reputation: 283 655

So the security-zones actually exist outside of Internet Explorer? That could explain alot! Thanks for your answer! – Marcus Hansson – 2011-08-01T13:06:36.527