jXMPP [1], a FOSS XMPP-base library, has just been extended by a
testframework for "XMPP-Strings". Currently, this is limited to Local-,
Domain- and Resourceparts and the various XMPP address types, but may be
extended to future Strings found in XMPP-land.

The testframework comes with a corpus of known valid and invalid XMPP
addresses (JIDs). I am happy about feedback and contributions to the
corpus. Hopefully it becomes a useful resource for XMPP developers. You
can find the corpus under

-
https://github.com/igniterealtime/jxmpp/tree/master/jxmpp-strings-testframework/src/main/resources/xmpp-strings/jids/valid/main
-
https://github.com/igniterealtime/jxmpp/blob/master/jxmpp-strings-testframework/src/main/resources/xmpp-strings/jids/invalid/main

The testframework currently uses the following libraries to prepare and
enforce the Strings:

- ICU4J
- GNU libidn
- xmpp.rocks's PRECIS

a further minimalistic implementation, called "simple", is part of jXMPP.

You can run the testframework simply by

``` bash
git clone https://github.com/igniterealtime/jxmpp.git
cd jxmpp
./test-xmpp-strings
```

if you have `gradle` and `python3` in your path.

Please note that ICU4J and libidn (and "simple") do not currently
provide the required PRECIS profile and hence the older Stringprep
profiles are used.

Feel free to use the provided infrastructure to test your own
implementation. Thanks to JNI and the polyglot programming feature of
the GraalVM, it should be easily possible even if you implementation is
not written in a JVM-based language. Please contact me if you need
assistance.

- Florian

1: https://github.com/igniterealtime/jxmpp

Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
JDev mailing list
Info: https://mail.jabber.org/mailman/listinfo/jdev
Unsubscribe: jdev-unsubscr...@jabber.org
_______________________________________________

Reply via email to