{"action":"closed","issue":{"url":"https://api.github.com/repos/mempodippy/vlany/issues/19","repository_url":"https://api.github.com/repos/mempodippy/vlany","labels_url":"https://api.github.com/repos/mempodippy/vlany/issues/19/labels{/name}","comments_url":"https://api.github.com/repos/mempodippy/vlany/issues/19/comments","events_url":"https://api.github.com/repos/mempodippy/vlany/issues/19/events","html_url":"https://github.com/mempodippy/vlany/issues/19","id":213429600,"number":19,"title":"vlany/symbols/exec/execve.c","user":{"login":"0xAF","id":326320,"avatar_url":"https://avatars0.githubusercontent.com/u/326320?v=3","gravatar_id":"","url":"https://api.github.com/users/0xAF","html_url":"https://github.com/0xAF","followers_url":"https://api.github.com/users/0xAF/followers","following_url":"https://api.github.com/users/0xAF/following{/other_user}","gists_url":"https://api.github.com/users/0xAF/gists{/gist_id}","starred_url":"https://api.github.com/users/0xAF/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/0xAF/subscriptions","organizations_url":"https://api.github.com/users/0xAF/orgs","repos_url":"https://api.github.com/users/0xAF/repos","events_url":"https://api.github.com/users/0xAF/events{/privacy}","received_events_url":"https://api.github.com/users/0xAF/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2017-03-10T19:25:10Z","updated_at":"2017-03-11T18:20:55Z","closed_at":"2017-03-11T18:20:55Z","body":"I have a copy of your earlier work (as it seems) and in the execve.c file, at the end you have:\r\n```\r\n            if(!strcmp(argv[i], \"-static\")) // trying to statically compile a binary.. eww\r\n            {\r\n                // This works and removes the -static flag from the gcc execution but for some reason gcc throws a \"not found error\" with an empty string\r\n                // printf(\"gcc -static flag detected. overwriting -static flag\\n\");\r\n                // strncpy(argv[i], \"\", strlen(argv[i]));\r\n                // printf(\"-static flag overwritten\\n\");\r\n                // For now, let's just return a kernel memory error\r\n                // Sigh...\r\n\r\n                errno = ENOMEM;\r\n                return -1;\r\n            }\r\n```\r\nI think GCC returns error, because it gets it's argument/option/parameter which is empty now. And when it parses it,  the parser does not recognize it as a option, starting with '-', so it decides it's a file to compile. But empty filename is \"not found\".\r\nJust a wild guess... try to replace it with some pointless option like '-Wvarargs' (which is by default anyway).\r\nI guess this should work...\r\n\r\n(Sorry for not testing it myself, I was just reading what you've done there and I though to share my wild guess, but I do not have time or need to try it myself)"}}
{"actor":{"display_login":"0xAF"}}