user: What is the c source code of the assembly code below?

```asm
<check_log_len>:
  endbr64
  push   %r13
  push   %r12
  mov    $0x80,%r12d
  push   %rbp
  mov    %rdi,%rbp
  push   %rbx
  mov    %esi,%ebx
  sub    %ebx,%r12d
  sub    $0x8,%rsp
  call   <strlen@plt>
  cmp    %r12d,%eax
  jg     L42
L49:
  add    $0x8,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  ret
  nopl   0x0(%rax)
L42:
  lea    D54(%rip),%r13
  mov    %r13,%rdi
  call   <strlen@plt>
  mov    %r13,%rsi
  mov    %rbp,%rdi
  mov    %eax,%edx
  call   <strncasecmp@plt>
  mov    %r12d,%edx
  lea    D29(%rip),%rsi
  test   %rax,%rax
  je     L64
  lea    D73(%rip),%r13
  mov    %r13,%rdi
  call   <strlen@plt>
  mov    %r13,%rsi
  mov    %rbp,%rdi
  mov    %eax,%edx
  call   <strncasecmp@plt>
  mov    %r12d,%edx
  lea    D2(%rip),%rsi
  test   %rax,%rax
  je     L64
  lea    D22(%rip),%r13
  mov    %r13,%rdi
  call   <strlen@plt>
  mov    %r13,%rsi
  mov    %rbp,%rdi
  mov    %eax,%edx
  call   <strncasecmp@plt>
  mov    %r12d,%edx
  lea    D0(%rip),%rsi
  test   %rax,%rax
  je     L64
  lea    D12(%rip),%r13
  mov    %r13,%rdi
  call   <strlen@plt>
  mov    %r13,%rsi
  mov    %rbp,%rdi
  mov    %eax,%edx
  call   <strncasecmp@plt>
  test   %rax,%rax
  je     L56
  lea    D76(%rip),%r13
  mov    %r13,%rdi
  call   <strlen@plt>
  mov    %r13,%rsi
  mov    %rbp,%rdi
  mov    %eax,%edx
  call   <strncasecmp@plt>
  test   %rax,%rax
  je     L56
  movslq %r12d,%r12
  movb   $0x0,0x0(%rbp,%r12,1)
  jmp    L49
  nopl   0x0(%rax)
L56:
  mov    %r12d,%edx
  lea    D20(%rip),%rsi
L64:
  add    $0x8,%rsp
  mov    %rbp,%rdi
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  jmp    1080 <cut_log@plt>
```

tool_calls: name: retrieve_data
arguments: data_label: D54
data_type: string
name: retrieve_data
arguments: data_label: D29
data_type: string
name: retrieve_data
arguments: data_label: D73
data_type: string
name: retrieve_data
arguments: data_label: D2
data_type: string
name: retrieve_data
arguments: data_label: D22
data_type: string
name: retrieve_data
arguments: data_label: D0
data_type: string
name: retrieve_data
arguments: data_label: D12
data_type: string
name: retrieve_data
arguments: data_label: D76
data_type: string
name: retrieve_data
arguments: data_label: D20
data_type: string

tool: D54: [Dynamic DNS]

tool: D29:  registration

tool: D73: [USB device attached]

tool: D2:  is attached to the router

tool: D22: [USB device detached]

tool: D0:  is detached from the router

tool: D12: [site allowed:

tool: D76: [site blocked:

tool: D20: ]

assistant: ```c
void check_log_len(char *msg, int time_len) {
  int log_len;
  int log_max_len;
  int log_max_size = 128;
  log_len = strlen(msg);
  log_max_len = log_max_size - time_len;
  if (log_len <= log_max_len)
    return;
  if (strncasecmp(msg, "[Dynamic DNS]", strlen("[Dynamic DNS]")) == 0) {
    cut_log(msg, " registration", log_max_len);
    return;
  }
  if (strncasecmp(msg, "[USB device attached]", strlen("[USB device attached]")) == 0) {
    cut_log(msg, " is attached to the router", log_max_len);
    return;
  }
  if (strncasecmp(msg, "[USB device detached]", strlen("[USB device detached]")) == 0) {
    cut_log(msg, " is detached from the router", log_max_len);
    return;
  }
  if ((strncasecmp(msg, "[site allowed:", strlen("[site allowed:")) == 0) || (strncasecmp(msg, "[site blocked:", strlen("[site blocked:")) == 0)) {
    cut_log(msg, "]", log_max_len);
    return;
  }
  msg[log_max_len] = '\0';
  return;
}
```