CS/CE 218 Lecture -*-Outline-*- * file-attributes advert: ownership is an important concept in our culture. these commands allow you to control information that you own,... but in general a file has several properties... ** observing file attributes Q: what information about a file can you get from ls -l? ** file permissions philosophy of permissions on Unix: originally, permissions were very lax, encourages sharing the system is not designed to be highly secure (doesn't mean it's right to circumvent them...) permissions traditional area of study in OS, already well developed by the time of Unix design Q: What kinds of things *should* a file system allow you to say about how others can access your files? *** symbolic permissions (as printed by ls) Q: Is it useful to give someone execute but not read access to a program? What about vice versa? Q: How is searching a directory like executing a program? Q: What directories in ~leavens/classes/cs218/lectures can you read? Q: What directories in $PUB/study-guides can you read? Why must the symbolic arguments to chmod have permissions separated by commas without spaces? *** octal permissions (as accepted by chmod) r-x = 101 (binary) = 5 octal user, group, system each has a digit (left to right) why octal? Q: Is it sensible to have your directories with permission 777 containing files of permission 644? Is specifying permissions in octal better than giving them symbolically? Why? the setuserid bit allows someone else to have your identity for the duration of a program (e.g., to read one of your files in manner controlled by your program) ** changing file ownership what command changes the owner of a file? contrary to the book, it can be used, but only to give away ownership why wouldn't some systems allow you to give away ownership? (accounting)