diff --git a/Attacks/pom.xml b/Attacks/pom.xml
index 201b771f45..4b648eaebc 100644
--- a/Attacks/pom.xml
+++ b/Attacks/pom.xml
@@ -4,7 +4,7 @@
de.rub.nds.tlsattacker
TLS-Attacker
- 3.2
+ 3.3.0
Attacks
jar
diff --git a/Attacks/src/main/java/de/rub/nds/tlsattacker/attacks/ec/oracles/RealDirectMessageECOracle.java b/Attacks/src/main/java/de/rub/nds/tlsattacker/attacks/ec/oracles/RealDirectMessageECOracle.java
index 35f9b1a081..3587de1ca7 100644
--- a/Attacks/src/main/java/de/rub/nds/tlsattacker/attacks/ec/oracles/RealDirectMessageECOracle.java
+++ b/Attacks/src/main/java/de/rub/nds/tlsattacker/attacks/ec/oracles/RealDirectMessageECOracle.java
@@ -76,6 +76,7 @@ public boolean checkSecretCorrectnes(Point ecPoint, BigInteger secret) {
ECDHClientKeyExchangeMessage message = (ECDHClientKeyExchangeMessage) WorkflowTraceUtil.getFirstSendMessage(
HandshakeMessageType.CLIENT_KEY_EXCHANGE, trace);
+ message.prepareComputations();
// modify public point base X coordinate
ModifiableBigInteger x = ModifiableVariableFactory.createBigIntegerModifiableVariable();
@@ -92,7 +93,6 @@ public boolean checkSecretCorrectnes(Point ecPoint, BigInteger secret) {
ModifiableByteArray pms = ModifiableVariableFactory.createByteArrayModifiableVariable();
byte[] explicitePMS = BigIntegers.asUnsignedByteArray(curve.getModulus().bitLength() / 8, secret);
pms.setModification(ByteArrayModificationFactory.explicitValue(explicitePMS));
- message.prepareComputations();
message.getComputations().setPremasterSecret(pms);
if (numberOfQueries % 100 == 0) {
diff --git a/Attacks/src/main/java/de/rub/nds/tlsattacker/attacks/impl/InvalidCurveAttacker.java b/Attacks/src/main/java/de/rub/nds/tlsattacker/attacks/impl/InvalidCurveAttacker.java
index 132a15d9f4..729ca18903 100644
--- a/Attacks/src/main/java/de/rub/nds/tlsattacker/attacks/impl/InvalidCurveAttacker.java
+++ b/Attacks/src/main/java/de/rub/nds/tlsattacker/attacks/impl/InvalidCurveAttacker.java
@@ -85,22 +85,18 @@ public Boolean isVulnerable() {
EllipticCurve curve = CurveFactory.getCurve(config.getNamedGroup());
Point point = Point.createPoint(config.getPublicPointBaseX(), config.getPublicPointBaseY(),
config.getNamedGroup());
- for (int i = 0; i < getConfig().getProtocolFlows(); i++) {
- if (config.getPremasterSecret() != null) {
- premasterSecret = config.getPremasterSecret();
- } else {
- Point sharedPoint = curve.mult(new BigInteger("" + i + 1), point);
- premasterSecret = sharedPoint.getX().getData();
- if (premasterSecret == null) {
- premasterSecret = BigInteger.ZERO;
- }
- LOGGER.debug("PMS: " + premasterSecret.toString());
- }
+
+ int protocolFlows = getConfig().getProtocolFlows();
+ if (config.getPremasterSecret() != null) {
+ protocolFlows = 1;
+ }
+
+ for (int i = 0; i < protocolFlows; i++) {
+ setPremasterSecret(curve, i, point);
try {
WorkflowTrace trace = executeProtocolFlow();
if (!WorkflowTraceUtil.didReceiveMessage(HandshakeMessageType.SERVER_HELLO, trace)) {
LOGGER.info("Did not receive ServerHello. Check your config");
-
return null;
}
if (!WorkflowTraceUtil.didReceiveMessage(HandshakeMessageType.FINISHED, trace)) {
@@ -116,6 +112,19 @@ public Boolean isVulnerable() {
return false;
}
+ private void setPremasterSecret(EllipticCurve curve, int i, Point point) {
+ if (config.getPremasterSecret() != null) {
+ premasterSecret = config.getPremasterSecret();
+ } else {
+ Point sharedPoint = curve.mult(new BigInteger("" + (i + 1)), point);
+ premasterSecret = sharedPoint.getX().getData();
+ if (premasterSecret == null) {
+ premasterSecret = BigInteger.ZERO;
+ }
+ LOGGER.debug("PMS: " + premasterSecret.toString());
+ }
+ }
+
private WorkflowTrace executeProtocolFlow() {
Config tlsConfig = getTlsConfig();
WorkflowTrace trace = new WorkflowConfigurationFactory(tlsConfig).createWorkflowTrace(WorkflowTraceType.HELLO,
diff --git a/README.md b/README.md
index 6624927c88..b2e6e4c4f0 100644
--- a/README.md
+++ b/README.md
@@ -1,6 +1,6 @@
# TLS-Attacker
-[![release](https://img.shields.io/badge/Release-v3.0-blue.svg)](https://github.com/RUB-NDS/TLS-Attacker/releases)
+[![release](https://img.shields.io/badge/Release-v3.3.0-blue.svg)](https://github.com/RUB-NDS/TLS-Attacker/releases)
![licence](https://img.shields.io/badge/License-Apachev2-brightgreen.svg)
[![travis](https://travis-ci.org/RUB-NDS/TLS-Attacker.svg?branch=master)](https://travis-ci.org/RUB-NDS/TLS-Attacker)
diff --git a/TLS-Client/pom.xml b/TLS-Client/pom.xml
index 7b543ba348..29a34170f6 100644
--- a/TLS-Client/pom.xml
+++ b/TLS-Client/pom.xml
@@ -4,7 +4,7 @@
de.rub.nds.tlsattacker
TLS-Attacker
- 3.2
+ 3.3.0
TLS-Client
TLS-Client
diff --git a/TLS-Core/pom.xml b/TLS-Core/pom.xml
index cb05f3cfb5..e80f2e60fb 100644
--- a/TLS-Core/pom.xml
+++ b/TLS-Core/pom.xml
@@ -4,7 +4,7 @@
de.rub.nds.tlsattacker
TLS-Attacker
- 3.2
+ 3.3.0
TLS-Core
jar
diff --git a/TLS-Forensics/pom.xml b/TLS-Forensics/pom.xml
index e318c39d06..724d47aa09 100644
--- a/TLS-Forensics/pom.xml
+++ b/TLS-Forensics/pom.xml
@@ -4,7 +4,7 @@
de.rub.nds.tlsattacker
TLS-Attacker
- 3.2
+ 3.3.0
TLS-Forensics
jar
diff --git a/TLS-Mitm/pom.xml b/TLS-Mitm/pom.xml
index 0f5562d7c6..bbaa306a6d 100644
--- a/TLS-Mitm/pom.xml
+++ b/TLS-Mitm/pom.xml
@@ -4,7 +4,7 @@
de.rub.nds.tlsattacker
TLS-Attacker
- 3.2
+ 3.3.0
TLS-Mitm
jar
diff --git a/TLS-Server/pom.xml b/TLS-Server/pom.xml
index def6eb9582..862d84a981 100644
--- a/TLS-Server/pom.xml
+++ b/TLS-Server/pom.xml
@@ -4,7 +4,7 @@
de.rub.nds.tlsattacker
TLS-Attacker
- 3.2
+ 3.3.0
TLS-Server
jar
diff --git a/TraceTool/pom.xml b/TraceTool/pom.xml
index 2a53cd7f2d..67ccfb9a81 100644
--- a/TraceTool/pom.xml
+++ b/TraceTool/pom.xml
@@ -4,7 +4,7 @@
de.rub.nds.tlsattacker
TLS-Attacker
- 3.2
+ 3.3.0
TraceTool
jar
diff --git a/Transport/pom.xml b/Transport/pom.xml
index 18bfae1877..c5ad17243b 100644
--- a/Transport/pom.xml
+++ b/Transport/pom.xml
@@ -4,7 +4,7 @@
de.rub.nds.tlsattacker
TLS-Attacker
- 3.2
+ 3.3.0
Transport
jar
diff --git a/Utils/pom.xml b/Utils/pom.xml
index a063f95a8b..eb4b60dc21 100644
--- a/Utils/pom.xml
+++ b/Utils/pom.xml
@@ -4,7 +4,7 @@
de.rub.nds.tlsattacker
TLS-Attacker
- 3.2
+ 3.3.0
Utils
jar
diff --git a/pom.xml b/pom.xml
index 7f39bf113e..9f91cb58ea 100644
--- a/pom.xml
+++ b/pom.xml
@@ -3,7 +3,7 @@
4.0.0
de.rub.nds.tlsattacker
TLS-Attacker
- 3.2
+ 3.3.0
pom
2015
TLS-Attacker