-----------------------------------------------------------------

[*] Initial strace run with jchroot on the command ./usr/lib/sftp-server to identify missing areas

[*] Emulating binary name: sftp-server in strace mode to identify missing areas (with jchroot)
[*] Emulator used: qemu-mipsel-static
[*] Chroot environment used: jchroot
[*] Using root directory: /logs/s115_usermode_emulator/firmware/unblob_extracted/firmware_extract/1568982-13971496.squashfs_v4_le_extract (1/1)
[*] Using CPU config: 

1 brk(NULL) = 0x40022d20
1 mmap2(NULL,8192,PROT_READ|PROT_WRITE,MAP_PRIVATE|MAP_ANONYMOUS,-1,0) = 0x3f7c7000
1 uname(0x3ff1d6e0) = 0
1 access("/etc/ld.so.preload",R_OK) = -1 errno=2 (No such file or directory)
1 openat(AT_FDCWD,"/etc/ld.so.cache",O_RDONLY|O_CLOEXEC) = -1 errno=2 (No such file or directory)
1 openat(AT_FDCWD,"/lib/tls/libgcc_s.so.1",O_RDONLY|O_CLOEXEC) = 3
1 read(3,0x3ff1d464,512) = 512
1 prctl(46,9,1072813156,512,1065377792,0) = 0
1 fstat64(3,0x3ff1d328) = 0
1 mmap2(NULL,144160,PROT_EXEC|PROT_READ,MAP_PRIVATE|MAP_DENYWRITE,3,0) = 0x3f7a3000
1 mprotect(0x3f7b6000,61440,PROT_NONE) = 0
1 mmap2(0x3f7c5000,8192,PROT_READ|PROT_WRITE,MAP_PRIVATE|MAP_DENYWRITE|MAP_FIXED,3,0x12) = 0x3f7c5000
1 mprotect(0x3ff1d000,4096,PROT_EXEC|PROT_READ|PROT_WRITE|PROT_GROWSDOWN) = 0
1 close(3) = 0
1 openat(AT_FDCWD,"/lib/tls/libc.so.6",O_RDONLY|O_CLOEXEC) = 3
1 read(3,0x3ff1d44c,512) = 512
1 prctl(46,13,1072813132,512,1065377792,0) = 0
1 _llseek(3,0,792,0x3ff1d208,SEEK_SET) = 0
1 read(3,0x3ff1d238,32) = 32
1 fstat64(3,0x3ff1d310) = 0
1 mmap2(NULL,1630336,PROT_EXEC|PROT_READ,MAP_PRIVATE|MAP_DENYWRITE,3,0) = 0x3f614000
1 mprotect(0x3f78a000,61440,PROT_NONE) = 0
1 mmap2(0x3f799000,28672,PROT_READ|PROT_WRITE,MAP_PRIVATE|MAP_DENYWRITE|MAP_FIXED,3,0x175) = 0x3f799000
1 mmap2(0x3f7a0000,8320,PROT_READ|PROT_WRITE,MAP_PRIVATE|MAP_ANONYMOUS|MAP_FIXED,-1,0) = 0x3f7a0000
1 close(3) = 0
1 set_thread_area(0x3f7cf770) = 0
1 mprotect(0x3f799000,16384,PROT_READ) = 0
1 mprotect(0x3f7c5000,4096,PROT_READ) = 0
1 mprotect(0x40021000,4096,PROT_READ) = 0
1 mprotect(0x3f7fd000,4096,PROT_READ) = 0
1 openat(AT_FDCWD,"/dev/null",O_RDWR|O_LARGEFILE) = 3
1 close(3) = 0
1 getuid() = 0
1 brk(NULL) = 0x40022d20
1 brk(0x40043d20) = 0x40043d20
1 brk(0x40044000) = 0x40044000
1 socket(PF_UNIX,SOCK_STREAM|SOCK_CLOEXEC|SOCK_NONBLOCK,IPPROTO_IP) = 3
1 connect(3,0x3ff1da00,110) = -1 errno=2 (No such file or directory)
1 close(3) = 0
1 socket(PF_UNIX,SOCK_STREAM|SOCK_CLOEXEC|SOCK_NONBLOCK,IPPROTO_IP) = 3
1 connect(3,0x3ff1db48,110) = -1 errno=2 (No such file or directory)
1 close(3) = 0
1 openat(AT_FDCWD,"/etc/nsswitch.conf",O_RDONLY|O_CLOEXEC) = 3
1 fstat64(3,0x3ff1db18) = 0
1 read(3,0x40023470,4096) = 185
1 read(3,0x40023470,4096) = 0
1 close(3) = 0
1 openat(AT_FDCWD,"/lib/tls/libnss_files.so.2",O_RDONLY|O_CLOEXEC) = -1 errno=2 (No such file or directory)
1 openat(AT_FDCWD,"/lib/libnss_files.so.2",O_RDONLY|O_CLOEXEC) = 3
1 read(3,0x3ff1d5f4,512) = 512
1 prctl(46,9,1072813556,512,1065377792,0) = 0
1 _llseek(3,0,648,0x3ff1d3a8,SEEK_SET) = 0
1 read(3,0x3ff1d3d8,32) = 32
1 fstat64(3,0x3ff1d4b8) = 0
1 mmap2(NULL,136032,PROT_EXEC|PROT_READ,MAP_PRIVATE|MAP_DENYWRITE,3,0) = 0x3f5f2000
1 mprotect(0x3f5fd000,61440,PROT_NONE) = 0
1 mmap2(0x3f60c000,8192,PROT_READ|PROT_WRITE,MAP_PRIVATE|MAP_DENYWRITE|MAP_FIXED,3,0xa) = 0x3f60c000
1 mmap2(0x3f60e000,21344,PROT_READ|PROT_WRITE,MAP_PRIVATE|MAP_ANONYMOUS|MAP_FIXED,-1,0) = 0x3f60e000
1 close(3) = 0
1 mprotect(0x3f60c000,4096,PROT_READ) = 0
1 openat(AT_FDCWD,"/etc/passwd",O_RDONLY|O_CLOEXEC) = 3
1 fstat64(3,0x3ff1daa0) = 0
1 read(3,0x40024840,4096) = 456
1 close(3) = 0
1 prctl(4,0,1073914528,1064961498,1073914528,0) = 0
1 _newselect([0],[],[],NULL) =  = 0x00000001 ([0],[],[],NULL)
1 read(0,0x3ff19dc4,16384) = 0
1 exit_group(0)

[*] Identification of missing filesytem areas.
[*] Found missing area: /etc/ld.so.cache
[*] Trying to identify this missing file: ld.so.cache
[*] Missing file /logs/s115_usermode_emulator/firmware/unblob_extracted/firmware_extract/1568982-13971496.squashfs_v4_le_extract/etc/ld.so.cache
[*] Found missing area: /lib/tls/libnss_files.so.2
[*] Trying to identify this missing file: libnss_files.so.2
[*] Possible matching file found: /logs/s115_usermode_emulator/firmware/unblob_extracted/firmware_extract/1568982-13971496.squashfs_v4_le_extract/lib/libnss_files.so.2
[*] Copy file /logs/s115_usermode_emulator/firmware/unblob_extracted/firmware_extract/1568982-13971496.squashfs_v4_le_extract/lib/libnss_files.so.2 to /logs/s115_usermode_emulator/firmware/unblob_extracted/firmware_extract/1568982-13971496.squashfs_v4_le_extract/lib/tls/

-----------------------------------------------------------------