此程序可讓系統主控台的使用者不能暫停系統或中斷系統的電源。如果主控台使用者能夠拔除系統硬體,此軟體解決方案即無作用。
開始之前
您必須擔任 root 角色。如需更多資訊,請參閱Securing Users and Processes in Oracle Solaris 11.2 中的Using Your Assigned Administrative Rights。
% profiles -p "Console User" info name=Console User desc=Manage System as the Console User auths=solaris.system.shutdown,solaris.device.cdrw, solaris.smf.manage.vbiosd,solaris.smf.value.vbiosd profiles=Suspend To RAM,Suspend To Disk,Brightness,CPU Power Management, Network Autoconf User help=RtConsUser.html
如需相關說明,請參閱Securing Users and Processes in Oracle Solaris 11.2 中的How to Create a Rights Profile。
#CONSOLE_USER=Console User
若是多位使用者共用一個權限設定檔的情況,可在權限設定檔中設定這個值,作為具備可擴充性的解決方案。
# usermod -P shared-profile username
您也可以在 policy.conf 檔案中個別指派每個系統的設定檔。
# pfedit /etc/security/policy.conf... #PROFS_GRANTED=Basic Solaris User PROFS_GRANTED=shared-profile,Basic Solaris User
另請參閱
如需更多資訊,請參閱Securing Users and Processes in Oracle Solaris 11.2 中的policy.conf File,以及 policy.conf(4) 線上手冊和 usermod(1M) 線上手冊。