Giter Club home page Giter Club logo

sudodev's Introduction

描述

English

sudodev 是一个通过指定某个设备(U盘)后让你使用sudo而不需要密码的程序

看到这里后,用C++写了一遍 初学C++算是练习吧

影响的系统文件:

  • /etc/sudoers
  • /etc/group

如何工作

  • 这个程序会创建一个groupsdevuser
  • 你必须将自己加入sudoers通过visudo或者其他方式,并且,你必须是sdevusers的成员
  • 在你的/etc/sudoers文件中有以下一行代码
#includedir /etc/sudoers.d

如果没有,程序会试图添加进去,但是这不能保证你可以不用输入密码

有了以上条件,你就可以使用sdev_ctladddel选项来添加或删除你的外部设备,一旦sdevd监测到了你添加的设备,你就可以使用sudo而不需要输入密码了

建议

  • 使用前请备份影响的系统文件
  • 你可以将sdevd写入系统的启动脚本,具体方法参见你所用发行版的wiki,也可以参考这里

致谢

非常感谢学姐@Arondight做了这个很棒的东西

COPYRIGHT

Copyright © 2015 AbbyCin([email protected])

LICENSE

GNU General Public License GPL

sudodev's People

Contributors

abbycin avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.