Hidden file

In computing, a hidden directory or hidden file is a directory (folder) or file which file system utilities do not display by default. They are commonly used for storing user preferences or preserving the state of a utility and are frequently created implicitly by using various utilities. Usually the intent is to not "clutter" the display of the contents of a directory with files the user did not create.[1][2][3]

Unix and Unix-like environments

In Unix-like operating systems any file or directory that starts with a period or full stop character (for example, /home/user/.config) is to be treated as hidden – that is, the ls command does not display them unless the -a flag (ls -a) is used.

In most command line shells, wildcards will not match dotfiles unless the wildcard itself starts with an explicit . (although this is sometimes configurable; for example, the dotglob option in bash).

The notion that filenames preceded by a . should be hidden is the result of a software bug in the early days of Unix. When the special . and .. directory entries were added to the filesystem, it was decided that the ls command should not display them. However, the program was mistakenly written to exclude any file whose name started with a . character, rather than the exact names . or ...[4]

GNOME

In the GNOME desktop environment (as well as all programs written using GLib[5]), filenames listed in a file named .hidden in each directory are also excluded from display. In GNOME's file manager, the keyboard shortcut Ctrl+H enables the display of both kinds of hidden files.

Mac OS X

In addition to the "dotfile" behaviour, files with the "Invisible" attribute are hidden in Finder, although not in ls. The "Invisible" attribute can be set or cleared using the SetFile command; for example, invoking SetFile -a V jimbo will hide the file "jimbo". Starting in Mac OS X Snow Leopard, the chflags command can also be used; for example, chflags hidden jimbo will hide the file "jimbo".

DOS and MS Windows

In MS-DOS and other DOS systems, file directory entries include a Hidden File attribute which is manipulated using attrib command. Use the command line command dir /ah to display the files with the attribute of hidden.

Under Windows Explorer, content of a directory can be hidden just by appending a pre-defined CLSID [6] to the end of the folder name. The directory is still visible, but its content becomes one of the Windows Special Folders.[7] However, the real content of this directory can still be seen using CLI command dir.

Abuse

Malicious programs can use this functionality to hide their presence.

References

External links

  • Bellevue Linux Users Group: Hidden files in Unix-like operating systems (via archive.org)
  • Computer Hope: command
This article was sourced from Creative Commons Attribution-ShareAlike License; additional terms may apply. World Heritage Encyclopedia content is assembled from numerous content providers, Open Access Publishing, and in compliance with The Fair Access to Science and Technology Research Act (FASTR), Wikimedia Foundation, Inc., Public Library of Science, The Encyclopedia of Life, Open Book Publishers (OBP), PubMed, U.S. National Library of Medicine, National Center for Biotechnology Information, U.S. National Library of Medicine, National Institutes of Health (NIH), U.S. Department of Health & Human Services, and USA.gov, which sources content from all federal, state, local, tribal, and territorial government publication portals (.gov, .mil, .edu). Funding for USA.gov and content contributors is made possible from the U.S. Congress, E-Government Act of 2002.
 
Crowd sourced content that is contributed to World Heritage Encyclopedia is peer reviewed and edited by our editorial staff to ensure quality scholarly research articles.
 
By using this site, you agree to the Terms of Use and Privacy Policy. World Heritage Encyclopedia™ is a registered trademark of the World Public Library Association, a non-profit organization.