intel / sgx-ra-sample

Other
178 stars 65 forks source link

sgx_ra_get_msg1 call fails: response code 417 #36

Closed agrawalprash closed 4 years ago

agrawalprash commented 4 years ago

Hi,

I'm trying to execute the run-server and run-client scripts for remote attestation. I copied the SPID, IAS_PRIMARY_SUBSCRIPTION_KEY and IAS_SECONDARY_SUBSCRIPTION_KEY from the API portal, and pointed IAS_REPORT_SIGNING_CA_FILE to the certificate file downloaded from here: https://software.intel.com/en-us/forums/intel-software-guard-extensions-intel-sgx/topic/814779#comment-1943218

I'm getting the following error on the server side:

prash@prash-OptiPlex-3050:~/sgx-ra-sample$ ./run-server -d
+++ IAS Primary Subscription Key set to '7bf8........................8c68'
+++ IAS Secondary Subscription Key set to 'ce66........................ea22'
+++ Using default CA bundle /etc/ssl/certs/ca-certificates.crt
Using default private key
+++ using private key:
Listening for connections on port 7777
Waiting for a client to connect...
Connection from 127.0.0.1
Waiting for msg0||msg1
protocol error reading msg0||msg1
error processing msg1
Waiting for a client to connect...

and the following error on the client side:

prash@prash-OptiPlex-3050:~/sgx-ra-sample$ ./run-client -v -d
[CEnclavePool /home/prash/linux-sgx/psw/urts/enclave.cpp:599] enter CEnclavePool constructor
[parse_dyn /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:176] dynamic tag = 10, ptr = 0
[parse_dyn /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:176] dynamic tag = 19, ptr = 31cf58
[parse_dyn /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:176] dynamic tag = 1b, ptr = 10
[parse_dyn /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:176] dynamic tag = 1a, ptr = 31cf68
[parse_dyn /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:176] dynamic tag = 1c, ptr = 58
[parse_dyn /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:176] dynamic tag = 6ffffef5, ptr = 278
[parse_dyn /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:176] dynamic tag = 5, ptr = 7e50
[parse_dyn /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:176] dynamic tag = 6, ptr = 1e98
[parse_dyn /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:176] dynamic tag = a, ptr = 4277
[parse_dyn /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:176] dynamic tag = b, ptr = 18
[parse_dyn /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:176] dynamic tag = 15, ptr = 0
[parse_dyn /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:176] dynamic tag = 3, ptr = 31df80
[parse_dyn /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:176] dynamic tag = 7, ptr = c0c8
[parse_dyn /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:176] dynamic tag = 8, ptr = 4368
[parse_dyn /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:176] dynamic tag = 9, ptr = 18
[parse_dyn /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:176] dynamic tag = 1e, ptr = a
[parse_dyn /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:176] dynamic tag = 6ffffffb, ptr = 8000001
[parse_dyn /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:176] dynamic tag = 6ffffff9, ptr = 2ce
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [0] : sh_addr = 0, sh_size = 0, sh_offset = 0, sh_name = 0
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [1] .interp: sh_addr = 238, sh_size = 1c, sh_offset = 238, sh_name = 1b
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [2] .note.gnu.build-id: sh_addr = 254, sh_size = 24, sh_offset = 254, sh_name = 23
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [3] .gnu.hash: sh_addr = 278, sh_size = 1c20, sh_offset = 278, sh_name = 36
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [4] .dynsym: sh_addr = 1e98, sh_size = 5fb8, sh_offset = 1e98, sh_name = 40
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [0] : sh_addr = 0, sh_size = 0, sh_offset = 0, sh_name = 0
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [1] .interp: sh_addr = 238, sh_size = 1c, sh_offset = 238, sh_name = 1b
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [2] .note.gnu.build-id: sh_addr = 254, sh_size = 24, sh_offset = 254, sh_name = 23
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [3] .gnu.hash: sh_addr = 278, sh_size = 1c20, sh_offset = 278, sh_name = 36
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [4] .dynsym: sh_addr = 1e98, sh_size = 5fb8, sh_offset = 1e98, sh_name = 40
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [5] .dynstr: sh_addr = 7e50, sh_size = 4277, sh_offset = 7e50, sh_name = 48
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [0] : sh_addr = 0, sh_size = 0, sh_offset = 0, sh_name = 0
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [1] .interp: sh_addr = 238, sh_size = 1c, sh_offset = 238, sh_name = 1b
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [2] .note.gnu.build-id: sh_addr = 254, sh_size = 24, sh_offset = 254, sh_name = 23
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [3] .gnu.hash: sh_addr = 278, sh_size = 1c20, sh_offset = 278, sh_name = 36
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [4] .dynsym: sh_addr = 1e98, sh_size = 5fb8, sh_offset = 1e98, sh_name = 40
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [5] .dynstr: sh_addr = 7e50, sh_size = 4277, sh_offset = 7e50, sh_name = 48
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [6] .rela.dyn: sh_addr = c0c8, sh_size = 4368, sh_offset = c0c8, sh_name = 50
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [0] : sh_addr = 0, sh_size = 0, sh_offset = 0, sh_name = 0
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [0] : sh_addr = 0, sh_size = 0, sh_offset = 0, sh_name = 0
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [1] .interp: sh_addr = 238, sh_size = 1c, sh_offset = 238, sh_name = 1b
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [2] .note.gnu.build-id: sh_addr = 254, sh_size = 24, sh_offset = 254, sh_name = 23
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [3] .gnu.hash: sh_addr = 278, sh_size = 1c20, sh_offset = 278, sh_name = 36
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [4] .dynsym: sh_addr = 1e98, sh_size = 5fb8, sh_offset = 1e98, sh_name = 40
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [5] .dynstr: sh_addr = 7e50, sh_size = 4277, sh_offset = 7e50, sh_name = 48
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [6] .rela.dyn: sh_addr = c0c8, sh_size = 4368, sh_offset = c0c8, sh_name = 50
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [7] .plt: sh_addr = 10430, sh_size = 10, sh_offset = 10430, sh_name = 5a
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [8] .plt.got: sh_addr = 10440, sh_size = 8, sh_offset = 10440, sh_name = 5f
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [9] .text: sh_addr = 10480, sh_size = ed6c0, sh_offset = 10480, sh_name = 68
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [10] .nipx: sh_addr = fdb40, sh_size = af9, sh_offset = fdb40, sh_name = 6e
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [11] .rodata: sh_addr = fe640, sh_size = 5580, sh_offset = fe640, sh_name = 74
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [12] .niprod: sh_addr = 103bc0, sh_size = 8c0, sh_offset = 103bc0, sh_name = 7c
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [13] .eh_frame_hdr: sh_addr = 104480, sh_size = 25dc, sh_offset = 104480, sh_name = 84
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [14] .eh_frame: sh_addr = 106a60, sh_size = 15c94, sh_offset = 106a60, sh_name = 92
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [15] .gcc_except_table: sh_addr = 11c6f4, sh_size = f9, sh_offset = 11c6f4, sh_name = 9c
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [16] .init_array: sh_addr = 31cf58, sh_size = 10, sh_offset = 11cf58, sh_name = ae
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [17] .fini_array: sh_addr = 31cf68, sh_size = 58, sh_offset = 11cf68, sh_name = ba
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [18] .data.rel.ro: sh_addr = 31cfc0, sh_size = e50, sh_offset = 11cfc0, sh_name = c6
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [19] .dynamic: sh_addr = 31de10, sh_size = 170, sh_offset = 11de10, sh_name = d3
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [20] .got: sh_addr = 31df80, sh_size = 78, sh_offset = 11df80, sh_name = 63
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [21] .data: sh_addr = 31e000, sh_size = 1da0, sh_offset = 11e000, sh_name = dc
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [22] .nipd: sh_addr = 31fda0, sh_size = 8, sh_offset = 11fda0, sh_name = e2
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [23] .bss: sh_addr = 31fdc0, sh_size = f0c0, sh_offset = 11fda8, sh_name = e8
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [24] .comment: sh_addr = 0, sh_size = 2b, sh_offset = 11fda8, sh_name = ed
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [25] .note.sgxmeta: sh_addr = 0, sh_size = 501c, sh_offset = 11fdd4, sh_name = f6
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [26] .debug_aranges: sh_addr = 0, sh_size = 3d80, sh_offset = 124df0, sh_name = 104
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [27] .debug_info: sh_addr = 0, sh_size = 4d43b, sh_offset = 128b70, sh_name = 113
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [28] .debug_abbrev: sh_addr = 0, sh_size = d608, sh_offset = 175fab, sh_name = 11f
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [29] .debug_line: sh_addr = 0, sh_size = 1463b, sh_offset = 1835b3, sh_name = 12d
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [30] .debug_str: sh_addr = 0, sh_size = cf27, sh_offset = 197bee, sh_name = 139
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [31] .debug_loc: sh_addr = 0, sh_size = 5816, sh_offset = 1a4b15, sh_name = 144
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [32] .debug_ranges: sh_addr = 0, sh_size = 3b20, sh_offset = 1aa32b, sh_name = 14f
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [33] .symtab: sh_addr = 0, sh_size = 14130, sh_offset = 1ade50, sh_name = 1
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [34] .strtab: sh_addr = 0, sh_size = c0b3, sh_offset = 1c1f80, sh_name = 9
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [35] .shstrtab: sh_addr = 0, sh_size = 15d, sh_offset = 1ce033, sh_name = 11
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [0] : sh_addr = 0, sh_size = 0, sh_offset = 0, sh_name = 0
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [1] .interp: sh_addr = 238, sh_size = 1c, sh_offset = 238, sh_name = 1b
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [2] .note.gnu.build-id: sh_addr = 254, sh_size = 24, sh_offset = 254, sh_name = 23
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [3] .gnu.hash: sh_addr = 278, sh_size = 1c20, sh_offset = 278, sh_name = 36
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [4] .dynsym: sh_addr = 1e98, sh_size = 5fb8, sh_offset = 1e98, sh_name = 40
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [5] .dynstr: sh_addr = 7e50, sh_size = 4277, sh_offset = 7e50, sh_name = 48
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [6] .rela.dyn: sh_addr = c0c8, sh_size = 4368, sh_offset = c0c8, sh_name = 50
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [7] .plt: sh_addr = 10430, sh_size = 10, sh_offset = 10430, sh_name = 5a
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [8] .plt.got: sh_addr = 10440, sh_size = 8, sh_offset = 10440, sh_name = 5f
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [9] .text: sh_addr = 10480, sh_size = ed6c0, sh_offset = 10480, sh_name = 68
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [10] .nipx: sh_addr = fdb40, sh_size = af9, sh_offset = fdb40, sh_name = 6e
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [11] .rodata: sh_addr = fe640, sh_size = 5580, sh_offset = fe640, sh_name = 74
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [12] .niprod: sh_addr = 103bc0, sh_size = 8c0, sh_offset = 103bc0, sh_name = 7c
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [13] .eh_frame_hdr: sh_addr = 104480, sh_size = 25dc, sh_offset = 104480, sh_name = 84
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [14] .eh_frame: sh_addr = 106a60, sh_size = 15c94, sh_offset = 106a60, sh_name = 92
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [15] .gcc_except_table: sh_addr = 11c6f4, sh_size = f9, sh_offset = 11c6f4, sh_name = 9c
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [16] .init_array: sh_addr = 31cf58, sh_size = 10, sh_offset = 11cf58, sh_name = ae
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [17] .fini_array: sh_addr = 31cf68, sh_size = 58, sh_offset = 11cf68, sh_name = ba
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [18] .data.rel.ro: sh_addr = 31cfc0, sh_size = e50, sh_offset = 11cfc0, sh_name = c6
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [19] .dynamic: sh_addr = 31de10, sh_size = 170, sh_offset = 11de10, sh_name = d3
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [20] .got: sh_addr = 31df80, sh_size = 78, sh_offset = 11df80, sh_name = 63
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [21] .data: sh_addr = 31e000, sh_size = 1da0, sh_offset = 11e000, sh_name = dc
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [22] .nipd: sh_addr = 31fda0, sh_size = 8, sh_offset = 11fda0, sh_name = e2
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [23] .bss: sh_addr = 31fdc0, sh_size = f0c0, sh_offset = 11fda8, sh_name = e8
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [24] .comment: sh_addr = 0, sh_size = 2b, sh_offset = 11fda8, sh_name = ed
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [25] .note.sgxmeta: sh_addr = 0, sh_size = 501c, sh_offset = 11fdd4, sh_name = f6
LOAD Section: 1
Flags = 0x0000000000000005
VAddr = 0x0000000000000000
Size  = 0x000000000011C7ED

LOAD Section: 2
Flags = 0x0000000000000006
VAddr = 0x000000000031CF58
Size  = 0x0000000000011F28

[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [0] : sh_addr = 0, sh_size = 0, sh_offset = 0, sh_name = 0
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [1] .interp: sh_addr = 238, sh_size = 1c, sh_offset = 238, sh_name = 1b
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [2] .note.gnu.build-id: sh_addr = 254, sh_size = 24, sh_offset = 254, sh_name = 23
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [3] .gnu.hash: sh_addr = 278, sh_size = 1c20, sh_offset = 278, sh_name = 36
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [4] .dynsym: sh_addr = 1e98, sh_size = 5fb8, sh_offset = 1e98, sh_name = 40
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [5] .dynstr: sh_addr = 7e50, sh_size = 4277, sh_offset = 7e50, sh_name = 48
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [6] .rela.dyn: sh_addr = c0c8, sh_size = 4368, sh_offset = c0c8, sh_name = 50
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [7] .plt: sh_addr = 10430, sh_size = 10, sh_offset = 10430, sh_name = 5a
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [8] .plt.got: sh_addr = 10440, sh_size = 8, sh_offset = 10440, sh_name = 5f
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [9] .text: sh_addr = 10480, sh_size = ed6c0, sh_offset = 10480, sh_name = 68
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [10] .nipx: sh_addr = fdb40, sh_size = af9, sh_offset = fdb40, sh_name = 6e
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [11] .rodata: sh_addr = fe640, sh_size = 5580, sh_offset = fe640, sh_name = 74
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [12] .niprod: sh_addr = 103bc0, sh_size = 8c0, sh_offset = 103bc0, sh_name = 7c
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [13] .eh_frame_hdr: sh_addr = 104480, sh_size = 25dc, sh_offset = 104480, sh_name = 84
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [14] .eh_frame: sh_addr = 106a60, sh_size = 15c94, sh_offset = 106a60, sh_name = 92
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [15] .gcc_except_table: sh_addr = 11c6f4, sh_size = f9, sh_offset = 11c6f4, sh_name = 9c
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [16] .init_array: sh_addr = 31cf58, sh_size = 10, sh_offset = 11cf58, sh_name = ae
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [17] .fini_array: sh_addr = 31cf68, sh_size = 58, sh_offset = 11cf68, sh_name = ba
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [18] .data.rel.ro: sh_addr = 31cfc0, sh_size = e50, sh_offset = 11cfc0, sh_name = c6
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [19] .dynamic: sh_addr = 31de10, sh_size = 170, sh_offset = 11de10, sh_name = d3
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [20] .got: sh_addr = 31df80, sh_size = 78, sh_offset = 11df80, sh_name = 63
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [21] .data: sh_addr = 31e000, sh_size = 1da0, sh_offset = 11e000, sh_name = dc
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [22] .nipd: sh_addr = 31fda0, sh_size = 8, sh_offset = 11fda0, sh_name = e2
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [23] .bss: sh_addr = 31fdc0, sh_size = f0c0, sh_offset = 11fda8, sh_name = e8
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [24] .comment: sh_addr = 0, sh_size = 2b, sh_offset = 11fda8, sh_name = ed
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [25] .note.sgxmeta: sh_addr = 0, sh_size = 501c, sh_offset = 11fdd4, sh_name = f6
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [26] .debug_aranges: sh_addr = 0, sh_size = 3d80, sh_offset = 124df0, sh_name = 104
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [27] .debug_info: sh_addr = 0, sh_size = 4d43b, sh_offset = 128b70, sh_name = 113
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [28] .debug_abbrev: sh_addr = 0, sh_size = d608, sh_offset = 175fab, sh_name = 11f
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [29] .debug_line: sh_addr = 0, sh_size = 1463b, sh_offset = 1835b3, sh_name = 12d
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [30] .debug_str: sh_addr = 0, sh_size = cf27, sh_offset = 197bee, sh_name = 139
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [31] .debug_loc: sh_addr = 0, sh_size = 5816, sh_offset = 1a4b15, sh_name = 144
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [32] .debug_ranges: sh_addr = 0, sh_size = 3b20, sh_offset = 1aa32b, sh_name = 14f
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [33] .symtab: sh_addr = 0, sh_size = 14130, sh_offset = 1ade50, sh_name = 1
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [34] .strtab: sh_addr = 0, sh_size = c0b3, sh_offset = 1c1f80, sh_name = 9
[get_section /home/prash/linux-sgx/psw/urts/parser/elfparser.cpp:83] section [35] .shstrtab: sh_addr = 0, sh_size = 15d, sh_offset = 1ce033, sh_name = 11
[enclave_create sgx_enclave_common.cpp:220]
 secs->attibutes.flags = 6, secs->attributes.xfrm = 7
[build_secs /home/prash/linux-sgx/psw/urts/loader.cpp:524] Enclave start addr. = 0x7fb7f8800000, Size = 0x800000, 8192 KB
[build_image /home/prash/linux-sgx/psw/urts/loader.cpp:567]
    Metadata Version = 0x0000000100000004
build_contexts, step = 0x0000000000000000
    Entry Id( 0) =    1, HEAP_MIN        , Page Count =     1, Attributes = 0x01, Flags = 0x0000000000000203, RVA = 0x000000000032F000 + 0x0000000000000000
    build_context
    Entry Id     =    1, HEAP_MIN        , Page Count =     1, Attributes = 0x01, Flags = 0x0000000000000203, RVA = 0x000000000032F000 -> RVA = 0x000000000032F000
build_contexts, step = 0x0000000000000000
    Entry Id( 0) =    2, HEAP_INIT       , Page Count =   255, Attributes = 0x11, Flags = 0x0000000000000203, RVA = 0x0000000000330000 + 0x0000000000000000
    build_context
    Entry Id     =    2, HEAP_INIT       , Page Count =   255, Attributes = 0x11, Flags = 0x0000000000000203, RVA = 0x0000000000330000 -> RVA = 0x0000000000330000
build_contexts, step = 0x0000000000000000
    Entry Id( 0) =   10, GUARD           , Page Count =    16, Attributes = 0x00, Flags = 0x0000000000000000, RVA = 0x000000000042F000 + 0x0000000000000000
    build_context
    Entry Id     =   10, GUARD           , Page Count =    16, Attributes = 0x00, Flags = 0x0000000000000000, RVA = 0x000000000042F000 -> RVA = 0x000000000042F000
build_contexts, step = 0x0000000000000000
    Entry Id( 0) =    7, STACK_MAX       , Page Count =    62, Attributes = 0x53, Flags = 0x0000000000000203, RVA = 0x000000000043F000 + 0x0000000000000000
    build_context
    Entry Id     =    7, STACK_MAX       , Page Count =    62, Attributes = 0x53, Flags = 0x0000000000000203, RVA = 0x000000000043F000 -> RVA = 0x000000000043F000
build_contexts, step = 0x0000000000000000
    Entry Id( 0) =    8, STACK_MIN       , Page Count =     2, Attributes = 0x03, Flags = 0x0000000000000203, RVA = 0x000000000047D000 + 0x0000000000000000
    build_context
    Entry Id     =    8, STACK_MIN       , Page Count =     2, Attributes = 0x03, Flags = 0x0000000000000203, RVA = 0x000000000047D000 -> RVA = 0x000000000047D000
build_contexts, step = 0x0000000000000000
    Entry Id( 0) =   10, GUARD           , Page Count =    16, Attributes = 0x00, Flags = 0x0000000000000000, RVA = 0x000000000047F000 + 0x0000000000000000
    build_context
    Entry Id     =   10, GUARD           , Page Count =    16, Attributes = 0x00, Flags = 0x0000000000000000, RVA = 0x000000000047F000 -> RVA = 0x000000000047F000
build_contexts, step = 0x0000000000000000
    Entry Id( 0) =    4, TCS             , Page Count =     1, Attributes = 0x03, Flags = 0x0000000000000100, RVA = 0x000000000048F000 + 0x0000000000000000
    build_context
    Entry Id     =    4, TCS             , Page Count =     1, Attributes = 0x03, Flags = 0x0000000000000100, RVA = 0x000000000048F000 -> RVA = 0x000000000048F000
build_contexts, step = 0x0000000000000000
    Entry Id( 0) =    6, SSA             , Page Count =     2, Attributes = 0x03, Flags = 0x0000000000000203, RVA = 0x0000000000490000 + 0x0000000000000000
    build_context
    Entry Id     =    6, SSA             , Page Count =     2, Attributes = 0x03, Flags = 0x0000000000000203, RVA = 0x0000000000490000 -> RVA = 0x0000000000490000
build_contexts, step = 0x0000000000000000
    Entry Id( 0) =   10, GUARD           , Page Count =    16, Attributes = 0x00, Flags = 0x0000000000000000, RVA = 0x0000000000492000 + 0x0000000000000000
    build_context
    Entry Id     =   10, GUARD           , Page Count =    16, Attributes = 0x00, Flags = 0x0000000000000000, RVA = 0x0000000000492000 -> RVA = 0x0000000000492000
build_contexts, step = 0x0000000000000000
    Entry Id( 0) =    5, TD              , Page Count =     1, Attributes = 0x03, Flags = 0x0000000000000203, RVA = 0x00000000004A2000 + 0x0000000000000000
    build_context
    Entry Id     =    5, TD              , Page Count =     1, Attributes = 0x03, Flags = 0x0000000000000203, RVA = 0x00000000004A2000 -> RVA = 0x00000000004A2000
build_contexts, step = 0x0000000000000000
    Entry Id( 0) = 4105, THREAD_GROUP    , Entry Count =    8, Load Times = 0,    LStep = 0x0000000000074000
[reg_sig_handler sig_handler.cpp:189] signal handler is registered
[__create_enclave /home/prash/linux-sgx/psw/urts/urts_com.h:332] add tcs 0x7fb7f8c8f000
[__create_enclave /home/prash/linux-sgx/psw/urts/urts_com.h:342] Debug enclave. Checking if VTune is profiling or SGX_DBG_OPTIN is set
[__create_enclave /home/prash/linux-sgx/psw/urts/urts_com.h:388] VTune is not profiling and SGX_DBG_OPTIN is not set. TCS Debug OPTIN bit not set and API to do module mapping not invoked
+++ using default public key

---- Msg0 Details ----------------------------------------------------------
Extended Epid Group ID: 00000000
----------------------------------------------------------------------------
sgx_ra_get_msg1: 00000001

Digging deeper, I see the following error in the aesmd logs at /var/opt/aesmd/data/internal_log.txt:

[/home/prash/linux-sgx/psw/ae/aesm_service/source/core/AESMLogicWrapper.cpp|720|service_start|Mon Dec 23 11:09:47 2019]aesm service started
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/le_launch_service_bundle/le_launch_service_bundle.cpp|184|get_launch_token|Mon Dec 23 11:10:15 2019]enter function
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/le_launch_service_bundle/LEClass.cpp|429|get_launch_token_internal|Mon Dec 23 11:10:15 2019]try to load Enclave with mrsigner:BD 71 C6 38 0E F7 7C 54 17 E8 B2 D1 CE 2D 4B 65 04 B9 F4 18 E5 04 93 42 44 0C FF F2 44 3D 95 BD , attr 6, xfrm 7
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/le_launch_service_bundle/LEClass.cpp|455|get_launch_token_internal|Mon Dec 23 11:10:15 2019]token request returned with ret = 0, status = 0
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/epid_quote_service_bundle/epid_quote_service_bundle.cpp|326|get_extended_epid_group_id|Mon Dec 23 11:10:15 2019]get_extended_epid_group
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/epid_quote_service_bundle/epid_quote_service_bundle.cpp|244|init_quote|Mon Dec 23 11:10:15 2019]init_quote
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/epid_quote_service_bundle/qe_logic.cpp|101|init_quote|Mon Dec 23 11:10:15 2019]enter fun
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/epid_quote_service_bundle/qe_logic.cpp|115|init_quote|Mon Dec 23 11:10:15 2019]start read and verify old epid blob
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/epid_quote_service_bundle/pve_logic.cpp|341|provision|Mon Dec 23 11:10:15 2019]enter fun
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/epid_quote_service_bundle/pve_logic.cpp|342|provision|Mon Dec 23 11:10:15 2019]start end point selection
[/home/prash/linux-sgx/psw/ae/aesm_service/source/utils/aesm_long_lived_thread.cpp|83|find_or_insert_iocache|Mon Dec 23 11:10:15 2019]cache size 0
[/home/prash/linux-sgx/psw/ae/aesm_service/source/utils/aesm_long_lived_thread.cpp|136|find_or_insert_iocache|Mon Dec 23 11:10:15 2019]successfully add ioc 0x7f0b5c003f20 (status=1,timeout=0) into thread 0x7f0b67dafbc0
[/home/prash/linux-sgx/psw/ae/aesm_service/source/oal/linux/aesm_thread.cpp|131|aesm_create_thread|Mon Dec 23 11:10:15 2019]start to create a thread
[/home/prash/linux-sgx/psw/ae/aesm_service/source/oal/linux/aesm_thread.cpp|167|aesm_create_thread|Mon Dec 23 11:10:15 2019]thread 0x7f0b5c001dc0 created successfully
[/home/prash/linux-sgx/psw/ae/aesm_service/source/utils/aesm_long_lived_thread.cpp|275|set_thread_start|Mon Dec 23 11:10:15 2019]succ create thread 0x7f0b67dafbc0 for ioc 0x7f0b5c003f20
[/home/prash/linux-sgx/psw/ae/aesm_service/source/utils/aesm_long_lived_thread.cpp|302|set_thread_start|Mon Dec 23 11:10:15 2019]timeout:5000,timediff: 4999.929142
[/home/prash/linux-sgx/psw/ae/aesm_service/source/oal/linux/aesm_thread.cpp|84|aesm_thread_proc|Mon Dec 23 11:10:15 2019]start running thread 0x7f0b5c001dc0...
[/home/prash/linux-sgx/psw/ae/aesm_service/source/oal/linux/aesm_thread.cpp|95|aesm_thread_proc|Mon Dec 23 11:10:15 2019]thread parameters of thread 0x7f0b5c001dc0 copied
[/home/prash/linux-sgx/psw/ae/aesm_service/source/oal/linux/aesm_thread.cpp|259|aesm_wait_thread|Mon Dec 23 11:10:15 2019]start to wait thread 0x7f0b5c001dc0 for 4999 ms
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/epid_quote_service_bundle/pve_logic.cpp|399|epid_provision_thread_func|Mon Dec 23 11:10:15 2019]start end point selection
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/epid_quote_service_bundle/endpoint_select_info.cpp|254|start_protocol|Mon Dec 23 11:10:15 2019]enter fun
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/epid_quote_service_bundle/endpoint_select_info.cpp|139|get_url_info|Mon Dec 23 11:10:15 2019]server url blob file not available in persistent storage
[/home/prash/linux-sgx/psw/ae/aesm_service/source/common/AEClass.h|108|load_enclave|Mon Dec 23 11:10:15 2019]loading enclave 2
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/le_launch_service_bundle/le_launch_service_bundle.cpp|252|get_launch_token|Mon Dec 23 11:10:15 2019]enter function
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/le_launch_service_bundle/LEClass.cpp|429|get_launch_token_internal|Mon Dec 23 11:10:15 2019]try to load Enclave with mrsigner:EC 15 B1 07 87 D2 F8 46 67 CE B0 B5 98 FF C4 4A 1F 1C B8 0F 67 0A AE 5D F9 E8 FA 9F 63 76 E1 F8 , attr 14, xfrm 7
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/le_launch_service_bundle/LEClass.cpp|455|get_launch_token_internal|Mon Dec 23 11:10:15 2019]token request returned with ret = 0, status = 0
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/le_launch_service_bundle/le_launch_service_bundle.cpp|68|set_psvn|Mon Dec 23 11:10:15 2019]get QE or PvE isv_svn=10
[/home/prash/linux-sgx/psw/ae/aesm_service/source/common/AEClass.h|136|load_enclave|Mon Dec 23 11:10:15 2019]enclave 2 loaded with id 0X5
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/epid_quote_service_bundle/endpoint_select_info.cpp|283|start_protocol|Mon Dec 23 11:10:15 2019]use parition 142 from PvE
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/epid_quote_service_bundle/endpoint_select_info.cpp|285|start_protocol|Mon Dec 23 11:10:15 2019]Connect to server url "http://ps.sgx.trustedservices.intel.com/" for endpoint selection
[/home/prash/linux-sgx/psw/ae/aesm_service/source/utils/type_length_value.cpp|514|add_es_selector|Mon Dec 23 11:10:15 2019]create TLV: type (TLV:TLV_ES_SELECTOR:17), size 2, version 1, payload 00 8E
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/epid_quote_service_bundle/endpoint_select_info.cpp|302|start_protocol|Mon Dec 23 11:10:15 2019]ES msg1 generated
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/linux_network_service_bundle/linux_network_service_bundle.cpp|142|aesm_send_recv_msg_encoding|Mon Dec 23 11:10:15 2019]send msg  to url http://ps.sgx.trustedservices.intel.com/
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/linux_network_service_bundle/linux_network_service_bundle.cpp|47|aesm_send_recv_msg_encoding_internal|Mon Dec 23 11:10:15 2019]send msg "02 02 BE D3 29 08 A2 85 62 05 00 00 00 00 06 11 01 00 02 00 8E" to server:http://ps.sgx.trustedservices.intel.com/
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/linux_network_service_bundle/linux_network_service_bundle.cpp|55|aesm_send_recv_msg_encoding_internal|Mon Dec 23 11:10:15 2019]encoded msg 0202BED32908A28562050000000006EQEAAgCO
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/linux_network_service_bundle/aesm_http_msg.cpp|101|http_network_init|Mon Dec 23 11:10:15 2019]http init for url http://ps.sgx.trustedservices.intel.com/
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/linux_network_service_bundle/aesm_http_msg.cpp|129|http_network_init|Mon Dec 23 11:10:15 2019]use manual proxy http://10.10.78.61:3128
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/linux_network_service_bundle/aesm_http_msg.cpp|137|http_network_send_data|Mon Dec 23 11:10:15 2019]send data method=1
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/linux_network_service_bundle/aesm_http_msg.cpp|237|http_network_send_data|Mon Dec 23 11:10:16 2019]get response size=0
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/linux_network_service_bundle/linux_network_service_bundle.cpp|63|aesm_send_recv_msg_encoding_internal|Mon Dec 23 11:10:16 2019]recv NULL message from backend server
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/epid_quote_service_bundle/endpoint_select_info.cpp|311|start_protocol|Mon Dec 23 11:10:16 2019]fail to send ES msg1 to backend server:1
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/epid_quote_service_bundle/endpoint_select_info.cpp|75|read_pek|Mon Dec 23 11:10:16 2019]Read ES result from persistent storage successfully
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/epid_quote_service_bundle/pve_logic.cpp|411|epid_provision_thread_func|Mon Dec 23 11:10:16 2019]estimate msg1 size :859
[/home/prash/linux-sgx/psw/ae/aesm_service/source/utils/type_length_value.cpp|419|add_block_cipher_info|Mon Dec 23 11:10:16 2019]create TLV: type (TLV:TLV_BLOCK_CIPHER_INFO:2), size 16, version 1, payload 8C 70 F1 64 87 72 89 88 C3 A7 E3 4A CF DC 75 08
[/home/prash/linux-sgx/psw/ae/aesm_service/source/utils/type_length_value.cpp|519|add_psid|Mon Dec 23 11:10:16 2019]create TLV: type (TLV:TLV_PS_ID:9), size 32, version 1, payload DB 1D 19 0A F8 65 BC 2A 69 F5 2A D2 F7 20 22 D7 F8 11 47 85 19 18 AE 24 DE A7 A7 35 CD A0 4F 55
[/home/prash/linux-sgx/psw/ae/aesm_service/source/utils/type_length_value.cpp|354|add_cipher_text|Mon Dec 23 11:10:16 2019]create TLV: type (TLV:TLV_CIPHER_TEXT:0), size 385, version 1, payload 03 20 5A CE 9B CE 9E A5 27 97 1F 9A B9 8B AC 5F E8 41 E3 7C 94 F4 4B 0B A8 78 94 26 5C DF 08 F5 C7 75 2A B3 F2 D4 43 A5 05 66 ...AD CD E3 7F F9 9D 56 33 CB A6 51 F5 15 34 53 1A 3D 5C 86 BB D7 2A E1 F8 57 D9 97 48 93 74 07 17 A5 0C 33 AD A5 F2 89 87 3D 58
[/home/prash/linux-sgx/psw/ae/aesm_service/source/utils/type_length_value.cpp|354|add_cipher_text|Mon Dec 23 11:10:16 2019]create TLV: type (TLV:TLV_CIPHER_TEXT:0), size 385, version 1, payload 03 0A BB 71 36 E7 79 74 ED E6 43 66 F8 87 F4 8C 39 F8 E3 BD 72 51 D5 8D 75 58 97 EB 43 41 79 F4 D3 17 17 79 88 35 4F 6C 5E BA ...7E CC DF E5 42 69 CB 8C DC 45 5C 9C 8F CD 20 3C 0D 61 53 54 A3 38 8B F3 5E 10 81 5F F5 6F 0B 3B C9 03 7E 19 97 C6 95 18 F0 BB
[/home/prash/linux-sgx/psw/ae/aesm_service/source/utils/type_length_value.cpp|524|add_platform_info|Mon Dec 23 11:10:16 2019]create TLV: type (TLV:TLV_PLATFORM_INFO:24), size 26, version 1, payload 04 0E FF 04 01 02 00 00 00 00 00 00 00 00 00 00 0A 00 09 00 00 00 00 00 00 00
[/home/prash/linux-sgx/psw/ae/aesm_service/source/utils/type_length_value.cpp|390|add_block_cipher_text|Mon Dec 23 11:10:16 2019]create TLV: type (TLV:TLV_BLOCK_CIPHER_TEXT:1), size 431, version 1, payload C9 A9 B6 70 9B B4 6F 7B CD 58 23 01 62 0C BB 7F 77 D5 E6 78 07 91 BE A0 C8 1C 25 19 D1 AB 8B F0 7D B6 81 2A A8 B2 65 9C CD F6 ...1B C3 D2 AE D7 3F 95 BF A5 3B E0 29 85 5D 59 2D 3E 43 19 B9 1D 55 7B 36 A4 BC 79 04 13 E2 F9 30 25 44 E0 E9 37 B4 52 65 81 AC
[/home/prash/linux-sgx/psw/ae/aesm_service/source/utils/type_length_value.cpp|453|add_mac|Mon Dec 23 11:10:16 2019]create TLV: type (TLV:TLV_MESSAGE_AUTHENTICATION_CODE:3), size 16, version 1, payload F3 EF D2 3A 8C 4B 88 FA 68 7C A7 44 CA AA A0 66
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/epid_quote_service_bundle/pve_logic.cpp|438|epid_provision_thread_func|Mon Dec 23 11:10:16 2019]msg1 generated with size 859
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/epid_quote_service_bundle/pve_logic.cpp|444|epid_provision_thread_func|Mon Dec 23 11:10:16 2019]start to send prov msg1 and recv response
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/linux_network_service_bundle/linux_network_service_bundle.cpp|142|aesm_send_recv_msg_encoding|Mon Dec 23 11:10:16 2019]send msg  to url http://ps.sgx.trustedservices.intel.com:80
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/linux_network_service_bundle/linux_network_service_bundle.cpp|47|aesm_send_recv_msg_encoding_internal|Mon Dec 23 11:10:16 2019]send msg "00 02 9B 62 05 D2 71 C0 80 F8 00 00 00 03 4C 00 01 01 81 03 20 5A CE 9B CE 9E A5 27 97 1F 9A B9 8B AC 5F E8 41 E3 7C 94 F4 4B ...1D 55 7B 36 A4 BC 79 04 13 E2 F9 30 25 44 E0 E9 37 B4 52 65 81 AC 03 01 00 10 F3 EF D2 3A 8C 4B 88 FA 68 7C A7 44 CA AA A0 66" to server:http://ps.sgx.trustedservices.intel.com:80
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/linux_network_service_bundle/linux_network_service_bundle.cpp|55|aesm_send_recv_msg_encoding_internal|Mon Dec 23 11:10:16 2019]encoded msg 00029B6205D271C080F8000000034CAAEBgQMgWs6bzp6lJ5cfmrmLrF/oQeN8lPRLC6h4lCZc3wj1x3Uqs/LUQ6UFZhSW0ELJri/5kuhMvSz5RlCloQkclvBnmpvzJqCtAkIOQ0UPwVQLMYyIeBsKYH6USIH+WMYKFTzWaDSnIrLB0keFWJ6Uq7hgZwEQ9N27F1rGkGN6wHLBeK2UScWj6LhJSk1CjIjtpc4emjltAMSyjALnrI47XyHbAyao3QP0VMWylmjRt+t2gHzi0ZUgkm98H9TptrP/FbrnN4PEBpC05GqFPZuUclgg2uSX7X3V0/2rG6EYyOPlVGnP8DzoF/a0OpWtNKQNstchwQWHG+fQrLqYKwbYOM6mQRccbTcpQVvwucoLklfVlFkkCoQq7HXQB9BQgrp24B1fVnClYZCgmjGM5edXg+mhyNfXd2idGt1oZ8+dxePT4al7yEX/h9hp8uNNEIYWJfZ1pkilDEWtzeN/+Z1WM8umUfUVNFMaPVyGu9cq4fhX2ZdIk3QHF6UMM62l8omHPVgBAQGvyam2cJu0b3vNWCMBYgy7f3fV5ngHkb6gyBwlGdGri/B9toEqqLJlnM32W7wQmHEHW6dOVU62PWsq4aqV12nbljEIr1ALgrcz7r6u3iMz7bCficrDbCR3HH3waOyNqjUSd2lZn/zehLV3mnj+p2hgyIrtMBTQf5gF+8tccgSRKPbdp1vcfLCFKcEjll+E0ajOiSsV3RkeGiIVcVoPqDY5wGNz+UR7LJeLIvbDZbLvTfVpKitphTant/q5Of3cPPChT4PyNeF28Zs+dl/koGbIRSH3knxLsC58qPE52JJs/nMeWWu1tHoTAKFzmE5gzbhOQScZYgs2M725TON86YG8Fn+7FfkoltTu5NHawrXH/TuMBoqaULi7UQZa4acsiKtCJkVLz/3yU3PMbp7e3VI3+6YQn/YQLbw740o2vNyEmBalsmlKdvGSk/gI1Ier8MubJ7HJA238pyfKDJw4coA3p1FhBQF6HJhk5bzg1U8MfNMsSxmHN112eyLswpfFi/+XZEJKISkbw9Ku1z+Vv6U74CmFXVktPkMZuR1VezakvHkEE+L5MCVE4Ok3tFJlgawDAQAQ8+/SOoxLiPpofKdEyqqgZg==
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/linux_network_service_bundle/aesm_http_msg.cpp|101|http_network_init|Mon Dec 23 11:10:16 2019]http init for url http://ps.sgx.trustedservices.intel.com:80
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/linux_network_service_bundle/aesm_http_msg.cpp|129|http_network_init|Mon Dec 23 11:10:16 2019]use manual proxy http://10.10.78.61:3128
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/linux_network_service_bundle/aesm_http_msg.cpp|137|http_network_send_data|Mon Dec 23 11:10:16 2019]send data method=1
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/linux_network_service_bundle/aesm_http_msg.cpp|228|http_network_send_data|Mon Dec 23 11:10:16 2019]Response code error:417
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/linux_network_service_bundle/linux_network_service_bundle.cpp|59|aesm_send_recv_msg_encoding_internal|Mon Dec 23 11:10:16 2019]fail to send encoded msg (size=1158) to url:http://ps.sgx.trustedservices.intel.com:80
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/epid_quote_service_bundle/pve_logic.cpp|448|epid_provision_thread_func|Mon Dec 23 11:10:16 2019]send msg1 via network fail:(ae_error_t:AE_FAILURE:1)
[/home/prash/linux-sgx/psw/ae/aesm_service/source/utils/aesm_long_lived_thread.cpp|348|set_status_finish|Mon Dec 23 11:10:16 2019]set finish status for ioc 0x7f0b5c003f20(status=1,timeout=0,ref_count=2) of thread 0x7f0b67dafbc0
[/home/prash/linux-sgx/psw/ae/aesm_service/source/utils/aesm_long_lived_thread.cpp|350|set_status_finish|Mon Dec 23 11:10:16 2019]set thread 0x7f0b67dafbc0 to idle
[/home/prash/linux-sgx/psw/ae/aesm_service/source/oal/linux/aesm_thread.cpp|97|aesm_thread_proc|Mon Dec 23 11:10:16 2019]returned from user defined thread code for thread 0x7f0b5c001dc0
[/home/prash/linux-sgx/psw/ae/aesm_service/source/oal/linux/aesm_thread.cpp|108|aesm_thread_proc|Mon Dec 23 11:10:16 2019]thread 0x7f0b5c001dc0 change to status AESM_THREAD_PEDNING
[/home/prash/linux-sgx/psw/ae/aesm_service/source/oal/linux/aesm_thread.cpp|297|aesm_wait_thread|Mon Dec 23 11:10:16 2019]thread 0x7f0b5c001dc0 is detached with return value 1
[/home/prash/linux-sgx/psw/ae/aesm_service/source/utils/aesm_long_lived_thread.cpp|306|set_thread_start|Mon Dec 23 11:10:16 2019]wait for ioc 0x7f0b5c003f20 (status=0,timeout=1577079676,ref_count=1) result:0
[/home/prash/linux-sgx/psw/ae/aesm_service/source/utils/aesm_long_lived_thread.cpp|235|deref|Mon Dec 23 11:10:16 2019]deref ioc 0x7f0b5c003f20 (ref_count=1,status=0,timeout=1577079676) of thread 0x7f0b67dafbc0
[/home/prash/linux-sgx/psw/ae/aesm_service/source/utils/aesm_long_lived_thread.cpp|243|deref|Mon Dec 23 11:10:16 2019]free thread handle for ioc 0x7f0b5c003f20
[/home/prash/linux-sgx/psw/ae/aesm_service/source/oal/linux/aesm_thread.cpp|221|aesm_free_thread|Mon Dec 23 11:10:16 2019]start to free thread 0x7f0b5c001dc0
[/home/prash/linux-sgx/psw/ae/aesm_service/source/oal/linux/aesm_thread.cpp|236|aesm_free_thread|Mon Dec 23 11:10:16 2019]thread 0x7f0b5c001dc0 detached
[/home/prash/linux-sgx/psw/ae/aesm_service/source/oal/linux/aesm_thread.cpp|241|aesm_free_thread|Mon Dec 23 11:10:16 2019]thread 0x7f0b5c001dc0 resource dealloced
[/home/prash/linux-sgx/psw/ae/aesm_service/source/bundles/epid_quote_service_bundle/qe_logic.cpp|79|try_reprovision_if_not|Mon Dec 23 11:10:16 2019]pve provision failed:(aesm_error_t:AESM_UNEXPECTED_ERROR:1)
prash@prash-OptiPlex-3050:~/sgx-ra-sample$

From above, it looks like the aesmd service tries to send a message to http://ps.sgx.trustedservices.intel.com:80 but gets an HTTP response code 417. I am behind a proxy, and I have configured it to be "manual" in /etc/aesmd.conf.

Any help on what might be happening or pointers to debug this further?

Thanks, Prashant

dtzimmerman commented 4 years ago

Hi Prashant,

Seems that the problem is that the client system is unable to be EPID provisioned since its sitting behind a proxy.

I see that you configured /etc/aesmd.conf to use "manual" proxy, and I also assume that you set the "aesm proxy =" to your actual proxy and port?

Once you have changed the configuration, you will need to restart AESMD for the settings to take effect.

If you are still having trouble after that, set DEBUG = 1 and VERBOSE = 1 in the settings file and run again. Then check the client.log file for more details.

cheers,

Dan

agrawalprash commented 4 years ago

I did set "aesm proxy = http://proxyserver:port" in /etc/aesmd.conf, and I did restart the aesmd service, but nothing changed.

Interestingly, I got the platform provisioned once through a direct network connection (without proxy), after which all subsequent attestations have been working fine through the regular proxy network. So I'm curious if it's the provisioning step which runs into problems with proxy? I think my issue is similar to https://github.com/intel/linux-sgx/issues/190, but the root cause of that issue isn't clear either.

jmechalas commented 4 years ago

A system doesn't provision an EPID key until it attempts its first attestation. AESM needs to be able to connect to the internet in order to obtain the provisioning key. It won't need to re-provision, however, unless there's a TCB update, which can happen as a result of a BIOS update (as new microcode patches get pushed to the system).

The only thing I can think of that would make a difference here would be the proxy, possibly preventing you from contacting the provisioning service. The only way to know for sure would be to run tcpdump on the client and watch the connections from the client when it attempts attestation.

jmechalas commented 4 years ago

Closing since it's been over 6 months since the last comment.