Fix two typos (#1691)

Signed-off-by: Wouter Born <github@maindrain.net>
This commit is contained in:
Wouter Born 2020-10-05 09:03:27 +02:00 committed by GitHub
parent b7a764f358
commit 44b1823e97
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 4 deletions

View File

@ -12,14 +12,13 @@
*/ */
package com.acme; package com.acme;
import javax.sql.rowset.spi.XmlReader;
import org.eclipse.jdt.annotation.NonNullByDefault; import org.eclipse.jdt.annotation.NonNullByDefault;
import org.openhab.core.config.xml.util.XmlDocumentReader;
/** /**
* A class that is in a non-framework package. * A class that is in a non-framework package.
* *
* Used to test if the XStream security configuration in the {@link XmlReader} forbids deserialization. * Used to test if the XStream security configuration in the {@link XmlDocumentReader} forbids deserialization.
* *
* @author Wouter Born - Initial contribution * @author Wouter Born - Initial contribution
*/ */

View File

@ -107,7 +107,7 @@ public class XmlDocumentReaderTest {
* @see https://x-stream.github.io/CVE-2017-7957.html * @see https://x-stream.github.io/CVE-2017-7957.html
*/ */
@Test @Test
public void defaultSecurityProtectsAgainstDenailOfServiceAttacks() throws Exception { public void defaultSecurityProtectsAgainstDenialOfServiceAttacks() throws Exception {
assertThrows(ForbiddenClassException.class, () -> readXML("<void/>")); assertThrows(ForbiddenClassException.class, () -> readXML("<void/>"));
assertThrows(ForbiddenClassException.class, () -> readXML("<string class='void'>Hello, world!</string>")); assertThrows(ForbiddenClassException.class, () -> readXML("<string class='void'>Hello, world!</string>"));
} }