mirror of
				https://git.code.sf.net/p/linux-ima/ima-evm-utils
				synced 2025-10-30 20:52:15 +01:00 
			
		
		
		
	evmctl: use the pkcs11 engine for pkcs11: prefixed URIs
If the key has the pkcs11: URI prefix then setup the pkcs11 engine if the user hasn't chosen a specific engine already. Signed-off-by: Stefan Berger <stefanb@linux.ibm.com> Signed-off-by: Mimi Zohar <zohar@linux.ibm.com>
This commit is contained in:
		 Stefan Berger
					Stefan Berger
				
			
				
					committed by
					
						 Mimi Zohar
						Mimi Zohar
					
				
			
			
				
	
			
			
			 Mimi Zohar
						Mimi Zohar
					
				
			
						parent
						
							1de1e3c8ce
						
					
				
				
					commit
					3b32acbc7d
				
			| @@ -2836,6 +2836,14 @@ int main(int argc, char *argv[]) | ||||
| 	if (!imaevm_params.keypass) | ||||
| 		imaevm_params.keypass = getenv("EVMCTL_KEY_PASSWORD"); | ||||
|  | ||||
| 	if (imaevm_params.keyfile != NULL && | ||||
| 	    imaevm_params.eng == NULL && | ||||
| 	    !strncmp(imaevm_params.keyfile, "pkcs11:", 7)) { | ||||
| 		imaevm_params.eng = setup_engine("pkcs11"); | ||||
| 		if (!imaevm_params.eng) | ||||
| 			goto error; | ||||
| 	} | ||||
|  | ||||
| 	if (argv[optind] == NULL) | ||||
| 		usage(); | ||||
| 	else | ||||
|   | ||||
		Reference in New Issue
	
	Block a user