Skip to main content
Skip table of contents

Classify Newegg Traffic

function Flow_ClassifyNeweggTraffic (dpiMsg)
  local function isempty(s)
    return s == nil or s == ''
  end
  local app = GetString(dpiMsg, "internal", "application")
  if app == "http" then
    local location = GetString(dpiMsg, "http", "location")
    local headerRaw = GetString(dpiMsg, "http", "header_raw")
    if not isempty(location) then
      foundInLocation = string.find(location, "newegg", 1, true)
    end

    if not isempty(headerRaw) then
      foundInHeader = string.find(headerRaw, "newegg", 1, true)
    end

    if foundInLocation or foundInHeader then
      SetCustomApplication(dpiMsg, "newegg")
    end
  end
end
JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.