Florian Schmaus
4249c1a845
Improve PepManager.publish()
...
by using PubSubManager.tryToPublishAndPossibleAutoCreate().
This also swaps the parameters of the method.
Thanks to Guus der Kinderen for suggesting this.
2019-08-28 22:59:30 +02:00
Florian Schmaus
bf0c69c93e
Merge pull request #333 from adiaholic/docFix
...
DocFix in `NodeInformationProvider`
2019-08-22 15:16:00 +02:00
Florian Schmaus
f863bd222c
Merge branch '4.3'
2019-08-22 11:52:41 +02:00
Florian Schmaus
ca7529c192
Use Integer.compare(int, int) now that we are on Android 19
2019-08-04 23:03:42 +02:00
adiaholic
144e99c020
DocFix in NodeInformationProvider
2019-08-04 19:39:55 +05:30
Florian Schmaus
3e74d11b45
Disable MucMemoryLeakTest
...
Although it it not that unreliable, it causes false negatives once in
a while. This is because the standard Java SE API does not provide a
way to force a *full* garbage collection run, we need to resort to
unreliable hacks to trigger one.
The test itself is still useful to diagnose or refute alleged memory
leaks.
This commit also move the test from JUnit 4 to Junit 5.
2019-08-03 22:25:21 +02:00
Florian Schmaus
d2f9617418
Merge pull request #326 from adiaholic/bugFix
...
Return obtained XmlStringBuilder instead of null
2019-07-28 17:50:09 +02:00
adiaholic
41a3ec05c7
Returning obtained XmlStringBuilder instead of null
2019-07-28 16:36:12 +05:30
Florian Schmaus
4ca2c7cc69
Enable MissingJavadocPackage and UnnecessaryParentheses checkstyle checks
2019-07-24 09:18:39 +02:00
Florian Schmaus
91ec6cc955
Javadoc changes for Java 11 compatibility
2019-07-19 23:05:46 +02:00
Florian Schmaus
fda9408cf3
Use XmlStringBuilder in PubSub's SubscribeExtension
2019-07-05 11:31:12 +02:00
Florian Schmaus
9c0da3ed07
Change SubscribeExtension's jid field type from String to Jid
...
and make it final.
2019-07-05 11:24:02 +02:00
Florian Schmaus
df5899e72b
Introduce SmackConfiguration.SMACK_URL(_STRING)
2019-07-04 15:51:28 +02:00
Florian Schmaus
f3b856c80b
Improve shouldFailIfInitiatorCannotConnectToSocks5Proxy() unit test
...
If run in parallel with other unit tests, especially onces that open
up a proxy, this test could fail, because another unit test actually
had an proxy running on the very address this unit test assumes to be
no proxy running.
We now use an IP address from RFC 5737's TEST-NET-1 address block,
which should never be available.
2019-07-04 15:49:47 +02:00
0ad1a0bd4c
Add note about BookmarkManager to MUCManager
2019-07-03 23:37:51 +02:00
Florian Schmaus
a3f6fa65a4
Disallow null or empty string in PubSubManager.getNode(String)
2019-06-12 22:31:55 +02:00
Florian Schmaus
ef88bb17d0
Disallow empty string as node in DiscoverInfo
2019-06-12 22:31:29 +02:00
Florian Schmaus
c6c904cc3e
Add support for XEP-0350: Data Forms Geolocation Element
...
Fixes SMACK-871.
2019-06-12 17:13:05 +02:00
Florian Schmaus
fa0c16d75c
Introduce EqualsUtil and HashCode.(Builder|Cache)
2019-06-12 14:51:17 +02:00
Florian Schmaus
92b02afbff
Improve exceptions of Socks5Proxy
2019-06-11 12:47:40 +02:00
Florian Schmaus
818ee8a727
Make Objects.requireNonNull() throw IllegalArgumentException
...
and not NullPointerException. Altough this differs from
java.util.Objects behavior, throwing an IllegalArgumentException
appears more sensible and makes it easier to catch it in Smack's
parsing function.
2019-06-11 12:47:40 +02:00
Florian Schmaus
9bb36fc63c
Make Socks5TestProxy a subclass of Socks5Proxy
...
to reduce the duplicated code. This also means we are now testing the
real implementation.
2019-06-11 12:47:39 +02:00
Florian Schmaus
6e1193edaf
Use QName instead of XmppStringUtils.generateKey()
2019-06-11 12:47:39 +02:00
Florian Schmaus
ce70308099
Introduce UInt(16|32) datatypes
2019-06-11 12:47:39 +02:00
Florian Schmaus
c0183775fe
Add support for XEP-0221: Data Forms Media Element
...
Fixes SMACK-824.
2019-06-11 12:47:39 +02:00
Florian Schmaus
1f8b7273a8
Improve junit test in Socks5ByteStreamManager
...
It could be that the test is flapping. This helps to see the origin of
the unexpected exception.
2019-06-11 12:47:39 +02:00
Florian Schmaus
4d36e3b521
Introduce FormFieldChildElement and make FormField immutable
2019-06-11 12:47:39 +02:00
Florian Schmaus
1a99801501
Fix typo in FormField's javadoc: s/fold/field/
2019-06-05 10:54:17 +02:00
Florian Schmaus
9a2cca2bd3
Merge branch 'master' of github.com:Flowdalic/Smack
2019-06-03 17:41:49 +02:00
Florian Schmaus
b288768f77
Introduce util.InternetAddress
...
and use it where sensible. Also fixes a few unit tests along the way.
2019-06-03 17:41:10 +02:00
Florian Schmaus
619b8e6f4a
Add secure(OnlineAttackSafe|Unique|OfflineAttackSafe)RandomString()
...
and replace usages of java.util.UUID in Smack with
secureUniqueRandomString() because it uses a thread-local secure random
number generator.
2019-06-02 20:08:03 +02:00
Florian Schmaus
58fc39714f
Use assertThrows() in Socks5ByteStreamManagerTest
2019-06-02 11:00:37 +02:00
Florian Schmaus
839e347676
Rename NumberUtil.checkIfInUInt32Range() to requireUInt32
2019-06-02 10:46:53 +02:00
Florian Schmaus
726a2de273
Deprecate ParserUtils.getQName()
2019-06-02 10:44:50 +02:00
Florian Schmaus
af6ee76f4c
Remove empty lines in Socks5BytestreamManager
2019-06-02 10:41:39 +02:00
Florian Schmaus
49aa7ce21b
Do not swallow exception in Socks5BytestreamManager
2019-06-02 10:41:27 +02:00
Florian Schmaus
9352225f44
Rework SOCKS5 unit tests so that they can be run in parallel
...
As result it is now also possible to start multiple local SOCKS5
proxies with different port, which is usually not necessary in real
life but useful for unit tests.
2019-06-02 10:38:19 +02:00
Florian Schmaus
d337474a86
Add DiscoverItems.Item.toString()
2019-05-23 23:06:39 +02:00
Florian Schmaus
02f7cfcf27
Improve session sweeping logic in AdHocCommandManager
...
Fixes SMACK-624.
2019-05-20 10:41:01 +02:00
Florian Schmaus
02e2eba556
Socks5Proxy: Remove empty line
2019-05-18 13:24:48 +02:00
Florian Schmaus
48010f3b82
Socks5Proxy: Log if server thread termination was interrupted
2019-05-18 13:24:30 +02:00
Florian Schmaus
11ae6d6960
Socks5Proxy: Use CloseableUtil to close server socket
2019-05-18 13:24:05 +02:00
Florian Schmaus
ab99f629a3
Socks5Proxy: Include server socket in thread name
2019-05-18 13:23:24 +02:00
Florian Schmaus
f7762c5db7
Add "whitespace after comma" checkstyle rule
2019-05-17 21:56:46 +02:00
Florian Schmaus
7e25c3ada5
Merge branch '4.3'
2019-05-16 20:52:27 +02:00
Florian Schmaus
60db42e2f4
Merge pull request #299 from magnetsystems/autojoin-callback-on-reconnect
...
Autojoin callback on reconnect
2019-05-08 13:43:46 +02:00
Florian Schmaus
f4ee7dd541
Update PowerMock to 2.0.2
...
and set Mockito 2's mock-maker-inline as MockMaker to allow mocking of
final classes.
2019-05-08 12:44:48 +02:00
Florian Schmaus
d2f5efcb20
Use StandardCharsets.(UTF_8|US_ASCII)
...
This also gets rid of a ton of UnsupportedEncodingException s.
2019-05-08 12:44:48 +02:00
Florian Schmaus
2a4d110b22
Add Socks5Exception and improve SOCKS5 bytestream exception messages
...
The exception message now also contains the stream hosts and their
exception.
2019-05-08 11:07:18 +02:00
Florian Schmaus
fd89a5e5a5
Add StreamHost.toString()
2019-05-08 09:24:23 +02:00