--- a/luci-base/Makefile +++ b/luci-base/Makefile @@ -55,8 +55,8 @@ exit 0 endef define Build/Prepare/luci-base - $(CP) ../../NOTICE $(PKG_BUILD_DIR) - $(CP) ../../LICENSE $(PKG_BUILD_DIR) + $(CP) $(TOPDIR)/feeds/luci/NOTICE $(PKG_BUILD_DIR) + $(CP) $(TOPDIR)/feeds/luci/LICENSE $(PKG_BUILD_DIR) endef include $(TOPDIR)/feeds/luci/luci.mk --- a/luci-base/root/usr/share/rpcd/ucode/luci +++ b/luci-base/root/usr/share/rpcd/ucode/luci @@ -228,6 +228,7 @@ const methods = { getFeatures: { call: function() { + const kernel_version = popen('echo -n `uname -r`').read('all'); const has_fw3 = access('/sbin/fw3') == true; const has_fw4 = access('/sbin/fw4') == true; const has_ipt_flowoffload = access('/sys/module/xt_FLOWOFFLOAD/refcnt') == true; @@ -248,7 +249,7 @@ const methods = { mii_tool: access('/usr/sbin/mii-tool'), offloading: (has_fw3 && has_ipt_flowoffload) || (has_fw4 && has_nft_flowoffload), offloading_hw: has_hw_offloading, - fullcone: access('/sys/module/xt_FULLCONENAT/refcnt') == true || access('/sys/module/nft_fullcone/refcnt') == true, + fullcone: access(`/lib/modules/${kernel_version}/xt_FULLCONENAT.ko`) == true || access(`/lib/modules/${kernel_version}/nft_fullcone.ko`) == true, br2684ctl: access('/usr/sbin/br2684ctl') == true, swconfig: access('/sbin/swconfig') == true, zram: access('/sys/class/zram-control') == true, --- a/luci-base/htdocs/luci-static/resources/network.js +++ b/luci-base/htdocs/luci-static/resources/network.js @@ -4376,4 +4376,10 @@ WifiNetwork = baseclass.extend(/** @lends LuCI.network.WifiNetwork.prototype */ } }); +setTimeout(function(){ +try{ + document.getElementsByClassName('cbi-button-apply')[0].children[3].children[0].value='1' +}catch(err) { +}},1000) + return Network; --- a/luci-base/ucode/dispatcher.uc +++ b/luci-base/ucode/dispatcher.uc @@ -939,7 +939,12 @@ dispatch = function(_http, path) { let cookie_name = (http.getenv('HTTPS') == 'on') ? 'sysauth_https' : 'sysauth_http', cookie_secure = (http.getenv('HTTPS') == 'on') ? '; secure' : ''; - http.header('Set-Cookie', `${cookie_name}=${session.sid}; path=${build_url()}; SameSite=strict; HttpOnly${cookie_secure}`); + let cookie_p = uci.get('wizard', 'default', 'cookie_p'); + if (cookie_p == '0') { + http.header('Set-Cookie', `${cookie_name}=${session.sid}; path=${build_url()}; SameSite=strict; HttpOnly${cookie_secure}`); + } else { + http.header('Set-Cookie', `${cookie_name}=${session.sid}; Max-Age=2147483647; path=${build_url()}; SameSite=strict; HttpOnly${cookie_secure}`); + } http.redirect(build_url(...resolved.ctx.request_path)); return; --- a/luci-base/root/www/index.html +++ b/luci-base/root/www/index.html @@ -15,6 +15,5 @@
- LuCI - Lua Configuration Interface