// File: nurseiit[P]cpp-server/server.cpp
// Function: Headers::get_response[abi:cxx11]()
std::string get_response() {
    std::stringstream response_stream;

    FILE *fp;
    std::string path = url;

    if (path == "/") {
      path = "/index.html";
    }
    if (path.find("../") != -1) {
      path = "/403.html";
    }
    path = "./web" + path;

    if ((fp = fopen(path.c_str(), "rb")) == nullptr) {
      std::string content = "<html><body><h1>404 Not Found</h1></body></html>";
      response_stream << "HTTP/1.1 404 Not Found" << std::endl;
      response_stream << "content-type: text/html" << std::endl;
      response_stream << "content-length: " << content.length() << std::endl;
      response_stream << std::endl;
      response_stream << content;
    } else {
      std::stringstream content_stream;
      char buffer[6969];
      long n;

      while ((n = fread(buffer, 1, 6969, fp)) > 0)
        content_stream << buffer;
      fclose(fp);

      std::string content = content_stream.str();
      response_stream << "HTTP/1.1 200 OK" << std::endl;
      response_stream << "content-type: text/html" << std::endl;
      response_stream << "content-length: " << content.length() << std::endl;
      response_stream << std::endl;
      response_stream << content;
    }
    return response_stream.str();
  }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x1f90, %rsp           # imm = 0x1F90
movq %rdi, -0x1f20(%rbp)
movq %rdi, %rax
movq %rax, -0x1f18(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x1f10(%rbp)
leaq -0x198(%rbp), %rdi
callq 0x6330
movq -0x1f10(%rbp), %rsi
addq $0x20, %rsi
leaq -0x1c0(%rbp), %rdi
callq 0x6220
jmp 0x1a0c4
leaq 0x968c(%rip), %rsi      # 0x23757
leaq -0x1c0(%rbp), %rdi
callq 0x1c9a0
movb %al, -0x1f21(%rbp)
jmp 0x1a0df
movb -0x1f21(%rbp), %al
testb $0x1, %al
jne 0x1a0eb
jmp 0x1a130
leaq 0x9657(%rip), %rsi      # 0x23749
leaq -0x1c0(%rbp), %rdi
callq 0x6530
jmp 0x1a100
jmp 0x1a130
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x1c8(%rbp)
movl %eax, -0x1cc(%rbp)
jmp 0x1a567
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x1c8(%rbp)
movl %eax, -0x1cc(%rbp)
jmp 0x1a55b
leaq -0x1c0(%rbp), %rdi
leaq 0x9617(%rip), %rsi      # 0x23755
xorl %eax, %eax
movl %eax, %edx
callq 0x67e0
cmpq $-0x1, %rax
je 0x1a164
leaq 0x9605(%rip), %rsi      # 0x23759
leaq -0x1c0(%rbp), %rdi
callq 0x6530
jmp 0x1a162
jmp 0x1a164
leaq 0x95f8(%rip), %rsi      # 0x23763
leaq -0x1f0(%rbp), %rdi
leaq -0x1c0(%rbp), %rdx
callq 0x1c9d0
jmp 0x1a180
leaq -0x1c0(%rbp), %rdi
movq %rdi, -0x1f38(%rbp)
leaq -0x1f0(%rbp), %rsi
movq %rsi, -0x1f40(%rbp)
callq 0x64c0
movq -0x1f40(%rbp), %rdi
callq 0x62e0
movq -0x1f38(%rbp), %rdi
callq 0x6210
movq %rax, %rdi
leaq 0x95a6(%rip), %rsi      # 0x23769
callq 0x64a0
movq %rax, -0x1f30(%rbp)
jmp 0x1a1d1
movq -0x1f30(%rbp), %rax
movq %rax, -0x1a0(%rbp)
cmpq $0x0, %rax
jne 0x1a35c
leaq -0x211(%rbp), %rdi
movq %rdi, -0x1f48(%rbp)
callq 0x6730
movq -0x1f48(%rbp), %rdx
leaq 0x9562(%rip), %rsi      # 0x2376c
leaq -0x210(%rbp), %rdi
callq 0x6550
jmp 0x1a218
leaq -0x211(%rbp), %rdi
callq 0x6450
leaq -0x188(%rbp), %rdi
leaq 0x956b(%rip), %rsi      # 0x2379d
callq 0x6400
movq %rax, -0x1f50(%rbp)
jmp 0x1a240
movq -0x1f50(%rbp), %rdi
movq 0x1ad42(%rip), %rsi     # 0x34f90
callq 0x6440
jmp 0x1a255
leaq -0x188(%rbp), %rdi
leaq 0x9551(%rip), %rsi      # 0x237b4
callq 0x6400
movq %rax, -0x1f58(%rbp)
jmp 0x1a271
movq -0x1f58(%rbp), %rdi
movq 0x1ad11(%rip), %rsi     # 0x34f90
callq 0x6440
jmp 0x1a286
leaq -0x188(%rbp), %rdi
leaq 0x9538(%rip), %rsi      # 0x237cc
callq 0x6400
movq %rax, -0x1f60(%rbp)
jmp 0x1a2a2
leaq -0x210(%rbp), %rdi
callq 0x6620
movq -0x1f60(%rbp), %rdi
movq %rax, %rsi
callq 0x60f0
movq %rax, -0x1f68(%rbp)
jmp 0x1a2c6
movq -0x1f68(%rbp), %rdi
movq 0x1acbc(%rip), %rsi     # 0x34f90
callq 0x6440
jmp 0x1a2db
leaq -0x188(%rbp), %rdi
movq 0x1aca7(%rip), %rsi     # 0x34f90
callq 0x6440
jmp 0x1a2f0
leaq -0x188(%rbp), %rdi
leaq -0x210(%rbp), %rsi
callq 0x63c0
jmp 0x1a305
leaq -0x210(%rbp), %rdi
callq 0x62e0
jmp 0x1a51e
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x1c8(%rbp)
movl %eax, -0x1cc(%rbp)
leaq -0x211(%rbp), %rdi
callq 0x6450
jmp 0x1a55b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x1c8(%rbp)
movl %eax, -0x1cc(%rbp)
leaq -0x210(%rbp), %rdi
callq 0x62e0
jmp 0x1a55b
leaq -0x3a0(%rbp), %rdi
callq 0x6330
jmp 0x1a36a
jmp 0x1a36c
movq -0x1a0(%rbp), %rcx
leaq -0x1ee0(%rbp), %rdi
movl $0x1, %esi
movl $0x1b39, %edx           # imm = 0x1B39
callq 0x6610
movq %rax, -0x1f70(%rbp)
jmp 0x1a392
movq -0x1f70(%rbp), %rax
movq %rax, -0x1ee8(%rbp)
cmpq $0x0, %rax
jle 0x1a3d4
leaq -0x390(%rbp), %rdi
leaq -0x1ee0(%rbp), %rsi
callq 0x6400
jmp 0x1a3bb
jmp 0x1a36c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x1c8(%rbp)
movl %eax, -0x1cc(%rbp)
jmp 0x1a510
movq -0x1a0(%rbp), %rdi
callq 0x6410
jmp 0x1a3e2
leaq -0x1f08(%rbp), %rdi
leaq -0x3a0(%rbp), %rsi
callq 0x63f0
jmp 0x1a3f7
leaq -0x188(%rbp), %rdi
leaq 0x93d8(%rip), %rsi      # 0x237dd
callq 0x6400
movq %rax, -0x1f78(%rbp)
jmp 0x1a413
movq -0x1f78(%rbp), %rdi
movq 0x1ab6f(%rip), %rsi     # 0x34f90
callq 0x6440
jmp 0x1a428
leaq -0x188(%rbp), %rdi
leaq 0x937e(%rip), %rsi      # 0x237b4
callq 0x6400
movq %rax, -0x1f80(%rbp)
jmp 0x1a444
movq -0x1f80(%rbp), %rdi
movq 0x1ab3e(%rip), %rsi     # 0x34f90
callq 0x6440
jmp 0x1a459
leaq -0x188(%rbp), %rdi
leaq 0x9365(%rip), %rsi      # 0x237cc
callq 0x6400
movq %rax, -0x1f88(%rbp)
jmp 0x1a475
leaq -0x1f08(%rbp), %rdi
callq 0x6620
movq -0x1f88(%rbp), %rdi
movq %rax, %rsi
callq 0x60f0
movq %rax, -0x1f90(%rbp)
jmp 0x1a499
movq -0x1f90(%rbp), %rdi
movq 0x1aae9(%rip), %rsi     # 0x34f90
callq 0x6440
jmp 0x1a4ae
leaq -0x188(%rbp), %rdi
movq 0x1aad4(%rip), %rsi     # 0x34f90
callq 0x6440
jmp 0x1a4c3
leaq -0x188(%rbp), %rdi
leaq -0x1f08(%rbp), %rsi
callq 0x63c0
jmp 0x1a4d8
leaq -0x1f08(%rbp), %rdi
callq 0x62e0
leaq -0x3a0(%rbp), %rdi
callq 0x6350
jmp 0x1a51e
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x1c8(%rbp)
movl %eax, -0x1cc(%rbp)
leaq -0x1f08(%rbp), %rdi
callq 0x62e0
leaq -0x3a0(%rbp), %rdi
callq 0x6350
jmp 0x1a55b
movq -0x1f20(%rbp), %rdi
leaq -0x198(%rbp), %rsi
callq 0x63f0
jmp 0x1a533
leaq -0x1c0(%rbp), %rdi
callq 0x62e0
leaq -0x198(%rbp), %rdi
callq 0x6350
movq -0x1f18(%rbp), %rax
addq $0x1f90, %rsp           # imm = 0x1F90
popq %rbp
retq
leaq -0x1c0(%rbp), %rdi
callq 0x62e0
leaq -0x198(%rbp), %rdi
callq 0x6350
movq -0x1c8(%rbp), %rdi
callq 0x6700
nop