-- -- (C) 2013-20 - ntop.org -- local dirs = ntop.getDirs() package.path = dirs.installdir .. "/scripts/lua/modules/?.lua;" .. package.path require "lua_utils" local ts_utils = require("ts_utils") local info = ntop.getInfo() local page_utils = require("page_utils") local format_utils = require("format_utils") local os_utils = require "os_utils" local menu_alert_notifications = require("menu_alert_notifications") local alert_notification = require("alert_notification") local notifications = {} sendHTTPContentTypeHeader('text/html') if(_POST["ntopng_license"] ~= nil) then ntop.setCache('ntopng.license', trimSpace(_POST["ntopng_license"])) ntop.checkLicense() ntop.setCache('ntopng.cache.force_reload_plugins', '1') -- housekeeping.lua will reload plugins info = ntop.getInfo() if (info["version.enterprise_l_edition"] and info["pro.license"] ~= "") then table.insert(notifications, alert_notification:create(0, i18n("info"), i18n("about.create_license_l"), "info")) elseif (not info["version.enterprise_l_edition"] and info["pro.license"] ~= "") then table.insert(notifications, alert_notification:create(0, i18n("info"), i18n("about.create_license"), "info")) end end page_utils.set_active_menu_entry(page_utils.menu_entries.about, { product=info.product }) dofile(dirs.installdir .. "/scripts/lua/inc/menu.lua") menu_alert_notifications.render_notifications("about", notifications) print("
") print("
") print("
") page_utils.print_page_title(i18n("about.about_x", {product=info["product"]})) print("
") print("
") print("
") print("
") print("\n") print("\n") print("") vers = string.split(info["version.git"], ":") if((vers ~= nil) and (vers[2] ~= nil)) then ntopng_git_url = ""..info["version"].." ("..info["revision"]..")" else ntopng_git_url = info["version"] end print("\n") end print("\n") print("\n") --print("\n") ndpi_ver = info["version.ndpi"] if (ndpi_ver ~= nil) then v = string.split(ndpi_ver, " ") if (v ~= nil) then ndpi_vers = v[1] v_all = string.sub(v[2], 2, -2) vers = string.split(v_all, ":") ndpi_hash = vers[1] ndpi_date = vers[2] print("\n") else print("\n") end end print("\n") print("\n") print("\n") print("\n") if(info["version.nindex"] ~= nil) then print("\n") end if ts_utils.getDriverName() == "influxdb" then print("\n") print[[ ]] -- NOTE: need to calculate this dynamically as it can be temporary disabled at runtime local resolution = tonumber(ntop.getPref("ntopng.prefs.ts_resolution")) if hasHighResolutionTs() then l7_resolution = "1m" else l7_resolution = "5m" end end print("\n") print("\n") print("\n") if info["version.zmq"] ~= nil then print("\n") end if(info["version.geoip"] ~= nil) then print("\n") end print("\n") print("
") print(i18n("about.copyright")) print(""..info["copyright"].."
") print(i18n("about.licence")) print("") info["ntopng.license"] = ntop.getCache('ntopng.license') if(info["pro.release"] == false) then print("".. info["license"] .."") else print("EULA") end if(info["pro.systemid"] and (info["pro.systemid"] ~= "")) then v = split(info["version"], " ") print(" [ SystemId: ".. info["pro.systemid"] .." ]") print [[
]] print(i18n("about.licence_generation", { purchase_url='http://shop.ntop.org/', universities_url='http://www.ntop.org/support/faq/do-you-charge-universities-no-profit-and-research/' })) print[[

]] print('

') if(isAdministrator()) then if(info["pro.use_redis_license"] or (info["pro.license"] == "")) then print('
') print('\n') print('
]] else if(info["pro.license"]) then print(i18n("about.licence")..": ".. info["pro.license"] .."\n") if info["pro.license_ends_at"] ~= nil and info["pro.license_days_left"] ~= nil then print("
"..i18n("about.maintenance", { _until = format_utils.formatEpoch(info["pro.license_ends_at"]), days_left = info["pro.license_days_left"]})) end end end end end print("
"..i18n("about.version")..""..ntopng_git_url.." - ") printntopngRelease(info) if((info["OS"] ~= nil) and (info["OS"] ~= "")) then print("
"..i18n("about.built_on")..""..info["OS"].."
"..i18n("about.platform")..""..info["platform"].." - "..info["bits"] .." bit
"..i18n("about.startup_line").."".. info["product"] .." "..info["command_line"].."
 
nDPI "..ndpi_date.."
nDPI "..ndpi_ver.."
cURL"..info["version.curl"].."
Twitter Bootstrap4.4.0
Font Awesome5.11.2
RRDtool"..info["version.rrd"].."
nIndex"..info["version.nindex"].."
InfluxDBLoading...
Redis Server"..info["version.redis"].."
Mongoose web server"..info["version.httpd"].."
LuaJIT"..info["version.luajit"].."
ØMQ"..info["version.zmq"].."
GeoLite"..info["version.geoip"]) print [[
]] print(i18n("about.maxmind", {maxmind_url="http://www.maxmind.com/"})) print[[ ]] print("
Data-Driven Documents (d3js)2.9.1 / 3.0
\n") print("
") print("
") print("
") dofile(dirs.installdir .. "/scripts/lua/inc/footer.lua")