1#! /usr/bin/env perl 2# Copyright 2015-2016 The OpenSSL Project Authors. All Rights Reserved. 3# 4# Licensed under the OpenSSL license (the "License"). You may not use 5# this file except in compliance with the License. You can obtain a copy 6# in the file LICENSE in the source distribution or at 7# https://www.openssl.org/source/license.html 8 9use strict; 10use warnings; 11use OpenSSL::Test; 12 13setup("test_ui"); 14 15plan tests => 1; 16 17note <<"EOF"; 18The best way to test the UI interface is currently by using an openssl 19command that uses password_callback. The only one that does this is 20'genrsa'. 21Since password_callback uses a UI method derived from UI_OpenSSL(), it 22ensures that one gets tested well enough as well. 23EOF 24 25my $outfile = "rsa_$$.pem"; 26ok(run(app(["openssl", "genrsa", "-passout", "pass:password", "-aes128", 27 "-out", $outfile])), 28 "Checking that genrsa with a password works properly"); 29 30unlink $outfile; 31