Changeset 37284b2


Ignore:
Timestamp:
Apr 4, 2014 11:44:15 AM (2 weeks ago)
Author:
Kris Moore <kris@…>
Branches:
master
Children:
d6bf18f
Parents:
9f3ee49
Message:

Add exec=off / suid=off to /var/{tmp/log} and /tmp by default.

Also add options to disk editor to enable / disable suid / exec on
datasets

Location:
src-qt4/pc-installgui
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • src-qt4/pc-installgui/installer.cpp

    r8a5b8ec r37284b2  
    281281    // Add the main zfs pool with standard partitions 
    282282    fsType= "ZFS"; 
    283     fileSystem << targetDisk << targetSlice << "/(compress=lz4),/tmp(compress=lz4),/usr(canmount=off),/usr/home(compress=lz4),/usr/jails(compress=lz4),/usr/obj(compress=lz4),/usr/pbi(compress=lz4),/usr/ports(compress=lz4),/usr/ports/distfiles(compress=off),/usr/src(compress=lz4),/var(canmount=off),/var/audit(compress=lz4),/var/log(compress=lz4),/var/tmp(compress=lz4)" << fsType << tmp.setNum(totalSize) << "" << ""; 
     283    fileSystem << targetDisk << targetSlice << "/(compress=lz4),/tmp(compress=lz4|exec=off|suid=off),/usr(canmount=off),/usr/home(compress=lz4),/usr/jails(compress=lz4),/usr/obj(compress=lz4),/usr/pbi(compress=lz4),/usr/ports(compress=lz4),/usr/ports/distfiles(compress=off),/usr/src(compress=lz4),/var(canmount=off),/var/audit(compress=lz4),/var/log(compress=lz4|exec=off|suid=off),/var/tmp(compress=lz4|exec=off|suid=off)" << fsType << tmp.setNum(totalSize) << "" << ""; 
    284284    sysFinalDiskLayout << fileSystem; 
    285285    fileSystem.clear(); 
  • src-qt4/pc-installgui/wizardDisk.cpp

    r8a5b8ec r37284b2  
    426426 
    427427     // This lets the user do nifty stuff like a mirror/raid post-install with a single zpool command 
    428     fileSystem << targetDisk << targetSlice << "/" + rootOpts + ",/tmp(compress=lz4),/usr(canmount=off),/usr/home(compress=lz4),/usr/jails(compress=lz4),/usr/obj(compress=lz4),/usr/pbi(compress=lz4),/usr/ports(compress=lz4),/usr/ports/distfiles(compress=lz4),/usr/src(compress=lz4),/var(canmount=off),/var/audit(compress=lz4),/var/log(compress=lz4),/var/tmp(compress=lz4)" << fsType << tmp.setNum(totalSize) << "" << tmpPass; 
     428    fileSystem << targetDisk << targetSlice << "/" + rootOpts + ",/tmp(compress=lz4|suid=off|exec=off),/usr(canmount=off),/usr/home(compress=lz4),/usr/jails(compress=lz4),/usr/obj(compress=lz4),/usr/pbi(compress=lz4),/usr/ports(compress=lz4),/usr/ports/distfiles(compress=lz4),/usr/src(compress=lz4),/var(canmount=off),/var/audit(compress=lz4),/var/log(compress=lz4|exec=off|suid=off),/var/tmp(compress=lz4|exec=off|suid=off)" << fsType << tmp.setNum(totalSize) << "" << tmpPass; 
    429429    sysFinalDiskLayout << fileSystem; 
    430430    fileSystem.clear(); 
     
    708708  popupNE->addAction( "off", this, SLOT(slotZEXOFF())); 
    709709 
     710  // Add suid sub-menu 
     711  popupNE = popup->addMenu("suid"); 
     712  popupNE->addAction( "on", this, SLOT(slotZSUIDON())); 
     713  popupNE->addAction( "off", this, SLOT(slotZSUIDOFF())); 
     714 
    710715  popup->exec( QCursor::pos() ); 
    711716 
     
    810815{ 
    811816  toggleZFSOpt(QString("exec=on")); 
     817} 
     818 
     819void wizardDisk::slotZSUIDOFF() 
     820{ 
     821  toggleZFSOpt(QString("suid=off")); 
     822} 
     823 
     824void wizardDisk::slotZSUIDON() 
     825{ 
     826  toggleZFSOpt(QString("suid=on")); 
    812827} 
    813828 
  • src-qt4/pc-installgui/wizardDisk.h

    r07eb74c r37284b2  
    6161    void slotZEXON(); 
    6262    void slotZEXOFF(); 
     63    void slotZSUIDON(); 
     64    void slotZSUIDOFF(); 
    6365 
    6466private: 
Note: See TracChangeset for help on using the changeset viewer.