added t1 t2 and readme

This commit is contained in:
2020-05-17 12:16:22 +02:00
committed by GitHub
parent 77d02fc093
commit 778bbe1ff2
16 changed files with 117 additions and 0 deletions
+23
View File
@@ -0,0 +1,23 @@
# openSSL-DICE
Simulated implementation of DICE based on microsoft paper on dice n riot. initial implementation, later to be implemented on Jetson Xavior
Step 1 - skeletal setup
sketch roadmap of dataflow,
lable functions,
locate input and output DS,
find appropriate openssl fns,
Step 2 - codify
use static value for ids, eg UDS, FW,
Step 3 - replace static IDs with real values
use real values from device? use rng?
+8
View File
@@ -0,0 +1,8 @@
#include "fun1.h"
int fun1()
{
printf("Hello from FN1\n");
// fun2();
return 0;
}
+5
View File
@@ -0,0 +1,5 @@
#include <stdio.h>
int fun1();
+8
View File
@@ -0,0 +1,8 @@
#include "fun2.h"
int fun2()
{
printf("Hello from FN2\n");
return 0;
}
+1
View File
@@ -0,0 +1 @@
int fun2();
BIN
View File
Binary file not shown.
+9
View File
@@ -0,0 +1,9 @@
#include "fun1.h"
int main()
{
printf("Hello World\n");
fun1();
return 0;
}
+19
View File
@@ -0,0 +1,19 @@
CC=gcc
IDIR=./include
LDIR=./lib
ODIR=./out
_DEPS = fun1.h
DEPS = $(pathsbst %,(IDIR)/%,%(_DEPS))
CFLAGS= -I. -T$(IDIR)
.PHONY: all clean
all: main.c fun1.c
${CC} -o $(ODIR)/main2 main.c fun1.c
clean:
rm -r $(ODIR)/*
rm -r ./keys/*
BIN
View File
Binary file not shown.
+1
View File
@@ -0,0 +1 @@
void myPrintHelloMake(void);
+9
View File
@@ -0,0 +1,9 @@
#include <stdio.h>
#include <hellomake.h>
void myPrintHelloMake(void) {
printf("Hello makefiles!\n");
return;
}
Binary file not shown.
+8
View File
@@ -0,0 +1,8 @@
#include <hellomake.h>
int main() {
// call a function in another file
myPrintHelloMake();
return(0);
}
+26
View File
@@ -0,0 +1,26 @@
IDIR =../include
CC=gcc
CFLAGS=-I$(IDIR)
ODIR=obj
LDIR =../lib
LIBS=-lm
_DEPS = hellomake.h
DEPS = $(patsubst %,$(IDIR)/%,$(_DEPS))
_OBJ = hellomake.o hellofunc.o
OBJ = $(patsubst %,$(ODIR)/%,$(_OBJ))
$(ODIR)/%.o: %.c $(DEPS)
$(CC) -c -o $@ $< $(CFLAGS)
hellomake: $(OBJ)
$(CC) -o $@ $^ $(CFLAGS) $(LIBS)
.PHONY: clean
clean:
rm -f $(ODIR)/*.o *~ core $(INCDIR)/*~
Binary file not shown.
Binary file not shown.