FireShield

Hydra protocol feature

General information

Fireshield configuration can be initially setuped on the developer portal or on the client side. And can be received by GetRemoteConfig request.

// example of fireshield config
{
	"enabled": true,
	"services": [
	],
	"alert_page": {
		"domain": "%domain%",
		"path": "%path_to_page%"
	},
	"categories": [
		{
			"category": "unsafe:untrusted",
			"type": "block_alert_page"
		},
		{
			"category": "unsafe:spam",
			"type": "block_dns"
		},
		
	],
	"domains": {
		"unsafe:untrusted": [
			"%domain1%",
			"%domain2%"
		],
		"unsafe:spam": [
			"%domain4%",
			"%domain5%"
		]
	}
}

Fireshield configurations saves %ProgramData%/UnifiedSDK.Service in following

  • filesfireshield - contains a fireshild config that will be used by Hydra.

  • unsafefraud, unsafespam, unsafeuntrusted, safe and etc. - this files contains domains for any possible category (the category name must match the file name) in fireshield config

Possible fireshield category types:

  • ProxyPeer

  • BlockAlertPage - all calls of the specified domains will be redirected to block alert page

  • BlockDns - all calls of the specified domains will be blocked

  • Bypass - all calls of the specified domains will be outside VPN tunnel

  • Vpn - all calls of the specified domains will be in the VPN tunnel

Fireshield manual setup

To setup Fireshield configuration files can be changed from client with two ways

  • changing files directly

  • or using FireshiledService

FireshieldService methods

void GetFireshieldConfig(string fireshieldConfig) - returns current fireshield config

  • fireshieldConfig - fireshid config presented like json string

CreateIfNoExists(string newFireshieldConfig) - creates fireshield config if not exists

  • newFireshieldConfig - fireshid config presented like json string

EnsureFireshieldConfig() - ensures the current fireshield config.

EnsureCategory(string categoryName, FireshieldCategoryType fireshieldCategoryType) - ensures category to the config

  • categoryName - enshured category name

  • fireshieldCategoryType - fireshield category type

RemoveCategory(string categoryName) - removes category from the config

  • categoryName - removed category name

EnsureCategoryRules(string categoryName) - ensures category rule to the config

  • categoryName - removed category name

AddService(string serviceDatabaseName) - adds service to the config

  • serviceDatabaseName - fireshield service database name

RemoveService(string serviceDatabaseName) - Removes service form the config

  • serviceDatabaseName - fireshield service database name

EnableFireshield(bool enabled) - adds enable flag to the config

  • enabled - is fireshield enabled value

ConfigureAlertPage(string domain, string path) - configures alert page

  • domain - domain of alert page

  • path - path to alert page

DeleteFireshieldConfig() - deletes the current fireshield config

Launch Hydra with fireshield config

Last updated