// File: alfanick[P]rest-cpp/src/rest/features/authorization.cpp
// Function: REST::Features::Authorization::feature_push()
void Authorization::feature_push() {
  std::string auth_header = request->header("Authorization", "");
  if (!auth_header.empty()) {
    if (auth_header.find("Basic") == 0) {
      std::string decoded = Utils::base64_decode(auth_header.substr(auth_header.find(" ")+1));
      size_t colon = decoded.find(":");
      authorization = std::make_pair(decoded.substr(0, colon), decoded.substr(colon+1));
    }
  }
}

// Assembly:
subq $0x158, %rsp            # imm = 0x158
movq %rdi, 0x150(%rsp)
movq 0x150(%rsp), %rax
movq %rax, 0x18(%rsp)
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
movq 0x10(%rax,%rcx), %rax
movq %rax, 0x20(%rsp)
leaq 0x10f(%rsp), %rdi
movq %rdi, 0x28(%rsp)
callq 0x98200
movq 0x28(%rsp), %rdx
leaq 0x11ad6(%rip), %rsi     # 0xe6081
leaq 0x110(%rsp), %rdi
callq 0x95700
jmp 0xd45ba
movq 0x20(%rsp), %rsi
leaq 0x1019e(%rip), %rcx     # 0xe4764
leaq 0x130(%rsp), %rdi
leaq 0x110(%rsp), %rdx
callq 0x984a0
jmp 0xd45dd
leaq 0x110(%rsp), %rdi
callq 0x99830
leaq 0x10f(%rsp), %rdi
callq 0x938a0
leaq 0x130(%rsp), %rdi
callq 0x977c0
testb $0x1, %al
jne 0xd483f
leaq 0x130(%rsp), %rdi
leaq 0x11a74(%rip), %rsi     # 0xe608f
xorl %eax, %eax
movl %eax, %edx
callq 0x995d0
cmpq $0x0, %rax
jne 0xd483d
leaq 0x10b0f(%rip), %rsi     # 0xe5144
xorl %eax, %eax
movl %eax, %edx
leaq 0x130(%rsp), %rdi
movq %rdi, 0x10(%rsp)
callq 0x995d0
movq 0x10(%rsp), %rsi
movq %rax, %rdx
incq %rdx
leaq 0xb8(%rsp), %rdi
movq $-0x1, %rcx
callq 0x93510
jmp 0xd466c
leaq 0xd8(%rsp), %rdi
leaq 0xb8(%rsp), %rsi
callq 0x997e0
jmp 0xd4683
leaq 0xb8(%rsp), %rdi
callq 0x99830
leaq 0x127e0(%rip), %rsi     # 0xe6e77
xorl %eax, %eax
movl %eax, %edx
movq %rdx, 0x8(%rsp)
leaq 0xd8(%rsp), %rdi
movq %rdi, (%rsp)
callq 0x995d0
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
movq %rax, 0xb0(%rsp)
movq 0xb0(%rsp), %rcx
leaq 0x50(%rsp), %rdi
callq 0x93510
jmp 0xd46d6
movq 0xb0(%rsp), %rdx
incq %rdx
leaq 0x30(%rsp), %rdi
leaq 0xd8(%rsp), %rsi
movq $-0x1, %rcx
callq 0x93510
jmp 0xd46fc
leaq 0x70(%rsp), %rdi
leaq 0x50(%rsp), %rsi
leaq 0x30(%rsp), %rdx
callq 0x92310
jmp 0xd4712
movq 0x18(%rsp), %rdi
addq $0x8, %rdi
leaq 0x70(%rsp), %rsi
callq 0x8ef80
leaq 0x70(%rsp), %rdi
callq 0x97020
leaq 0x30(%rsp), %rdi
callq 0x99830
leaq 0x50(%rsp), %rdi
callq 0x99830
leaq 0xd8(%rsp), %rdi
callq 0x99830
jmp 0xd483d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x100(%rsp)
movl %eax, 0xfc(%rsp)
jmp 0xd478c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x100(%rsp)
movl %eax, 0xfc(%rsp)
leaq 0x110(%rsp), %rdi
callq 0x99830
leaq 0x10f(%rsp), %rdi
callq 0x938a0
jmp 0xd4861
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x100(%rsp)
movl %eax, 0xfc(%rsp)
jmp 0xd4854
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x100(%rsp)
movl %eax, 0xfc(%rsp)
leaq 0xb8(%rsp), %rdi
callq 0x99830
jmp 0xd4854
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x100(%rsp)
movl %eax, 0xfc(%rsp)
jmp 0xd482e
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x100(%rsp)
movl %eax, 0xfc(%rsp)
jmp 0xd4824
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x100(%rsp)
movl %eax, 0xfc(%rsp)
leaq 0x30(%rsp), %rdi
callq 0x99830
leaq 0x50(%rsp), %rdi
callq 0x99830
leaq 0xd8(%rsp), %rdi
callq 0x99830
jmp 0xd4854
jmp 0xd483f
leaq 0x130(%rsp), %rdi
callq 0x99830
addq $0x158, %rsp            # imm = 0x158
retq
leaq 0x130(%rsp), %rdi
callq 0x99830
movq 0x100(%rsp), %rdi
callq 0x981c0
nop