mirror of
http://git.haproxy.org/git/haproxy.git/
synced 2024-12-30 08:32:05 +00:00
4438c6061d
s/accidently/accidentally/ s/any ot these messages/any of theses messages/ s/catched/caught/ s/completly/completely/ s/convertor/converter/ s/desribing/describing/ s/developper/developer/ s/eventhough/even though/ s/exectution/execution/ s/functionnality/functionality/ s/If it receive a/If it receives a/ s/In can even/It can even/ s/informations/information/ s/it will be remove /it will be removed / s/langage/language/ s/mentionned/mentioned/ s/negociated/negotiated/ s/Optionnaly/Optionally/ s/ouputs/outputs/ s/outweights/outweighs/ s/ressources/resources/
72 lines
2.6 KiB
Plaintext
72 lines
2.6 KiB
Plaintext
Scientiamobile WURFL Device Detection
|
|
-------------------------------------
|
|
|
|
You can also include WURFL for inbuilt device detection enabling attributes.
|
|
|
|
WURFL is a high-performance and low-memory footprint mobile device detection
|
|
software component that can quickly and accurately detect over 500 capabilities
|
|
of visiting devices. It can differentiate between portable mobile devices, desktop devices,
|
|
SmartTVs and any other types of devices on which a web browser can be installed.
|
|
|
|
In order to add WURFL device detection support, you would need to download Scientiamobile
|
|
InFuze C API and install it on your system. Refer to www.scientiamobile.com to obtain a valid
|
|
InFuze license.
|
|
Compile haproxy as shown :
|
|
|
|
$ make TARGET=<target> USE_WURFL=1
|
|
|
|
Optionally WURFL_DEBUG=1 may be set to increase logs verbosity
|
|
|
|
For HAProxy developers who need to verify that their changes didn't accidentally
|
|
break the WURFL code, it is possible to build a dummy library provided in the
|
|
contrib/wurfl directory and to use it as an alternative for the full library.
|
|
This will not provide the full functionalities, it will just allow haproxy to
|
|
start with a wurfl configuration, which generally is enough to validate API
|
|
changes :
|
|
|
|
$ make -C contrib/wurfl
|
|
$ make TARGET=<target> USE_WURFL=1 WURFL_INC=$PWD/contrib/wurfl WURFL_LIB=$PWD/contrib/wurfl
|
|
|
|
These are the supported WURFL directives (see doc/configuration.txt) :
|
|
- wurfl-data-file <path to WURFL data file>
|
|
- wurfl-information-list [<string>] (list of WURFL capabilities,
|
|
virtual capabilities, property names we plan to use in injected headers)
|
|
- wurfl-information-list-separator <char> (character that will be
|
|
used to separate values in a response header, ',' by default).
|
|
- wurfl-cache-size <string> (Sets the WURFL caching strategy)
|
|
- wurfl-patch-file [<file path>] (Sets the paths to custom WURFL patch files)
|
|
|
|
Sample configuration :
|
|
|
|
global
|
|
wurfl-data-file /usr/share/wurfl/wurfl.zip
|
|
|
|
wurfl-information-list wurfl_id model_name
|
|
|
|
#wurfl-information-list-separator |
|
|
|
|
## single LRU cache
|
|
#wurfl-cache-size 100000
|
|
## no cache
|
|
#wurfl-cache-size 0
|
|
|
|
#wurfl-patch-file <paths to custom patch files>
|
|
|
|
...
|
|
frontend
|
|
bind *:8888
|
|
default_backend servers
|
|
|
|
There are two distinct methods available to transmit the WURFL data downstream
|
|
to the target application:
|
|
|
|
All data listed in wurfl-information-list
|
|
|
|
http-request set-header X-WURFL-All %[wurfl-get-all()]
|
|
|
|
A subset of data listed in wurfl-information-list
|
|
|
|
http-request set-header X-WURFL-Properties %[wurfl-get(wurfl_id,is_tablet)]
|
|
|
|
Please find more information about WURFL and the detection methods at https://www.scientiamobile.com
|