.TH ARCHIVE_WRITE_SET_PASSPHRASE 3 "September 21, 2014" "" .SH NAME .ad l \fB\%archive_write_set_passphrase\fP, \fB\%archive_write_set_passphrase_callback\fP \- functions for writing encrypted archives .SH LIBRARY .ad l Streaming Archive Library (libarchive, -larchive) .SH SYNOPSIS .ad l \fB#include \fP .br \fIint\fP .br \fB\%archive_write_set_passphrase\fP(\fI\%struct\ archive\ *\fP, \fI\%const\ char\ *passphrase\fP); .br \fIint\fP .br \fB\%archive_write_set_passphrase_callback\fP(\fI\%struct\ archive\ *\fP, \fI\%void\ *client_data\fP, \fI\%archive_passphrase_callback\ *\fP); .SH DESCRIPTION .ad l .RS 5 .TP \fB\%archive_write_set_passphrase\fP() Set a passphrase for writing an encrypted archive. If \fIpassphrase\fP is .BR NULL or empty, this function will do nothing and \fBARCHIVE_FAILED\fP will be returned. Otherwise, \fBARCHIVE_OK\fP will be returned. .TP \fB\%archive_write_set_passphrase_callback\fP() Register a callback function that will be invoked to get a passphrase for encryption if the passphrase was not set by the \fB\%archive_write_set_passphrase\fP() function. .RE .SH SEE ALSO .ad l \fBtar\fP(1), \fBarchive_write\fP(3), \fBarchive_write_set_options\fP(3), \fBlibarchive\fP(3)