Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
monticore
MontiSecArc
Commits
fc24c955
Commit
fc24c955
authored
Dec 19, 2014
by
Paff
Browse files
running exmaple
parents
b3f49dfc
2584b953
Changes
32
Hide whitespace changes
Inline
Side-by-side
montiSecArcAnalysis/src/test/resources/secarc/seccds/CashDeskSystem.secarc
View file @
fc24c955
...
...
@@ -11,7 +11,7 @@ import secarc.seccds.fe.Store;
component
CashDeskSystem
{
trustlevel
-
1
;
trustlevel
+
0
"interne Angreifer"
;
autoconnect
encrypted
port
;
autoinstantiate
on
;
...
...
@@ -20,18 +20,14 @@ component CashDeskSystem {
port
in
Event
newSale
,
in
Image
barcode
,
in
String
identifier
,
in
Event
endSale
,
out
ProductData
;
out
ProductData
outProductData
;
port
in
Event
cardPay
,
in
CardData
,
in
Integer
pin
,
out
Boolean
validation
;
port
out
Bill
;
component
CashDesk
cashDesk
[
encrypted
bdOut
->
bank
.
bankData
;
...
...
@@ -46,10 +42,8 @@ component CashDeskSystem {
connect
cashDesk
->
store
;
connect
cashDesk
.
outProductData
->
productData
;
connect
store
.
productData
->
cashDesk
.
inProductData
;
connect
cashDesk
.
outProductData
->
outProductData
;
connect
identifier
->
cashDesk
.
in
Identifier
;
connect
store
.
outProductData
->
cashDesk
.
in
ProductData
;
}
\ No newline at end of file
montiSecArcAnalysis/src/test/resources/secarc/seccds/fe/CashDesk.secarc
View file @
fc24c955
...
...
@@ -7,27 +7,26 @@ import java.awt.Image;
component
CashDesk
{
trustlevel
+
1
;
access
cashier
;
port
in
Event
newSale
,
in
Image
barcode
,
in
String
inIdentifier
,
out
String
outIdentifier
,
in
Event
endSale
,
in
ProductData
inProductData
,
in
PaymentAck
paymentAck
,
out
ProductData
outProductData
;
port
in
Event
cardPay
,
critical
in
CardData
,
critical
in
Integer
pin
,
critical
out
BankData
bdOut
,
in
CardData
,
in
Integer
pin
,
out
BankData
bdOut
,
in
PaymentAck
paIn
,
out
Boolean
validation
;
port
out
SaleInformation
,
out
Bill
;
out
SaleInformation
;
}
\ No newline at end of file
montiSecArcAnalysis/src/test/resources/secarc/seccds/fe/Store.secarc
View file @
fc24c955
...
...
@@ -16,9 +16,8 @@ component Store {
identity
weak
cashDesk
->
store
;
port
in
String
identifier
,
out
ProductData
,
out
PaymentAck
;
in
String
intIdentifier
,
out
ProductData
outProductData
;
port
in
SaleInformation
;
...
...
@@ -29,7 +28,7 @@ component Store {
cpe
"cpeName"
;
port
in
String
identifier
,
in
String
i
nI
dentifier
,
out
Identifier
;
}
...
...
montiSecArcFE/src/test/resources/secarc/cds/CashDeskSystem.secarc
View file @
fc24c955
...
...
@@ -16,9 +16,8 @@ component CashDeskSystem {
port
in
Event
newSale
,
in
Image
barcode
,
in
String
identifier
,
in
Event
endSale
,
out
ProductData
;
out
ProductData
outProductData
;
port
in
Event
cardPay
,
...
...
@@ -26,17 +25,11 @@ component CashDeskSystem {
in
Integer
pin
,
out
Boolean
validation
;
port
out
Bill
;
component
Store
{
port
in
String
inIdentifier
,
out
ProductData
outProductData
,
out
PaymentAck
;
port
in
SaleInformation
;
}
...
...
@@ -50,10 +43,8 @@ component CashDeskSystem {
connect
cashDesk
->
store
;
connect
cashDesk
.
outProductData
->
p
roductData
;
connect
cashDesk
.
outProductData
->
outP
roductData
;
connect
store
.
outProductData
->
cashDesk
.
inProductData
;
connect
identifier
->
cashDesk
.
inIdentifier
;
}
\ No newline at end of file
montiSecArcFE/src/test/resources/secarc/cds/fe/CashDesk.secarc
View file @
fc24c955
...
...
@@ -6,14 +6,14 @@ import java.awt.Image;
component
CashDesk
{
trustlevel
+
1
;
port
in
Event
newSale
,
in
Image
barcode
,
in
String
inIdentifier
,
out
String
outIdentifier
,
in
Event
endSale
,
in
ProductData
inProductData
,
in
PaymentAck
paymentAck
,
out
ProductData
outProductData
;
port
...
...
@@ -25,7 +25,6 @@ component CashDesk {
out
Boolean
validation
;
port
out
SaleInformation
,
out
Bill
;
out
SaleInformation
;
}
\ No newline at end of file
montiSecArcFE/src/test/resources/secarc/seccds/CashDeskSystem.secarc
View file @
fc24c955
...
...
@@ -11,27 +11,23 @@ import secarc.seccds.fe.Store;
component
CashDeskSystem
{
trustlevel
-
1
;
trustlevel
+
0
"interne Angreifer"
;
autoconnect
port
;
autoconnect
encrypted
port
;
autoinstantiate
on
;
accesscontrol
on
;
port
in
Event
newSale
,
in
Image
barcode
,
in
String
identifier
,
in
Event
endSale
,
out
ProductData
;
out
ProductData
outProductData
;
port
in
Event
cardPay
,
in
CardData
,
in
Integer
pin
,
out
Boolean
validation
;
port
out
Bill
;
component
CashDesk
cashDesk
[
encrypted
bdOut
->
bank
.
bankData
;
...
...
@@ -46,10 +42,8 @@ component CashDeskSystem {
connect
cashDesk
->
store
;
connect
cashDesk
.
outProductData
->
p
roductData
;
connect
cashDesk
.
outProductData
->
outP
roductData
;
connect
store
.
outProductData
->
cashDesk
.
inProductData
;
connect
identifier
->
cashDesk
.
inIdentifier
;
}
\ No newline at end of file
montiSecArcFE/src/test/resources/secarc/seccds/fe/CashDesk.secarc
View file @
fc24c955
...
...
@@ -13,11 +13,9 @@ component CashDesk {
port
in
Event
newSale
,
in
Image
barcode
,
in
String
inIdentifier
,
out
String
outIdentifier
,
in
Event
endSale
,
in
ProductData
inProductData
,
in
PaymentAck
paymentAck
,
out
ProductData
outProductData
;
port
...
...
@@ -29,7 +27,6 @@ component CashDesk {
out
Boolean
validation
;
port
out
SaleInformation
,
out
Bill
;
out
SaleInformation
;
}
\ No newline at end of file
montiSecArcFE/src/test/resources/secarc/seccds/fe/Store.secarc
View file @
fc24c955
...
...
@@ -17,8 +17,7 @@ component Store {
port
in
String
intIdentifier
,
out
ProductData
outProductData
,
out
PaymentAck
;
out
ProductData
outProductData
;
port
in
SaleInformation
;
...
...
montiSecArcGenerator/.project
0 → 100644
View file @
fc24c955
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>
secarc-example
</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>
org.eclipse.m2e.core.maven2Builder
</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>
org.eclipse.m2e.core.maven2Nature
</nature>
</natures>
</projectDescription>
montiSecArcGenerator/.settings/org.eclipse.core.resources.prefs
0 → 100644
View file @
fc24c955
eclipse.preferences.version=1
encoding/<project>=UTF-8
montiSecArcGenerator/generator/target/classes/cd/SQLCreate.ftl
0 → 100644
View file @
fc24c955
<#
if
op.callCalculator("demo.Constants")></#if>
<#
if
op.callCalculator("demo.TransformAssociations")></#if>
<#
list
ast.getCDClasses() as class>
create
table $
{
class
.getName
()}
(
<#if op.callCalculator("demo.Association", class) >
autoID INT NOT NULL PRIMARY KEY,
</#if>
<#list class.getCDAttributes() as attr>
$
{
attr
.printName
()}
$
{
op
.getValue
(
"constants"
)
.getType
(
attr
.printType
())}
<#if attr_has_next>,</#if>
</#list>
);
<#
if
op.callCalculator("demo.N2NAssociation", class)>
create
table $
{
class
.getName
()}
_$
{
op
.getValue
(
"otherClass"
)}
(
$
{
class
.getName
()}
INT NOT NULL,
$
{
op
.getValue
(
"otherClass"
)}
INT NOT NULL,
PRIMARY KEY ($
{
class
.getName
()}
, $
{
op
.getValue
(
"otherClass"
)}
)
);
</#
if
>
</#
list
>
\ No newline at end of file
montiSecArcGenerator/generator/target/classes/cd/SQLDelete.ftl
0 → 100644
View file @
fc24c955
<#
list
ast.getCDClasses() as class>
drop
table $
{
class
.getName
()}
;
<#
if
op.callCalculator("demo.N2NAssociation", class)>
drop
table $
{
class
.getName
()}
_$
{
op
.getValue
(
"otherClass"
)}
;
</#
if
>
</#
list
>
\ No newline at end of file
montiSecArcGenerator/generator/target/classes/cd/SQLMain.ftl
0 → 100644
View file @
fc24c955
<#--
Disable Java Comments-->
${
op
.setTracing
(
false
)}
${
op
.callTemplates
(
"cd.SQLCreate",
ast.printPackage() +".create",
"sql",
ast)
}
${
op
.callTemplates
(
"cd.SQLDelete",
ast.printPackage() +".delete",
"sql",
ast)
}
\ No newline at end of file
montiSecArcGenerator/generator/target/classes/demo/Association.class
0 → 100644
View file @
fc24c955
File added
montiSecArcGenerator/generator/target/classes/demo/Constants.class
0 → 100644
View file @
fc24c955
File added
montiSecArcGenerator/generator/target/classes/demo/N2NAssociation.class
0 → 100644
View file @
fc24c955
File added
montiSecArcGenerator/generator/target/classes/demo/TransformAssociations.class
0 → 100644
View file @
fc24c955
File added
montiSecArcGenerator/generator/target/generator-0.0.1-SNAPSHOT.jar
0 → 100644
View file @
fc24c955
File added
montiSecArcGenerator/generator/target/maven-archiver/pom.properties
0 → 100644
View file @
fc24c955
#Generated by Maven
#Tue Oct 28 16:40:43 CET 2014
version
=
0.0.1-SNAPSHOT
groupId
=
de.se_rwth.montisecarc
artifactId
=
generator
montiSecArcGenerator/generator/target/maven-status/maven-compiler-plugin/compile/default-compile/createdFiles.lst
0 → 100644
View file @
fc24c955
demo/TransformAssociations.class
demo/N2NAssociation.class
demo/Constants.class
demo/Association.class
Prev
1
2
Next
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment