OpenVPN / easy-rsa

easy-rsa - Simple shell based CA utility
Other
3.96k stars 1.18k forks source link

Introduce write_legacy_file_v2() #1165

Closed TinCanTech closed 1 month ago

TinCanTech commented 1 month ago

write_legacy_file_v2() takes explicit control of output redirection. This means that all required checks are completed before redirecting output to a file.

Input syntax:

"$type" is required.

"$file_name" is optional. When "$file_name" is not specified then output is sent to stdout.

'overwite' is optional. When 'overwite' is not specified then an existing file is preserved. When "$file_name" is a temp-file, in the session directory, then 'overwite' is enabled by default.