Open vahldiek opened 4 years ago
Some thoughts on this list, coming from January 2021 (after GSC rework):
This is not even true. GSC doesn't do anything about environment variables (which is a bug). in Graphene, there must be one of the following manifest options: loader.insecure__use_host_env = 1
or loader.env.[ENVIRON] = "[VALUE]" / loader.env_src_file = "file:file_with_serialized_envs"
(see https://graphene.readthedocs.io/en/latest/manifest-syntax.html#environment-variables). However, none of these options are specified in the GSC template manifest, check https://github.com/oscarlab/graphene/blob/master/Tools/gsc/templates/entrypoint.manifest.template.
This means that the final Graphenized Docker image created by GSC has no environment variables other than hard-coded LD_LIBRARY_PATH
and PATH
. So, currently this part is completely broken in GSC. We need to implement the above options, similar to how command-line arguments are treated (see https://graphene.readthedocs.io/en/latest/manifest-syntax.html#command-line-arguments). In particular, secure ENV variables should be extracted via inspecting the original Docker image.
GSC has a test/
subdir. It uses a Makefile that got really ugly and convoluted over the years: https://github.com/oscarlab/graphene/blob/master/Tools/gsc/test/Makefile. I suggest to remove this Makefile (and maybe also https://github.com/oscarlab/graphene/blob/master/Tools/gsc/Makefile) and instead do the same with a simple Python/bash script.
https://github.com/oscarlab/graphene/pull/2195 -- secure environment variables were added to GSC.
Does GSC support remote attestation? Can we convert gramine shielded container images to oci compliant and run using cri-o/containerd apart from docker?
Does GSC support remote attestation?
Yes, you can look at this pending PR on how it can be done: https://github.com/gramineproject/gsc/pull/11. At some point, we'll merge this PR as an example in GSC.
Can we convert gramine shielded container images to oci compliant and run using cri-o/containerd apart from docker?
There is no such tooling in GSC currently. Note that GSC itself creates a normal Docker image. So if there are some tools to make normal Docker images OCI compliant, then one can use such tools. (I'll be honest, I don't know much about the exact details of what "OCI compliant" means, so I may be wrong in my comment.)
and run using cri-o/containerd apart from docker?
FWIW, I've run GSC images using both runc
and kata-runtime
in k8s using containerd CRI.
Thats awesome, thanks
Is there a way, where can we use container images based out of image other than ubuntu as base image. I see limitation mentioned over here https://gramine.readthedocs.io/projects/gsc/en/latest/#dependency-on-ubuntu Here it says "GSC can simply be extended to support other distributions by providing a template for this distribution in templates/" Is there any example for this.
You can check this work in progress, for CentOS/RHEL support: https://github.com/gramineproject/gsc/pull/43
UPDATE:
Detect scripts as entrypoints and correctly change the entrypoint to the script interpreter
This was fixed some time ago with https://github.com/gramineproject/gramine/pull/722, and is available in Gramine v1.3.
Description of the problem
The first version of Graphene Shielded Containers (PR gramineproject/graphene#1430) is limited in scope and we've frozen the feature list. This issue lists limitations and possible future features, and should serve as a discussion forum for others to highlight which features are a priority.
Security issues:
--insecure-args
during build.Minor features:
build
arguments such asbuild_args
ornetwork_mode
in the configuration filedocker build parameter
docker_api.build(path='gsc-' + image, tag=gsc_image_name(image), nocache=True)
gsc build
into two commands,gsc build-graphene
andgsc build
.gsc build-graphene
is the first stage of currentgsc build
building a Graphene runtime Docker image. This is independent of the application image and can be generalized and does not require to be rebuild for every image.gsc build
depends on the previous commandgsc build-graphene
and copies the runtime over to the application image.gsc build-graphene
on dockerhub for supported Distributions (e.g. graphene:ubuntu18.04-sgx1.9)Major features: