{"action":"created","issue":{"url":"https://api.github.com/repos/appium/appium/issues/6797","repository_url":"https://api.github.com/repos/appium/appium","labels_url":"https://api.github.com/repos/appium/appium/issues/6797/labels{/name}","comments_url":"https://api.github.com/repos/appium/appium/issues/6797/comments","events_url":"https://api.github.com/repos/appium/appium/issues/6797/events","html_url":"https://github.com/appium/appium/issues/6797","id":174495792,"number":6797,"title":"Safari - iOS cookie handling doesn't find any secure cookies","user":{"login":"hazmeister","id":11080542,"avatar_url":"https://avatars1.githubusercontent.com/u/11080542?v=3","gravatar_id":"","url":"https://api.github.com/users/hazmeister","html_url":"https://github.com/hazmeister","followers_url":"https://api.github.com/users/hazmeister/followers","following_url":"https://api.github.com/users/hazmeister/following{/other_user}","gists_url":"https://api.github.com/users/hazmeister/gists{/gist_id}","starred_url":"https://api.github.com/users/hazmeister/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hazmeister/subscriptions","organizations_url":"https://api.github.com/users/hazmeister/orgs","repos_url":"https://api.github.com/users/hazmeister/repos","events_url":"https://api.github.com/users/hazmeister/events{/privacy}","received_events_url":"https://api.github.com/users/hazmeister/received_events","type":"User","site_admin":false},"labels":[{"id":24368806,"url":"https://api.github.com/repos/appium/appium/labels/Bug","name":"Bug","color":"fc2929","default":false},{"id":34328471,"url":"https://api.github.com/repos/appium/appium/labels/iOS","name":"iOS","color":"444444","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2016-09-01T11:04:18Z","updated_at":"2017-03-20T16:42:36Z","closed_at":null,"body":"## The problem\n\nTo reset the browser to a clean state in my tests, I often use the `deleteAllCookies()` method to clear the test's state.  With Appium and iOS, cookie handling appears to be limited to non secure cookies for the same domain.  Even checking the number of cookies after calling `deleteAllCookies()` seems to leave several cookies on sites secured with HTTPS.\n\nRunning the same test with Appium and Android deletes all the cookies for the domain as expected.\n## Environment\n- Appium version (or git revision) that exhibits the issue: 1.53\n- Desktop OS/version used to run Appium: Mac OS X 10.11.6\n- Mobile platform/version under test: iOS 9.3\n- Real device or emulator/simulator: Both\n- Appium CLI or Appium.app|exe: Appium.app\n## Code To Reproduce Issue\n\nStep through in debug mode - subsititue your own account details!\n\n```\n        driver.get(\"https://accounts.google.com/AccountChooser\");\n        driver.findElement(By.cssSelector(\"#Email\")).sendKeys(\"youraccount@gmail.com\");\n        driver.findElement(By.cssSelector(\"input#next\")).click();\n        driver.findElement(By.cssSelector(\"#Passwd\")).sendKeys(\"password\");\n        driver.findElement(By.cssSelector(\"input#signIn\")).click();\n\n        int clear = 0;\n        int secure = 0;\n        Set<Cookie> cookies = driver.manage().getCookies();\n        for (Cookie cookie : cookies) {\n            if(cookie.isSecure()) {\n                secure++;\n            } else {\n                clear++;\n            }\n        }\n        System.out.println(\"Found \" + secure + \" secure cookies\");\n        System.out.println(\"Found \" + clear + \" clear cookies\");\n        driver.manage().deleteAllCookies();\n        driver.navigate().refresh();\n        Set<Cookie> cookies1 = driver.manage().getCookies();\n        System.out.println(cookies1.size() + \" still found.\";\n```\n\n[Clone here](https://github.com/hazmeister/appium-bugs/blob/master/src/test/java/Cookies.java)\n## Appium Logs\n\n[Gist](https://gist.github.com/hazmeister/33bfcec6ecd9f79f69f6c24b4b1d166a)\n"},"comment":{"url":"https://api.github.com/repos/appium/appium/issues/comments/287820122","html_url":"https://github.com/appium/appium/issues/6797#issuecomment-287820122","issue_url":"https://api.github.com/repos/appium/appium/issues/6797","id":287820122,"user":{"login":"imurchie","id":2614354,"avatar_url":"https://avatars1.githubusercontent.com/u/2614354?v=3","gravatar_id":"","url":"https://api.github.com/users/imurchie","html_url":"https://github.com/imurchie","followers_url":"https://api.github.com/users/imurchie/followers","following_url":"https://api.github.com/users/imurchie/following{/other_user}","gists_url":"https://api.github.com/users/imurchie/gists{/gist_id}","starred_url":"https://api.github.com/users/imurchie/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/imurchie/subscriptions","organizations_url":"https://api.github.com/users/imurchie/orgs","repos_url":"https://api.github.com/users/imurchie/repos","events_url":"https://api.github.com/users/imurchie/events{/privacy}","received_events_url":"https://api.github.com/users/imurchie/received_events","type":"User","site_admin":false},"created_at":"2017-03-20T16:42:36Z","updated_at":"2017-03-20T16:42:36Z","body":"The core team has not had a chance to work on this yet, though it is in our backlog. I haven't seen any action from anyone else, either. :("}}
{"actor":{"display_login":"imurchie"}}