"oscam配置中文说明文档涵盖了oscam.USER、oscam.server和oscam.conf配置文件的设置方法,特别是oscam.user配置文件中的用户定义部分,包括账号、密码、主机名、测试通道、去重复级别、睡眠设置、CAID限制、AU设置以及服务分配等关键参数的详细解释。"
在OSCam的配置中,`oscam.user`文件是用户配置的核心,用于定义各个用户的访问权限和特性。以下是对各配置项的深入解析:
1. **[account]段**
- `user=name`: 指定账号名称,是必需的配置项。
- `pwd=password`: 设置账户的密码,同样也是必需的。
- `hostname=hostname`: 允许指定的主机名进行连接,可以用来限制用户只能从特定的设备访问。
2. **betatunnel**: 定义测试通道,用于实验性的解密服务。例如,`betatunnel=0100.0001:0200,0300.0004:0500`表示创建两个测试通道,将服务ID为0001的CAID0100转换为目标CAID0200,同理,服务ID为0004的CAID0300转换为目标CAID0500。
3. **uniq**: 去重复级别的设定,影响用户连接的管理。
- 0: 关闭去重功能。
- 1: 每个用户仅允许一个连接。
- 2: 不同IP地址的用户会被识别为不同用户。
- 3: 用户仅允许一个连接,优先提供给最新注册的用户。
- 4: 不同IP的用户被视为不同用户,但最新注册的用户仍可连接。
4. **sleep**: 非活动客户的睡眠时间,例如`sleep=5`表示5分钟后未活动的客户端将被断开连接。默认值为`none`,表示无限制。
5. **sleepsend**: 当设置为255时,对于OSCam客户端,将停止请求直到下一个活动;对于Camd3,会停止请求直到客户端重新启动。默认值为0,表示不停止请求。
6. **caid**: 限制可用的条件接收系统(CAID)。例如,`caid=0100&ffff:0200:0300&ff00`允许CAID0100与0200及0300的子集00FF和0000使用。
7. **au**: AU(Authentication Unit)设置,影响EMM(Entitlement Management Message)的发送方式。
- 读卡器标签:将EMM发送到指定的读卡器,可能引发安全问题。
- 1:自动将EMM发送到所有读卡器,同样存在安全风险。
8. **group**: 用户分配到的读卡器组,例如`group=readergroup1,readergroup2`,允许用户访问特定的读卡器。
9. **services**: 控制用户可以访问的服务,可以指定用户能访问的服务组,或排除某些服务。如`services=!servicegroup1,servicegroup2`表示禁止访问servicegroup1和servicegroup2。
10. **ident**: 用于指定特定CAID和识别符的组合,例如`ident=0100:0010;0200:0020`,用户仅能使用CAID0100的识别符0010或CAID0200的识别符0020。
通过以上参数的细致调整,可以根据需求实现对OSCam用户访问权限的精细控制,确保系统的安全性和稳定性。