Commit 3965c062 authored by Lars Hermerschmidt's avatar Lars Hermerschmidt
Browse files

example set up

parent 1ecd809e
Folders in this repository:
core - the MontiSecArc language and analysis tools source code
doc - documentation for MontiSecArc
examples - example projects for the MontiSecArc tools <------------ start here
Start the analysis tool by executing the script startExample.sh.
This will analyze the MontiSecArc Model in src/test/resources/secarc/seccds/fe/Store.secarc, which uses different files in src/test/resources/.
The impact of the individual analysis can be adjusted in src/main/conf/Analysis_Conf.txt
In case you want to change the analysises implemented in MontiSecArcAnalysis, run mvn install in the ../../core folder and change the script startExample.sh to point at the resulting jar ../../core/montiSecArcAnalysis/target/montiSecArcAnalysis.jar.
L01-List-Filters 1
L02-List-Critical-Ports 1
L03-List-Incoming-Ports 1
L04-List-Outgoing-Ports 1
L05-List-Ports-String 1
L06-List-Third-Party-Components 2
L07-List-Not-Reviewed-Configuration 1
D01-Derive-Role-Component 1
D02-Derive-Role-Port 1
D03-Derive-Role-Third-Party-Component 1
D04-Derive-Trustlevel-Component 1
E01-Unencrypted-Connector-In-Path 1
E02-Unencrypted-Connector-Low-Trustlevel 1
E03-Encrypted-Path-Continues-Unencrypted 1
E04-Unencrypted-Path-End-In-Low-Trustlevel 1
E05-Trustlevel-Connector-Higher 1
I01-Encrypted-Connector 1
I02-Trustlevel-Client-Server 1
I03-Roles-Defined 1
F01-Taint-Tracking 1
F02-High-Trustlevel 1
T01-Reason-Trustlevel 1
T02-High-Trustlevel 1
WI01-Access-Roles 1
WI02-Third-Party-Component-Security 1
WI03-Low-Trustlevel 1
WI04-Critical-Ports 1
\ No newline at end of file
/*
* Copyright (c) 2015 RWTH Aachen. All rights reserved.
*
* http://www.se-rwth.de/
*/
package montiSecArcAnalysisExample;
/**
* TODO: Write me!
*
* @author (last commit) $Author$
* @version $Revision$, $Date$
* @since TODO: add version number
*
*/
public class Test {
public static void main(String[] arguments) {
System.out.println(arguments.length);
}
}
package example;
// import message types
import secarc.seccds.msg.*;
component Store {
accesscontrol on;
autoconnect port;
access stockManager, storeManager, cashier;
trustlevel +2;
port
in String inIdentifier,
out ProductData outPData;
port
in SaleInformation;
connect storeServer.productData -> outPData;
component StoreServer storeServer {
autoconnect port;
configuration confName;
cpe "cpeName";
port
in String inIdentifier,
in SaleInformation,
out ProductData;
component (filter fString) FilterIdentifier filterIdentifier {
port
in String inIdentifier,
out Identifier;
}
component DataProcessor dataProcessor {
port
out ProductData,
in Identifier,
(filter fInformation) in SaleInformation filterInfo;
}
connect saleInformation -> dataProcessor.filterInfo;
}
}
package secarc.analysis.configuration;
component ConfigurationNotReviewed {
accesscontrol off;
trustlevel +1;
component Help help {
trustlevel +1;
}
component TargetHelp targetHelp {
cpe "1.2";
configuration conf;
trustlevel +1;
}
component SubEncryptedConnector subEncryptedConnector{
trustlevel +1;
}
}
\ No newline at end of file
package secarc.analysis.configuration;
component ConfigurationReviewed {
accesscontrol off;
trustlevel +1;
component Help help {
trustlevel +1;
}
component TargetHelp targetHelp {
cpe "1.2";
configuration conf_reviewed;
trustlevel +1;
}
component SubEncryptedConnector subEncryptedConnector {
trustlevel +1;
}
}
\ No newline at end of file
package secarc.analysis.connector;
component EncryptedPathEndInLowTrustlevel {
accesscontrol off;
trustlevel +2;
component Help help {
trustlevel +1;
}
component TargetHelp targetHelp {
cpe "1.2";
port in int inputTarget;
configuration conf_reviewed;
trustlevel +1;
}
connect encrypted subEncryptedConnector.inputSub2 -> targetHelp.inputTarget;
component SubEncryptedConnector subEncryptedConnector {
trustlevel +2;
port
out int inputSub2;
}
}
\ No newline at end of file
package secarc.analysis.connector;
component EncryptedPathWithLowerTrustlevel {
accesscontrol off;
trustlevel +1;
component Help help {
trustlevel +1;
}
component TargetHelp targetHelp {
trustlevel +0;
port in int inputTarget;
}
connect encrypted subEncryptedConnector.inputSub2 -> targetHelp.inputTarget;
component SubEncryptedConnector subEncryptedConnector {
trustlevel +0;
port
out int inputSub2;
}
}
\ No newline at end of file
package secarc.analysis.connector;
component EncryptedPathWithUnencryptedPart {
accesscontrol off;
trustlevel +0;
port
in int input;
component Help help {
trustlevel +1;
}
component TargetHelp targetHelp {
cpe "1.2";
port in int inputTarget;
configuration conf_reviewed;
trustlevel +1;
}
component SubEncryptedConnector subEncryptedConnector {
trustlevel +1;
port
in int inputSub,
out int inputSub2;
}
connect subEncryptedConnector.inputSub2 -> targetHelp.inputTarget;
connect encrypted input -> subEncryptedConnector.inputSub;
}
\ No newline at end of file
package secarc.analysis.connector;
component ListEncryptedData {
accesscontrol off;
trustlevel +1;
port
in String input;
component Help help {
trustlevel +1;
}
component TargetHelp targetHelp {
trustlevel +1;
}
component SubEncryptedConnector {
trustlevel +1;
port
in String inputSub;
connect encrypted input -> inputSub;
}
}
\ No newline at end of file
package secarc.analysis.connector;
component UnencryptedPathThroughLowTrustlevel {
accesscontrol off;
trustlevel +0;
component Help help {
trustlevel +1;
}
component TargetHelp targetHelp {
cpe "1.2";
port in int inputTarget;
configuration conf_reviewed;
trustlevel +1;
}
component SubEncryptedConnector subEncryptedConnector {
trustlevel +1;
port
out int inputSub2;
}
connect subEncryptedConnector.inputSub2 -> targetHelp.inputTarget;
}
\ No newline at end of file
package secarc.analysis.criticalport;
component CriticalPort {
accesscontrol on;
trustlevel +1;
port
critical in String input;
identity weak help -> targetHelp;
component Help help {
port out int output;
trustlevel +1;
}
component TargetHelp targetHelp {
access user;
}
}
\ No newline at end of file
package secarc.analysis.filter;
component FilterComponent {
accesscontrol off;
trustlevel +1;
component Help help {
trustlevel +1;
}
component TargetHelp targetHelp {
port out int output;
trustlevel +2;
}
component (filter url) FilterURL filterURL {
trustlevel +1;
port in int input;
}
connect encrypted targetHelp.output -> filterURL.input;
}
\ No newline at end of file
package secarc.analysis.filter;
component FilterPort {
accesscontrol off;
trustlevel +1;
component Help help {
trustlevel +1;
port
out int output;
}
component TargetHelp targetHelp {
trustlevel +2;
port
(filter sql) in int input;
}
connect encrypted help.output -> targetHelp.input;
}
\ No newline at end of file
package secarc.analysis.filter;
component FilterWithLowerTrustlevel {
accesscontrol off;
trustlevel +1;
component Help help {
trustlevel +1;
}
component TargetHelp targetHelp {
port out int output;
trustlevel +2;
}
component (filter url) FilterURL filterURL {
port in int input;
}
connect encrypted targetHelp.output -> filterURL.input;
}
\ No newline at end of file
package secarc.analysis.filter;
component InputString {
accesscontrol off;
trustlevel +1;
port in String input;
}
\ No newline at end of file
package secarc.analysis.identity;
component IdentityWithEncryption {
accesscontrol on;
trustlevel +1;
component Help help {
trustlevel +1;
}
identity weak targetHelp -> subEncryptedConnector;
component TargetHelp targetHelp {
port out int inputTarget;
trustlevel +1;
}
component SubEncryptedConnector subEncryptedConnector {
trustlevel +2;
access user;
port
in int inputSub;
}
connect encrypted targetHelp.inputTarget -> subEncryptedConnector.inputSub;
}
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment