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

```asm
<ifconf>:
  endbr64
  push   %r12
  push   %rbp
  mov    %rdi,%rbp
  push   %rbx
  mov    %rsi,%rbx
  mov    %rdi,%rsi
  lea    D40(%rip),%rdi
  sub    $0x50,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x48(%rsp)
  xor    %eax,%eax
  call   <ssystem@plt>
  mov    %rbx,%rdx
  mov    %rbp,%rsi
  xor    %eax,%eax
  lea    D20(%rip),%rdi
  call   <ssystem@plt>
  movsbl (%rbx),%eax
  pxor   %xmm0,%xmm0
  movaps %xmm0,(%rsp)
  movaps %xmm0,0x10(%rsp)
  test   %al,%al
  je     L26
  cmp    $0x2f,%al
  je     L26
  lea    0x1(%rbx),%rcx
  xor    %r8d,%r8d
  xor    %edx,%edx
  xor    %esi,%esi
  jmp    L31
  nopw   0x0(%rax,%rax,1)
L27:
  lea    -0x30(%rax),%edx
  and    $0xdf,%eax
  movslq %esi,%rdi
  sub    $0x37,%eax
  cmp    $0x9,%edx
  cmovg  %eax,%edx
  mov    (%rsp,%rdi,4),%eax
  add    $0x1,%rcx
  shl    $0x4,%eax
  add    %edx,%eax
  xor    %edx,%edx
  mov    %eax,(%rsp,%rdi,4)
  movsbl -0x1(%rcx),%eax
  cmp    $0x2f,%al
  je     L51
L69:
  test   %al,%al
  je     L51
L31:
  cmp    $0x3a,%al
  jne    L27
  test   %edx,%edx
  cmovne %esi,%r8d
  add    $0x1,%esi
  cmp    $0x7,%esi
  jg     L51
  movsbl (%rcx),%eax
  add    $0x1,%rcx
  mov    $0x1,%edx
  cmp    $0x2f,%al
  jne    L69
  nopl   0x0(%rax,%rax,1)
L51:
  mov    $0x8,%edi
  sub    %esi,%edi
  test   %edi,%edi
  jle    L122
L147:
  lea    0x1c(%rsp),%rdx
  xor    %eax,%eax
  movslq %esi,%r9
  jmp    L61
  nopw   0x0(%rax,%rax,1)
L56:
  add    $0x1,%eax
  movl   $0x0,(%rdx)
  sub    $0x4,%rdx
  cmp    %edi,%eax
  jge    L122
L61:
  mov    %esi,%ecx
  sub    %eax,%ecx
  cmp    %ecx,%r8d
  jge    L56
  mov    -0x1c(%rdx,%r9,4),%ecx
  add    $0x1,%eax
  mov    %ecx,(%rdx)
  movl   $0x0,-0x1c(%rdx,%r9,4)
  sub    $0x4,%rdx
  cmp    %edi,%eax
  jl     L61
L122:
  mov    0x4(%rsp),%edx
  lea    0x20(%rsp),%r12
  mov    0x1c(%rsp),%r9d
  lea    D19(%rip),%rsi
  mov    0xc(%rsp),%r8d
  mov    0x8(%rsp),%ecx
  mov    %r12,%rdi
  and    $0xfefd,%edx
  call   <sprintf@plt>
  xor    %eax,%eax
  mov    %r12,%rdx
  mov    %rbp,%rsi
  lea    D6(%rip),%rdi
  call   <ssystem@plt>
  mov    0x48(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L100
  add    $0x50,%rsp
  mov    %rbp,%rsi
  lea    D48(%rip),%rdi
  xor    %eax,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  jmp    1080 <ssystem@plt>
L26:
  mov    $0x8,%edi
  xor    %r8d,%r8d
  xor    %esi,%esi
  jmp    L147
L100:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: disassemble_data
arguments: label: D40
data_type: string
name: disassemble_data
arguments: label: D20
data_type: string
name: disassemble_data
arguments: label: D19
data_type: string
name: disassemble_data
arguments: label: D6
data_type: string
name: disassemble_data
arguments: label: D48
data_type: string

tool: D40: ifconfig %s inet `hostname` up

tool: D20: ifconfig %s add %s

tool: D19: fe80::%x:%x:%x:%x

tool: D6: ifconfig %s add %s/64

tool: D48: ifconfig %s


assistant: ```c
void ifconf(char *tundev, char *ipaddr) {
  ssystem("ifconfig %s inet `hostname` up", tundev);
  ssystem("ifconfig %s add %s", tundev, ipaddr);
  {
    char lladdr[40];
    char c, *ptr = (char *)ipaddr;
    uint16_t digit, ai, a[8], cc, scc, i;
    for (ai = 0; ai < 8; ai++) {
      a[ai] = 0;
    }
    ai = 0;
    cc = scc = 0;
    while (c = *ptr++) {
      if (c == '/')
        break;
      if (c == ':') {
        if (cc)
          scc = ai;
        cc = 1;
        if (++ai > 7)
          break;
      } else {
        cc = 0;
        digit = c - '0';
        if (digit > 9)
          digit = 10 + (c & 0xdf) - 'A';
        a[ai] = (a[ai] << 4) + digit;
      }
    }
    cc = 8 - ai;
    for (i = 0; i < cc; i++) {
      if ((8 - i - cc) <= scc) {
        a[7 - i] = 0;
      } else {
        a[7 - i] = a[8 - i - cc];
        a[8 - i - cc] = 0;
      }
    }
    sprintf(lladdr, "fe80::%x:%x:%x:%x", a[1] & 0xfefd, a[2], a[3], a[7]);
    ssystem("ifconfig %s add %s/64", tundev, lladdr);
  }
  ssystem("ifconfig %s\n", tundev);
}
```