Password Event

Fired when a file is encrypted, and the file's password is incorrect.

Syntax

ANSI (Cross Platform)
virtual int FirePassword(ZipPasswordEventParams *e);
typedef struct {
int Index;
char *Password; int reserved; } ZipPasswordEventParams; Unicode (Windows) virtual INT FirePassword(ZipPasswordEventParams *e);
typedef struct {
INT Index;
LPWSTR Password; INT reserved; } ZipPasswordEventParams;
- (void)onPassword:(int)index :(NSString**)password;
#define EID_ZIP_PASSWORD 5

virtual INT IPWORKSZIP_CALL FirePassword(INT &iIndex, LPSTR &lpszPassword);

Remarks

This event is fired when the class attempts to uncompress an encrypted file and the decryption fails due to an invalid password. The file may be identified in the collection by the Index parameter.

Setting the Password parameter in this event will cause the class to attempt to decrypt and decompress the file again with the specified password.

If the Password parameter is an empty string when this event completes, an error will occur.

Copyright (c) 2022 /n software inc. - All rights reserved.
IPWorks ZIP 2020 C++ Edition - Version 20.0 [Build 8300]