An experimental PHP website of WAP technology from the 2000s
Apache + PHP (needs the curl extension). Copy or symlink the repository to /var/www/html/WAP
and set AllowOverride FileInfo (or All) on that directory so the .htaccess (WAP MIME types) is applied.
Serve over plain HTTP, no HTTPS redirect: phones of that era cannot do modern TLS.
Check: curl -I http://localhost/WAP/index.php must return Content-Type: text/vnd.wap.wml.
Opera 12.16 for Linux (last Presto version, from Opera's official archive) renders WML natively
over plain HTTP: open http://localhost/WAP/index.php. Good for iterating on the layout, but it is
more lenient than a real phone, so it does not replace xmllint and the Kannel checks below.
- WAP 2.0 phones (about 2003 onwards): HTTP over TCP, render WML 1.x, no gateway needed.
- WAP 1.x phones (about 1999–2002): WSP over UDP only, they need a WAP gateway (Kannel, below) on UDP ports 9200 (connectionless) / 9201 (connection-oriented).
French carriers have shut down 2G (GSM/GPRS), and CSD data calls are gone. A phone with no Wi-Fi can no longer reach the site through a carrier.
The 9300i has 802.11b Wi-Fi, so it works without any carrier:
- Create a 2.4 GHz network the phone can join. It only supports 802.11b with old security (WEP/WPA), so use a dedicated guest network or an old access point, not your main network.
- On the phone, create a WLAN internet access point for that network.
- Open
http://<server-LAN-IP>/WAP/index.phpin the browser. On the local network, no router port forwarding is needed. - Optional, to test the WAP 1.x path through Kannel over Wi-Fi: if the phone's access point settings let you set a WAP gateway, set it to the server's LAN IP, port 9201 (to verify on the device).
The 7110 has no GPRS and no Wi-Fi. With 2G shut down, the only way left is a private GSM network (Osmocom + an SDR supported by osmo-trx, e.g. USRP B210), in a shielded enclosure: transmitting on GSM bands requires an authorization (Arcep in France).
Kannel only receives WAP over UDP, and Osmocom supports CSD but has no interworking function (CSD → PPP/IP).
So the lab uses the SMS bearer first, through lab/wap_sms_bridge.py (osmo-msc SMPP ↔ Kannel UDP),
then experimental CSD to a GSM modem running pppd.
Full lab documentation (in French): docs/.
Keep decks small: the 7110 accepts about 1.4 KB of compiled WMLC per deck.
sudo apt update && sudo apt install kannel
Minimal /etc/kannel/kannel.conf for the WAP gateway:
group = core
admin-port = 13000
admin-password = change-me
wapbox-port = 13002
wdp-interface-name = "*"
group = wapbox
bearerbox-host = localhost
Enable the wapbox in /etc/default/kannel (START_WAPBOX=1) and restart the kannel service.
A ready-made lab configuration is in lab/kannel.conf.
Tools: sudo apt install libxml2-utils kannel kannel-extras
(xmllint checks the WML is well-formed, Kannel's wml_tester compiles it to WMLC).
sh lab/check.sh
It runs php -l, xmllint, the WMLC size check (< 1400 bytes), the MIME types, the SMS bridge self-test
and, if Kannel is running, real WSP requests with fakewap on ports 9200 and 9201.
Removes the packages installed above, their configuration (/etc/kannel) and unused dependencies:
sudo systemctl stop kannel
sudo apt purge kannel kannel-extras libxml2-utils
sudo apt autoremove --purge
sudo rm -rf /var/log/kannel /var/spool/kannel # leftover logs/queues, if any
Also close the ports opened on your router (TCP 80, UDP 9200–9201).
Un site PHP expérimental autour de la technologie WAP des années 2000.
Apache + PHP (avec l'extension curl). Copier ou lier le dépôt dans /var/www/html/WAP
et activer AllowOverride FileInfo (ou All) sur ce dossier pour que le .htaccess (types MIME WAP) soit pris en compte.
Servir en HTTP simple, sans redirection HTTPS : les téléphones de l'époque ne connaissent pas le TLS moderne.
Vérification : curl -I http://localhost/WAP/index.php doit renvoyer Content-Type: text/vnd.wap.wml.
Opera 12.16 pour Linux (dernière version Presto, sur l'archive officielle d'Opera) affiche le WML nativement
en HTTP simple : ouvrir http://localhost/WAP/index.php. Pratique pour itérer sur le rendu, mais il est
plus permissif qu'un vrai téléphone : il ne remplace donc pas xmllint ni les vérifications Kannel ci-dessous.
- Téléphones WAP 2.0 (environ 2003 et après) : HTTP sur TCP, affichent le WML 1.x, aucune passerelle nécessaire.
- Téléphones WAP 1.x (environ 1999–2002) : WSP sur UDP uniquement, ils ont besoin d'une passerelle WAP (Kannel, ci-dessous) sur les ports UDP 9200 (sans connexion) / 9201 (orienté connexion).
Les opérateurs français ont coupé la 2G (GSM/GPRS), et les appels de données CSD n'existent plus. Un téléphone sans Wi-Fi ne peut plus atteindre le site via un opérateur.
Le 9300i a le Wi-Fi 802.11b, il fonctionne donc sans opérateur :
- Créer un réseau 2,4 GHz que le téléphone peut rejoindre. Il ne gère que le 802.11b avec une sécurité ancienne (WEP/WPA) : utiliser un réseau invité dédié ou un vieux point d'accès, pas votre réseau principal.
- Sur le téléphone, créer un point d'accès Internet WLAN pour ce réseau.
- Ouvrir
http://<IP-locale-du-serveur>/WAP/index.phpdans le navigateur. Sur le réseau local, aucune redirection de port n'est nécessaire sur la box. - Facultatif, pour tester le chemin WAP 1.x via Kannel en Wi-Fi : si les réglages du point d'accès permettent de définir une passerelle WAP, indiquer l'IP locale du serveur, port 9201 (à vérifier sur l'appareil).
Le 7110 n'a ni GPRS ni Wi-Fi. La 2G étant coupée, la seule solution restante est un réseau GSM privé (Osmocom + une SDR prise en charge par osmo-trx, par ex. USRP B210), en enceinte blindée : émettre sur les bandes GSM demande une autorisation (Arcep en France).
Kannel ne reçoit le WAP que sur UDP, et Osmocom gère le CSD mais n'a pas de fonction d'interconnexion (CSD → PPP/IP).
Le labo passe donc d'abord par la porteuse SMS, via lab/wap_sms_bridge.py (SMPP d'osmo-msc ↔ UDP de Kannel),
puis par un CSD expérimental vers un modem GSM relié à pppd.
Documentation complète du labo : docs/.
Garder des decks légers : le 7110 accepte environ 1,4 Ko de WMLC compilé par deck.
sudo apt update && sudo apt install kannel
/etc/kannel/kannel.conf minimal pour la passerelle WAP :
group = core
admin-port = 13000
admin-password = change-me
wapbox-port = 13002
wdp-interface-name = "*"
group = wapbox
bearerbox-host = localhost
Activer le wapbox dans /etc/default/kannel (START_WAPBOX=1) et redémarrer le service kannel.
Une configuration prête pour le labo se trouve dans lab/kannel.conf.
Outils : sudo apt install libxml2-utils kannel kannel-extras
(xmllint vérifie que le WML est bien formé, wml_tester de Kannel le compile en WMLC).
sh lab/check.sh
Le script lance php -l, xmllint, le contrôle de taille WMLC (< 1400 octets), les types MIME, l'auto-test du pont SMS
et, si Kannel tourne, de vraies requêtes WSP avec fakewap sur les ports 9200 et 9201.
Supprime les paquets installés ci-dessus, leur configuration (/etc/kannel) et les dépendances devenues inutiles :
sudo systemctl stop kannel
sudo apt purge kannel kannel-extras libxml2-utils
sudo apt autoremove --purge
sudo rm -rf /var/log/kannel /var/spool/kannel # journaux/files d'attente restants, le cas échéant
Refermer aussi les ports ouverts sur la box (TCP 80, UDP 9200–9201).
