Code Monkey home page Code Monkey logo

openappfilter's Introduction

OAF(Open App Filter)

OAF is a parental control plug-in based on OpenWrt, which supports app filtering for games, videos, chats, downloads, such as Tiktok, Youtube, Telegram,etc.,and support self-defined app rules, you can lean more and download firmware by visiting www.openappfilter.com .

Preparation

  • Prepare a router that supports openwrt
    There are already many routers that support the openwrt system, you can choose a simple one for installation,See which devices support.
  • Install the openwrt system on your router
    The openwrt install tutorial can be found through the forum.

How to compile OAF

  1. Prepare OpenWrt source or SDK and compile successfully

general steps

   git clone https://github.com/openwrt/openwrt
   cd openwrt
   ./scripts/feeds update -a
   ./scripts/feeds install -a
   make defconfig
   make V=s
  1. Download OAF source code
    git clone https://github.com/destan19/OpenAppFilter.git package/OpenAppFilter
  2. Open the compile configuration
     echo "CONFIG_PACKAGE_luci-app-oaf=y" >>.config  
     make defconfig  
  1. Begin compile
  • Compile OAF separately
     make package/luci-app-oaf/compile V=s  
  • Compile the entire firmware
     make V=s  

How to install OAF

If you can't compile it yourself, you can install it directly into the released OpenWrt version

  1. Install an officially released version of openwrt
    Note that it must be the official release version,may cause failure if other versions are used, because OAF depend on the kernel version.
    It is best to download through the following official address
    https://downloads.openwrt.org/releases
  2. Download OAF zip file
    Find the corresponding OAF zip file on the release page and download it, note that the plug-in version and the system version must be consistent.
  3. Install OAF ipks
    Unzip thie OAF package and then install ipks in order
  • kmod-oaf
  • appfilter
  • luci-compat(if the luci version is 2.0, openwrt 19.07+)
  • luci-app-oaf
  • luci-i18n-oaf-zh-cn(Chinese Language Pack, optional)

Notice

If there is no version you need, you need to compile and generate it yourself, and I will release more architecture ipks later.

openappfilter's People

Contributors

destan19 avatar jjm2473 avatar jszmonkey avatar lwintermelon avatar realhurrison avatar sbwml avatar zaiyuyishiyoudu avatar zzhang1987 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

openappfilter's Issues

能否加入对哔哩哔哩视频的过滤?

小孩高三,疫情期间在家上网科。忍不住会偷偷看视频,这个插件很有用,封游戏、封视频。但是还是发现小孩可以通过哔哩哔哩看视频。大神能否百忙中加入哔哩哔哩视频过滤规则,谢谢!

过滤信息有误

系统版本:OpenWrt R20.3.8 / LuCI Master (git-20.062.50551-a6189c5)
硬件信息:K2P(MT7621AT)
内核版本:4.14.171
问题描述:开启过滤QQ飞车应用时,英雄联盟的小队语音是连不上的,取消过滤QQ飞车,小队语音就能连上

反馈一下,MT7621没有碰到过不断重启的问题。

测试使用oaf版本 :commit b9c8200
使用OPENWRT Chaos_Calmer 3.18.109
开启oaf过滤腾讯视频与斗鱼,测试过滤成功。设备一切正常。
测试使用设备newifi-d1,newifi-d2,hiwifi b70。

该版本在19.07.0-rc1中,当接通互联网时,只要有wifi客户端接入,立刻造成路由器自动重启。
或是中继一个接通了互联网的无线信号。在成功连接后,路由器立刻进入无限重启的死循环。

openwrt编译如何添加你的插件,我这边无法成功

HI
我尝试编译你的插件,结果失败了,步骤如下
1.我把你的插件git clone到了Openwrt/lean_test/lede/package/Extra-plugin/OpenAppFilter这个目录
2. ./scripts/feeds/update -a && ./scripts/feeds/install -a
3. 我在make menuconfig里面已经看到了,选择*。然后编译,安装到的机器,结果发现luci-app-oaf已经安装,但我在网络里面找不到应用过滤这个选项

我之后尝试了单独编译插件安装,出现以下错误
root@OpenWrt:~# cd /tmp
root@OpenWrt:/tmp# opkg install luci-app-oaf_1.0-1_all.ipk
Installing luci-app-oaf (1.0-1) to root...
Configuring luci-app-oaf.
uci: Entry not found
uci: Parse error (invalid command) at line 1, byte 0

无法加载访问记录

编译自 Mleaf 的 openwrt https://github.com/Mleaf/openwrt
在package 目录放了这个项目编译
image

http://192.168.1.1/cgi-bin/luci/admin/network/user_status?1581321549979
Failed to execute call dispatcher target for entry '/admin/network/user_status'.
The called action terminated with an exception:
/usr/lib/lua/luci/controller/appfilter.lua:56: module 'luci.tools.status' not found:
no field package.preload['luci.tools.status']
no file './luci/tools/status.lua'
no file '/usr/share/lua/luci/tools/status.lua'
no file '/usr/share/lua/luci/tools/status/init.lua'
no file '/usr/lib/lua/luci/tools/status.lua'
no file '/usr/lib/lua/luci/tools/status/init.lua'
no file './luci/tools/status.so'
no file '/usr/lib/lua/luci/tools/status.so'
no file '/usr/lib/lua/loadall.so'
no file './luci.so'
no file '/usr/lib/lua/luci.so'
no file '/usr/lib/lua/loadall.so'
stack traceback:
[C]: in function 'require'
/usr/lib/lua/luci/controller/appfilter.lua:56: in function </usr/lib/lua/luci/controller/appfilter.lua:55>
(tail call): ?

在kernel 5.4下编译失败

用的是原版openwrt master分支,此版本kernel已升级至5.4,

报错 ERROR: module '/home/runner/work/Actions-OpenWrt-Snapshot/Actions-OpenWrt-Snapshot/openwrt/build_dir/target-x86_64_musl/linux-x86_64/oaf-3.0/oaf.ko' is missing.

在kernel 4.19中一直编译正常.

内核日志里出现大量记录,可以屏蔽吗?

应该是appfilter产生的吧?不启动appfilter的话,也会反复产生,求解决,谢谢!

[ 9852.383899] __af_update_client_app_info 727 visit_app_num = 0
[ 9852.389775] [5] 192.168.50.100 visit 7001, time=1583002817 action=Accept, 0/32
[ 9852.397256] __af_update_client_app_info 727 visit_app_num = 0
[ 9852.403156] [5] 192.168.50.100 visit 7001, time=1583002817 action=Accept, 0/33
[ 9852.410626] __af_update_client_app_info 727 visit_app_num = 0
[ 9852.416508] [5] 192.168.50.100 visit 7001, time=1583002817 action=Accept, 0/34
[ 9852.424029] __af_update_client_app_info 727 visit_app_num = 0
[ 9852.429956] [5] 192.168.50.100 visit 7001, time=1583002817 action=Accept, 0/35
[ 9852.437506] __af_update_client_app_info 727 visit_app_num = 0
[ 9852.443458] [5] 192.168.50.100 visit 7001, time=1583002817 action=Accept, 0/36
[ 9882.383305] __af_update_client_app_info 727 visit_app_num = 0
[ 9882.389484] [5] 192.168.50.100 visit 7001, time=1583002847 action=Accept, 0/37
[ 9882.452149] __af_update_client_app_info 727 visit_app_num = 0
[ 9882.458319] [5] 192.168.50.100 visit 7001, time=1583002847 action=Accept, 0/38
[ 9882.466736] __af_update_client_app_info 727 visit_app_num = 0
[ 9882.472657] [5] 192.168.50.100 visit 7001, time=1583002847 action=Accept, 0/39
[ 9882.747383] __af_update_client_app_info 727 visit_app_num = 0
[ 9882.753566] [5] 192.168.50.100 visit 7001, time=1583002847 action=Accept, 0/40
[ 9883.034815] __af_update_client_app_info 727 visit_app_num = 0
[ 9883.040998] [5] 192.168.50.100 visit 7001, time=1583002848 action=Accept, 0/41
[ 9883.323861] __af_update_client_app_info 727 visit_app_num = 0
[ 9883.329853] [5] 192.168.50.100 visit 7001, time=1583002848 action=Accept, 0/42
[ 9883.612706] __af_update_client_app_info 727 visit_app_num = 0
[ 9883.621864] [5] 192.168.50.100 visit 7001, time=1583002848 action=Accept, 0/43
[ 9883.689156] __af_update_client_app_info 727 visit_app_num = 0
[ 9883.695301] [5] 192.168.50.100 visit 7001, time=1583002848 action=Accept, 0/44
[ 9907.161164] __af_update_client_app_info 727 visit_app_num = 0
[ 9907.167303] [0] 192.168.50.115 visit 1002, time=1583002872 action=Accept, 0/25
[ 9907.565985] __af_update_client_app_info 727 visit_app_num = 0
[ 9907.572188] [0] 192.168.50.115 visit 1002, time=1583002872 action=Accept, 0/26
[ 9908.346208] __af_update_client_app_info 727 visit_app_num = 0
[ 9908.352461] [0] 192.168.50.115 visit 1002, time=1583002873 action=Accept, 0/27
[ 9941.725422] __af_update_client_app_info 727 visit_app_num = 0
[ 9941.731671] [5] 192.168.50.100 visit 7001, time=1583002906 action=Accept, 0/45
[ 9942.765276] __af_update_client_app_info 727 visit_app_num = 0
[ 9942.771467] [5] 192.168.50.100 visit 7001, time=1583002907 action=Accept, 0/46
[ 9944.011373] __af_update_client_app_info 727 visit_app_num = 0
[ 9944.017578] [5] 192.168.50.100 visit 7001, time=1583002909 action=Accept, 0/47
[ 9961.681687] __af_update_client_app_info 727 visit_app_num = 0
[ 9961.687886] [5] 192.168.50.100 visit 7001, time=1583002926 action=Accept, 0/48
[ 9964.696128] __af_update_client_app_info 727 visit_app_num = 0
[ 9964.702286] [5] 192.168.50.100 visit 7001, time=1583002929 action=Accept, 0/49
[ 9969.701657] __af_update_client_app_info 727 visit_app_num = 0
[ 9969.707811] [5] 192.168.50.100 visit 7001, time=1583002934 action=Accept, 0/50
[ 9970.766724] __af_update_client_app_info 727 visit_app_num = 0
[ 9970.772872] [5] 192.168.50.100 visit 7001, time=1583002935 action=Accept, 0/51
[ 9971.060539] __af_update_client_app_info 727 visit_app_num = 0
[ 9971.066506] [5] 192.168.50.100 visit 7001, time=1583002936 action=Accept, 0/52

ipq4019请求适配

之前自己编译的在ipq4019平台上的竞斗云和acrh17遇到无限重启的问题 请求适配

特征库内容修改无法生效

特征库配置文件: /etc/appfilter/feature.cfg


修改此文件无法生效。经测试:

  1. 将苏宁易购的规则写入抖音(抖音规则已经删除)的一栏中,打开抖音过滤按钮无法过滤苏宁易购,但是打开苏宁易购过滤按钮可正常过滤。
  2. 在feature.cfg中增加新栏目会被添加进.class并在web上展出,但是其中的过滤规则无法生效。
  3. /etc/init.d/appfilter restart与重启均已尝试,以上两个问题均依旧存在。

结论:
feature.cfg文件的确被读取,但其只能用作添加.class以在web展示复选框,其中的过滤规则并未被读取,可能被存在了其他位置(重启无效说明不是存在内存),而非/etc/appfilter/feature.cfg。目前通过修改feature.cfg文件没有办法修改过滤规则。

只识别网络中少部分设备通信

监控页面可以看到2个设备的使用情况并在不停更新。但是其它手机或PC的流量好像并没有监控,在监控页面没有显示

建议添加内网MAC地址过滤控制功能

MAC地址过滤应用能精准控制设备防止错杀不必要过滤的应用设备
1、能让家长控制过滤应用防止孩子过渡游戏时间又可以对访客过滤应用
2、增加时间控制机制 人性化控制孩子应用使用时间

"最后访问时间"不正确

监控页面显示"最后访问时间"为:1970/01/01 08:18:05
实际时间(路由器时间,拷贝有时延) : Fri Apr 10 02:04:21 2020

无法过滤抖音短视频

我用的这个固件,添加后编译成功也运行起来了。
但是我发现抖音并没有被过滤,大部分头像和评论图片以及视频预览图都屏蔽了,但是视频一个都没有屏蔽,希望更新一下视频过滤规则。

无法过滤抖音直播

求大大抓个特征,视频头像均可以屏蔽但是直播没办法过滤。直播按钮在主页面的右上角。

/usr/lib/lua/luci/model/cbi/appfilter/appfilter.lua:111: attempt to index local 'device' (a nil value)

最近更新的版本在openwrt 19.07下出错
/usr/lib/lua/luci/model/cbi/appfilter/appfilter.lua:111: attempt to index local 'device' (a nil value)
stack traceback:
/usr/lib/lua/luci/model/cbi/appfilter/appfilter.lua:111: in function 'func'
/usr/lib/lua/luci/cbi.lua:66: in function 'load'
/usr/lib/lua/luci/dispatcher.lua:1335: in function '_cbi'
/usr/lib/lua/luci/dispatcher.lua:1018: in function 'dispatch'
/usr/lib/lua/luci/dispatcher.lua:478: in function </usr/lib/lua/luci/dispatcher.lua:477>

误报

云视通监控会误报为荒野行动,导致过滤云视通无法联网在线,看记录也是访问荒野行动,关闭荒野行动,云视通立马在线。

冲突软件太多

广告过滤和出国上网,这些都是常常要用到的,不可能不要啊,
期待更新,

QQ只是用TCP协议吗?

我看QQ的过滤规则是这样的呢,都是TCP的,我看我的QQ登录用的是UDP协议
QQ:[tcp;;;;;00:02|-1:03,tcp;;;;;02:02|-1:03,tcp;;14000;;;,tcp;;8080;;;00:ca|01:3c,tcp;;;;;00:00|01:00|02:00|03:15]

QQ应该是开始会尝试用UDP登录,如果登录不成功再切换到TCP

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.