undefined4 NEAP_SetSecurity(int param_1,undefined1 param_2,void *param_3,size_t param_4)

{
  void *__dest;
  
  if (*(void **)(param_1 + 0x18) != (void *)0x0) {
    free(*(void **)(param_1 + 0x18));
  }
  *(undefined4 *)(param_1 + 0x18) = 0;
  *(undefined4 *)(param_1 + 0x1c) = 0;
  *(undefined1 *)(param_1 + 0x17) = 0;
  if ((param_3 != (void *)0x0) && (0 < (int)param_4)) {
    __dest = malloc(param_4)   //possible issue identified - semgrep
    *(void **)(param_1 + 0x18) = __dest;
    if (__dest == (void *)0x0) {
      return 0;
    }
    memcpy(__dest,param_3,param_4)   //possible issue identified - semgrep
    *(size_t *)(param_1 + 0x1c) = param_4;
    *(undefined1 *)(param_1 + 0x17) = param_2;
  }
  return 1;
}