{"action":"created","issue":{"url":"https://api.github.com/repos/openssl/openssl/issues/3041","repository_url":"https://api.github.com/repos/openssl/openssl","labels_url":"https://api.github.com/repos/openssl/openssl/issues/3041/labels{/name}","comments_url":"https://api.github.com/repos/openssl/openssl/issues/3041/comments","events_url":"https://api.github.com/repos/openssl/openssl/issues/3041/events","html_url":"https://github.com/openssl/openssl/issues/3041","id":217243968,"number":3041,"title":"SSL_is_init_finished() returns nonzero before SSL_read_early_data() returns SSL_READ_EARLY_DATA_FINISH ","user":{"login":"tatsuhiro-t","id":404610,"avatar_url":"https://avatars3.githubusercontent.com/u/404610?v=3","gravatar_id":"","url":"https://api.github.com/users/tatsuhiro-t","html_url":"https://github.com/tatsuhiro-t","followers_url":"https://api.github.com/users/tatsuhiro-t/followers","following_url":"https://api.github.com/users/tatsuhiro-t/following{/other_user}","gists_url":"https://api.github.com/users/tatsuhiro-t/gists{/gist_id}","starred_url":"https://api.github.com/users/tatsuhiro-t/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tatsuhiro-t/subscriptions","organizations_url":"https://api.github.com/users/tatsuhiro-t/orgs","repos_url":"https://api.github.com/users/tatsuhiro-t/repos","events_url":"https://api.github.com/users/tatsuhiro-t/events{/privacy}","received_events_url":"https://api.github.com/users/tatsuhiro-t/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2017-03-27T13:22:17Z","updated_at":"2017-03-27T16:57:22Z","closed_at":null,"body":"I saw that SSL_is_init_finished() returns nonzero before SSL_read_early_data() returns SSL_READ_EARLY_DATA_FINISH on my experimental TLSv1.3 deployment.\r\nIs this expected behaviour?\r\n\r\nI use SSL_is_init_finished() to select write function between SSL_write_early_data and SSL_write.  It seems that I should also consider that SSL_read_eary_data has returned SSL_READ_EARLY_DATA_FINISH already.\r\n\r\nHere is some trace when this happened.\r\nFirst, the server read 42 bytes by SSL_read_early_data.\r\nThen the server read 5 bytes, and 32 bytes of early data using SSL_read_early_data. At that point, it still didn't return SSL_READ_EARLY_DATA_FINISH.\r\nI didn't log each write function.  So I don't know the exact timing and which function was used.\r\nEventually, I got: \"error:1420C042:SSL routines:ssl_write_internal:called a function you should not call\" by calling SSL_write().  In the server code, use of SSL_write is used only when SSL_is_init_finished() returns nonzero.\r\n\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/openssl/openssl/issues/comments/289515662","html_url":"https://github.com/openssl/openssl/issues/3041#issuecomment-289515662","issue_url":"https://api.github.com/repos/openssl/openssl/issues/3041","id":289515662,"user":{"login":"mattcaswell","id":7422273,"avatar_url":"https://avatars3.githubusercontent.com/u/7422273?v=3","gravatar_id":"","url":"https://api.github.com/users/mattcaswell","html_url":"https://github.com/mattcaswell","followers_url":"https://api.github.com/users/mattcaswell/followers","following_url":"https://api.github.com/users/mattcaswell/following{/other_user}","gists_url":"https://api.github.com/users/mattcaswell/gists{/gist_id}","starred_url":"https://api.github.com/users/mattcaswell/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mattcaswell/subscriptions","organizations_url":"https://api.github.com/users/mattcaswell/orgs","repos_url":"https://api.github.com/users/mattcaswell/repos","events_url":"https://api.github.com/users/mattcaswell/events{/privacy}","received_events_url":"https://api.github.com/users/mattcaswell/received_events","type":"User","site_admin":false},"created_at":"2017-03-27T16:57:22Z","updated_at":"2017-03-27T16:57:22Z","body":"No - this is not expected behaviour. Are you able to construct a simple reproducing test case?"}}
{"actor":{"display_login":"mattcaswell"}}