File tree Expand file tree Collapse file tree 1 file changed +45
-0
lines changed
TLS-Core/src/main/java/de/rub/nds/tlsattacker/core/workflow Expand file tree Collapse file tree 1 file changed +45
-0
lines changed Original file line number Diff line number Diff line change @@ -331,6 +331,51 @@ public ReceivingAction getLastReceivingAction() {
331331 return null ;
332332 }
333333
334+ /**
335+ * Get the first MessageAction of the workflow trace.
336+ *
337+ * @return the first MessageAction of the workflow trace. Null if no message
338+ * actions are defined
339+ */
340+ public MessageAction getFirstMessageAction () {
341+ for (int i = 0 ; i < tlsActions .size (); i ++) {
342+ if (tlsActions .get (i ) instanceof MessageAction ) {
343+ return (MessageAction ) (tlsActions .get (i ));
344+ }
345+ }
346+ return null ;
347+ }
348+
349+ /**
350+ * Get the first SendingAction of the workflow trace.
351+ *
352+ * @return the first SendingAction of the workflow trace. Null if no sending
353+ * actions are defined
354+ */
355+ public SendingAction getFirstSendingAction () {
356+ for (int i = 0 ; i < tlsActions .size (); i ++) {
357+ if (tlsActions .get (i ) instanceof SendingAction ) {
358+ return (SendingAction ) (tlsActions .get (i ));
359+ }
360+ }
361+ return null ;
362+ }
363+
364+ /**
365+ * Get the first ReceivingActionAction of the workflow trace.
366+ *
367+ * @return the first ReceivingActionAction of the workflow trace. Null if no
368+ * receiving actions are defined
369+ */
370+ public ReceivingAction getFirstReceivingAction () {
371+ for (int i = 0 ; i < tlsActions .size (); i ++) {
372+ if (tlsActions .get (i ) instanceof ReceivingAction ) {
373+ return (ReceivingAction ) (tlsActions .get (i ));
374+ }
375+ }
376+ return null ;
377+ }
378+
334379 public String getName () {
335380 return name ;
336381 }
You can’t perform that action at this time.
0 commit comments