Exploit databaseDownload repository ZIP
GH-1917e82ea4e17d91152ad921475048a4
automateforceai/cve-2018-0202
Sources for CVE-2018-0202
1 sourcePreferred order: Exploit-DB, Metasploit, then GitHub repositories by stars.
Repository files17
automateforceai/cve-2018-0202Revision 9964c381baf5
- ↑..Parent directory
- libclamunrar.map
- unrar.c
- unrar.h
- unrar15.c
- unrar15.h
- unrar20.c
- unrar20.h
- unrarcmd.c
- unrarcmd.h
- unrarfilter.c
- unrarfilter.h
- unrarhlp.c
- unrarhlp.h
- unrarppm.c
- unrarppm.h
- unrarvm.c
- unrarvm.h
Files from this repository share one source choice. Supporting files may cover other vulnerabilities.
clamav-0.99.3-fix/libclamunrar/unrarcmd.c
C · 1,367 bytes/*
* Extract RAR archives
*
* Copyright (C) 2005 [email protected]
*
* This code is based on the work of Alexander L. Roshal (C)
*
* The unRAR sources may be used in any software to handle RAR
* archives without limitations free of charge, but cannot be used
* to re-create the RAR compression algorithm, which is proprietary.
* Distribution of modified unRAR sources in separate form or as a
* part of other software is permitted, provided that it is clearly
* stated in the documentation and source comments that the code may
* not be used to develop a RAR (WinRAR) compatible archiver.
*/
#include <string.h>
#include <stdlib.h>
#include "libclamunrar/unrar.h"
#include "libclamunrar/unrarcmd.h"
void rar_cmd_array_init(rar_cmd_array_t *cmd_a)
{
cmd_a->array = NULL;
cmd_a->num_items = 0;
}
void rar_cmd_array_reset(rar_cmd_array_t *cmd_a)
{
if (!cmd_a) {
return;
}
if (cmd_a->array) {
free(cmd_a->array);
}
cmd_a->array = NULL;
cmd_a->num_items = 0;
}
int rar_cmd_array_add(rar_cmd_array_t *cmd_a, int num)
{
cmd_a->num_items += num;
cmd_a->array = (struct rarvm_prepared_command *) rar_realloc2(cmd_a->array,
cmd_a->num_items * sizeof(struct rarvm_prepared_command));
if (cmd_a->array == NULL) {
return FALSE;
}
memset(&cmd_a->array[cmd_a->num_items-1], 0, sizeof(struct rarvm_prepared_command));
return TRUE;
}