diff --git a/CONTRIBUTED.md b/CONTRIBUTED.md index 7527b02139..234f60766a 100644 --- a/CONTRIBUTED.md +++ b/CONTRIBUTED.md @@ -44,7 +44,8 @@ luci-app-jd-dailybonus source: [jerrykuku/luci-app-jd-dailybonus](https://github luci-app-oled source: [NateLol/luci-app-oled](https://github.com/NateLol/luci-app-oled).
luci-app-beardropper source: [NateLol/natelol](https://github.com/NateLol/natelol).
luci-app-vssr source: [jerrykuku/luci-app-vssr](https://github.com/jerrykuku/luci-app-vssr).
-luci-theme-edge source: [garypang13/luci-theme-edge](https://github.com/garypang13/luci-theme-edge). +luci-theme-edge source: [garypang13/luci-theme-edge](https://github.com/garypang13/luci-theme-edge).
+luci-proto-minieap source: [ysc3839/luci-proto-minieap](https://github.com/ysc3839/luci-proto-minieap). ## License ### Depend on their own License. diff --git a/package/ctcgfw/luci-proto-minieap/Makefile b/package/ctcgfw/luci-proto-minieap/Makefile new file mode 100644 index 0000000000..f1e0a1f1da --- /dev/null +++ b/package/ctcgfw/luci-proto-minieap/Makefile @@ -0,0 +1,16 @@ +include $(TOPDIR)/rules.mk + +PKG_NAME:=luci-proto-minieap +PKG_VERSION:=2.1 +PKG_RELEASE:=1 +PKG_MAINTAINER:=Richard Yu +PKG_LICENSE:=GPLv3 +PKG_LICENSE_FILES:=LICENSE + +LUCI_TITLE:=LuCI support for MiniEAP +LUCI_DEPENDS:= +LUCI_PKGARCH:=all + +include $(TOPDIR)/feeds/luci/luci.mk + +# call BuildPackage - OpenWrt buildroot signature diff --git a/package/ctcgfw/luci-proto-minieap/htdocs/luci-static/resources/protocol/minieap.js b/package/ctcgfw/luci-proto-minieap/htdocs/luci-static/resources/protocol/minieap.js new file mode 100644 index 0000000000..78aeeee7a5 --- /dev/null +++ b/package/ctcgfw/luci-proto-minieap/htdocs/luci-static/resources/protocol/minieap.js @@ -0,0 +1,102 @@ +'use strict'; +'require form'; +'require network'; + +network.registerErrorCode('MISSING_USER_OR_PASS', _('Missing username or password')); +network.registerErrorCode('EXIT_FAILURE', _('Program exited with failure. See system log for more information.')); + +return network.registerProtocol('minieap', { + getI18n: function() { + return _('MiniEAP client'); + }, + + getOpkgPackage: function() { + return 'minieap'; + }, + + renderFormOptions: function(s) { + var dev = this.getL2Device() || this.getDevice(), o; + + // remove firewall tab, add rjv3 tab + try { + s.tab('rjv3', _('RJv3 Plugin Settings'), null); + s.tab_names.splice(2, 0, s.tab_names.pop()); + } catch (e) {} + + o = s.taboption('general', form.Value, 'username', _('Username')); + + o = s.taboption('general', form.Value, 'password', _('Password')); + o.password = true; + + o = s.taboption('general', form.DynamicList, 'module', _('Packet plugins')); + o.rmempty = true; + o.datatype = 'list(string)'; + o.value('rjv3', 'rjv3'); + o.value('printer', 'printer'); + + o = s.taboption('advanced', form.Value, 'max_fail', _('Max fail')); + o.datatype = 'uinteger'; + o.placeholder = '3'; + + o = s.taboption('advanced', form.Value, 'max_retries', _('Max retries')); + o.datatype = 'uinteger'; + o.placeholder = '3'; + + o = s.taboption('advanced', form.Flag, 'no_auto_reauth', _('No auto reauth')); + + o = s.taboption('advanced', form.Value, 'wait_after_fail', _('Wait after fail')); + o.datatype = 'uinteger'; + o.placeholder = '30'; + + o = s.taboption('advanced', form.Value, 'stage_timeout', _('Stage timeout')); + o.datatype = 'uinteger'; + o.placeholder = '5'; + + o = s.taboption('advanced', form.Value, 'auth_round', _('Auth Round')); + o.datatype = 'uinteger'; + o.placeholder = '1'; + + o = s.taboption('advanced', form.Value, 'log_file', _('Log file')); + o.placeholder = '/var/log/minieap.log'; + + // rjv3 plugin + o = s.taboption('rjv3', form.Value, 'heartbeat', _('Heartbeat interval')); + o.datatype = 'uinteger'; + o.placeholder = '60'; + + o = s.taboption('rjv3', form.ListValue, 'eap_bcast_addr', _('EAP broadcast address')); + o.value(0, _('Standard')); // BROADCAST_STANDARD + o.value(1, _('RJ private')); // BROADCAST_RJ + // o.value(2, _('BROADCAST_CER')); // BROADCAST_CER + + o = s.taboption('rjv3', form.ListValue, 'dhcp_type', _('DHCP type')); + o.value(0, _('Disabled')); // DHCP_NONE + o.value(1, _('Double Auth')); // DHCP_DOUBLE_AUTH + o.value(2, _('DHCP After Auth')); // DHCP_AFTER_AUTH + o.value(3, _('DHCP Before Auth')); // DHCP_BEFORE_AUTH + + o = s.taboption('rjv3', form.DynamicList, 'rj_option', _('RJ option')); + o.rmempty = true; + o.placeholder = ':[:r]'; + + o = s.taboption('rjv3', form.Value, 'service', _('Service name')); + o.placeholder = 'internet'; + + o = s.taboption('rjv3', form.Value, 'version_str', _('Version string')); + o.placeholder = 'RG-SU For Linux V1.0'; + + o = s.taboption('rjv3', form.Value, 'dhcp_script', _('DHCP script')); + + o = s.taboption('rjv3', form.Value, 'fake_dns1', _('Fake DNS 1')); + o.datatype = 'ip4addr'; + + o = s.taboption('rjv3', form.Value, 'fake_dns2', _('Fake DNS 2')); + o.datatype = 'ip4addr'; + + o = s.taboption('rjv3', form.Value, 'fake_serial', _('Fake HDD serial')); + + o = s.taboption('rjv3', form.Value, 'max_dhcp_count', _('Max DHCP count')); + o.datatype = 'uinteger'; + o.placeholder = '3'; + } +}); diff --git a/package/ctcgfw/luci-proto-minieap/po/templates/minieap.pot b/package/ctcgfw/luci-proto-minieap/po/templates/minieap.pot new file mode 100644 index 0000000000..028bd27f0a --- /dev/null +++ b/package/ctcgfw/luci-proto-minieap/po/templates/minieap.pot @@ -0,0 +1,95 @@ +msgid "" +msgstr "Content-Type: text/plain; charset=UTF-8" + +msgid "Auth Round" +msgstr "" + +msgid "DHCP After Auth" +msgstr "" + +msgid "DHCP Before Auth" +msgstr "" + +msgid "DHCP script" +msgstr "" + +msgid "DHCP type" +msgstr "" + +msgid "Disabled" +msgstr "" + +msgid "Double Auth" +msgstr "" + +msgid "EAP broadcast address" +msgstr "" + +msgid "Fake DNS 1" +msgstr "" + +msgid "Fake DNS 2" +msgstr "" + +msgid "Fake HDD serial" +msgstr "" + +msgid "Heartbeat interval" +msgstr "" + +msgid "Log file" +msgstr "" + +msgid "Max DHCP count" +msgstr "" + +msgid "Max fail" +msgstr "" + +msgid "Max retries" +msgstr "" + +msgid "MiniEAP client" +msgstr "" + +msgid "Missing username or password" +msgstr "" + +msgid "No auto reauth" +msgstr "" + +msgid "Packet plugins" +msgstr "" + +msgid "Password" +msgstr "" + +msgid "Program exited with failure. See system log for more information." +msgstr "" + +msgid "RJ option" +msgstr "" + +msgid "RJ private" +msgstr "" + +msgid "RJv3 Plugin Settings" +msgstr "" + +msgid "Service name" +msgstr "" + +msgid "Stage timeout" +msgstr "" + +msgid "Standard" +msgstr "" + +msgid "Username" +msgstr "" + +msgid "Version string" +msgstr "" + +msgid "Wait after fail" +msgstr "" diff --git a/package/ctcgfw/luci-proto-minieap/po/zh_Hans/minieap.po b/package/ctcgfw/luci-proto-minieap/po/zh_Hans/minieap.po new file mode 100644 index 0000000000..95b6526a23 --- /dev/null +++ b/package/ctcgfw/luci-proto-minieap/po/zh_Hans/minieap.po @@ -0,0 +1,95 @@ +msgid "" +msgstr "Content-Type: text/plain; charset=UTF-8" + +msgid "Auth Round" +msgstr "认证次数" + +msgid "DHCP After Auth" +msgstr "认证后 DHCP" + +msgid "DHCP Before Auth" +msgstr "认证前 DHCP" + +msgid "DHCP script" +msgstr "DHCP 脚本" + +msgid "DHCP type" +msgstr "DHCP 方式" + +msgid "Disabled" +msgstr "禁用" + +msgid "Double Auth" +msgstr "二次认证" + +msgid "EAP broadcast address" +msgstr "EAP 广播地址" + +msgid "Fake DNS 1" +msgstr "自定义主 DNS 地址" + +msgid "Fake DNS 2" +msgstr "自定义次 DNS 地址" + +msgid "Fake HDD serial" +msgstr "自定义硬盘序列号" + +msgid "Heartbeat interval" +msgstr "心跳间隔" + +msgid "Log file" +msgstr "日志文件" + +msgid "Max DHCP count" +msgstr "最大 DHCP 次数" + +msgid "Max fail" +msgstr "最大失败次数" + +msgid "Max retries" +msgstr "最大重试次数" + +msgid "MiniEAP client" +msgstr "MiniEAP 客户端" + +msgid "Missing username or password" +msgstr "用户名或密码为空" + +msgid "No auto reauth" +msgstr "不自动重新认证" + +msgid "Packet plugins" +msgstr "数据包插件" + +msgid "Password" +msgstr "密码" + +msgid "Program exited with failure. See system log for more information." +msgstr "程序出错退出。查看系统日志获取更多信息。" + +msgid "RJ option" +msgstr "锐捷选项" + +msgid "RJ private" +msgstr "锐捷私有" + +msgid "RJv3 Plugin Settings" +msgstr "RJv3 插件设置" + +msgid "Service name" +msgstr "服务名称" + +msgid "Stage timeout" +msgstr "阶段超时" + +msgid "Standard" +msgstr "标准" + +msgid "Username" +msgstr "用户名" + +msgid "Version string" +msgstr "版本字符串" + +msgid "Wait after fail" +msgstr "失败后等待时间"