-
Notifications
You must be signed in to change notification settings - Fork 261
untrusted PAL sent PAL event #2667
Comments
Definitely: error checking ;) Please add and then check where exactly it's failing. |
I add the debug log, It can ensure that it's failed, when run to I also try to add the implementation of This confuses me,could you give me some advice? did I need change some code in the makefile ? |
Sorry, but I didn't understand your whole comment. Could you clean up/reword it? |
Why are you adding this Why do you use the PPML example? The PPML example is extremely big and complex. You should start with a small test, preferrably written in C. This would give you much better control of what the application and Graphene are doing. Finally, you probably want to debug with GDB. |
thanks for your reply @dimakuv I try to port the zlib to Pal for unzip the file, but it's not work. when I run to unzip code, it will raise error as follow:
is there any limits when add code to Pal ? or for my scene, did you have any suggestion for me ? have any other solution that could decrypt the zip file and unzip it before app running. |
No, no limits. As long as the added code is correct, Graphene happily works and doesn't throw exceptions.
Why are you trying to do this at the level of Graphene source code? Your scenario sounds like a change to TensorFlow scripts, not a change of internal Graphene workings. |
Ok, I will check my code again.
because we want to suitable for any apps which developed by any language and framework. |
You could achieve this in a less intrusive way. I would recommend the premain way: #2347. In this way, your tiny helper program does your "decrypt the zip file" logic and then |
Your solution is very excellent, I'll have a try to see if it fits my scene exactly. |
@dimakuv I take your suggestion to put the unzip logic to premain, and it worked well. |
Description of the problem
I want to add some code in function
int set_protected_files_key(const char* pf_key_hex)
for my special purpose.https://github.com/oscarlab/graphene/blob/851f7082dc995e509d36c4acfbd6dec1295f84cb/Pal/src/host/Linux-SGX/enclave_pf.c#L632
for test, I add a sample function in the
int set_protected_files_key(const char* pf_key_hex)
as followmy func
malloc2DArray(r,c)
define in a signle file namedtestmalloc.c
whith a head filetestmalloc.h
, I put the two file in the/Pal/src/host/Linux-SGX/protected-files
the source of testmalloc.c is as follow:
the source of testmalloc.h is as follow:
and also I change the Makefile to add the new source_flile
then a rebuild the grahene,and run the ppml , when run to my code , it case the error as follow:
did I miss something ?
The text was updated successfully, but these errors were encountered: