TAILIEUCHUNG - Mastering Unix Shell Scripting phần 8

Hãy nghiên cứu các mã liên quan đến cả hai những thử nghiệm này trong các chức năng mọi khi, chúng ta có thể cải thiện bất kỳ kịch bản, và điều này cũng không ngoại lệ. Tôi đã liệt kê một số tùy chọn mà bạn có thể muốn xem xét. | 19 Monitoring and Auditing User Key Strokes In most large shops there is a need at least occasionally to monitor a user s actions. You may even want to audit the keystrokes of anyone with root access to the system or other administration type accounts such as oracle. Contractors on site can pose a particular security risk. Typically when a new application comes into the environment one or two contractors are on site for a period of time for installation troubleshooting and training personnel on the product. I always set up contractors in sudo see Chapter 14 for more details on sudo to access the new application account after I change the password. sudo tracks only the commands that were entered with a date time stamp. The detail of the command output from stdout and stderr does not get logged so you do not have a complete audit trail of exactly what happened if a problem arises. To get around this dilemma you can track a user s keystrokes from the time he or she accesses a user account until the time he or she exits the account if you have the space for the log file. This little feat is accomplished using the script command. The idea is to use sudo to kick off a shell script that starts a script session. When the script session is running all of the input and output on the terminal is captured in the log file. Of course if the user goes into some menus or programs the log file gets a little hard to read but we at least have an idea what happened. This monitoring is not done surreptitiously because I always want everyone to know that the monitoring is taking place. When a script session starts output from the script command informs the user that a session is running and gives the name of the session s log file. We can also set up mon 475 476 Chapter 19 itoring to take place from the time a user logs in until the user logs out. For this monitoring we do not need sudo but we do need to edit the HOME .profile or other login configuration file for the particular user. .

TỪ KHÓA LIÊN QUAN
TAILIEUCHUNG - Chia sẻ tài liệu không giới hạn
Địa chỉ : 444 Hoang Hoa Tham, Hanoi, Viet Nam
Website : tailieuchung.com
Email : tailieuchung20@gmail.com
Tailieuchung.com là thư viện tài liệu trực tuyến, nơi chia sẽ trao đổi hàng triệu tài liệu như luận văn đồ án, sách, giáo trình, đề thi.
Chúng tôi không chịu trách nhiệm liên quan đến các vấn đề bản quyền nội dung tài liệu được thành viên tự nguyện đăng tải lên, nếu phát hiện thấy tài liệu xấu hoặc tài liệu có bản quyền xin hãy email cho chúng tôi.
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.