Chinaunix首页 | 论坛 | 博客
  • 博客访问: 7387478
  • 博文数量: 1755
  • 博客积分: 18684
  • 博客等级: 上将
  • 技术积分: 16227
  • 用 户 组: 普通用户
  • 注册时间: 2010-06-02 10:28
个人简介

啥也没写

文章分类

全部博文(1755)

文章存档

2024年(1)

2023年(44)

2022年(39)

2021年(46)

2020年(43)

2019年(27)

2018年(44)

2017年(50)

2016年(47)

2015年(15)

2014年(21)

2013年(43)

2012年(143)

2011年(228)

2010年(263)

2009年(384)

2008年(246)

2007年(30)

2006年(38)

2005年(2)

2004年(1)

分类: BSD

2018-03-20 20:43:21

lshell lets you restrict a user's shell environment to limited sets of commands,choose to enable or disable any command over SSH (e.g. SCP, SFTP, rsync, etc.) log user's commands, implement timing restrictions, and more.

lshell能让你限制一个用户的shell环境,限制只能使用某些命令集,能有选择地允许/禁止用户通过ssh(或者scp,sftp,rsyn等)某些命令。并记录用户使用命令的情况,ssh登陆的时间限制。

lshell 在freebsd的ports tree :/usr/ports/shells/lshell

可以直接ports安装,或者到官方下载,手动配置安装:由于依赖python语言包,须安装好python,然后,

1.安装- On *BSD:
 # python setup.py install --no-compile --install-data=/usr/local/

 完成安装后。配置文件摆放:/usr/local/etc/lshell.conf

2.配置:

如果你只想用户查看以下命令"ls,echo,id,pwd“,修改配置文件的这部分:

allowed         : ['ls','echo','id','pwd']

3.修改用户的shell:

chsh -s /usr/local/bin/lshell x-fish

或者用vipw来修改。

阅读(1342) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~