This makes a new custom security context with the given properties and runs the program in this context.