davidksalazar

Q: Disable Safari 7.0.2 keychain password save

How can I disable safari from saving a user/pass from a form using html or javascript?

I've had this issue that came up with safari 7.0.2 where you can save a user/pass to a keychain and when you goto that same form it automatically overrides those fields? Personally I think this is horrible behavior. I don't think fields should ever be overridden.

 

I've created an isolated version that you can demo the issue here. http://dev.davidsalazar.com/issues/safari-autofill/

 

Steps to replicate (ensure you use latest safari 7.0.2)

1. Type and user/pass click save. It should prompt you to save to keychain, accept the save.

2. Now click on the link load random data and you will notice that safari will now be overriding those fields with your perviously saved fields.

iMac (27-inch Late 2009), OS X Mountain Lion (10.8.1)

Posted on Mar 24, 2014 9:10 AM

Close

Q: Disable Safari 7.0.2 keychain password save

  • All replies
  • Helpful answers

Page 1 Next
  • by sterling r,

    sterling r sterling r Mar 26, 2014 11:29 AM in response to davidksalazar
    Community Specialists
    Mar 26, 2014 11:29 AM in response to davidksalazar

    Hello DavidKSalazar,

     

    It sounds like you are being prompted to save your password to a keychain and you want it to stop. From what you describe it seems like iCloud Keychain is turned on. You can use this info to close it in your Settings:

    Devices using iOS 7.0.3 or later:

    1. Go to Settings > iCloud and turn Keychain on.

    From: iCloud: Frequently asked questions about iCloud Keychain

              http://support.apple.com/kb/HT5813

     

    Thank you for using Apple Support Communities.

    All the best,

    Sterling

  • by davidksalazar,

    davidksalazar davidksalazar Mar 26, 2014 2:12 PM in response to sterling r
    Level 1 (0 points)
    Mar 26, 2014 2:12 PM in response to sterling r

    I'm not interested in knowing how to disable the keychain from safari.  I want to know how I can disable it on the end users side for the form.  Please reread my post. 

  • by davidksalazar,

    davidksalazar davidksalazar Mar 27, 2014 10:26 PM in response to sterling r
    Level 1 (0 points)
    Mar 27, 2014 10:26 PM in response to sterling r

    I thought this was goign to work but it didn't.

    http://www.w3schools.com/tags/att_input_autocomplete.asp

  • by Kingoftypos,

    Kingoftypos Kingoftypos Mar 29, 2014 11:03 PM in response to davidksalazar
    Level 3 (757 points)
    Mar 29, 2014 11:03 PM in response to davidksalazar

    Have you tried removing the keychain for said website? For example, the one that you provided. I followed your instructions.

     

    Typed "tester" in the username section. Then "user" in the password section. When prompted to save the password, I clicked save.

     

    Closed the window and went back to it. I saw that both fields were taken up, "tester" and "****" for user. I clicked on Load random data into fields. Saw the random data, but then Safari overridden them.

     

    Went into Safari---> Preferences---> Passwords and deleted the password associated with that website. Went back and clicked on Load Random Data Into Fields and it did just that.

     

    I know it's not exactly what you are looking for, but it's an option.

     

    Besides, I've had more than one Yahoo email address. If I were to double click the username, it gave me the option for both email addresses with their own password.

     

    KOT

  • by davidksalazar,

    davidksalazar davidksalazar Mar 29, 2014 11:12 PM in response to Kingoftypos
    Level 1 (0 points)
    Mar 29, 2014 11:12 PM in response to Kingoftypos

    I do not want a solution that involves messing with browser preferences. I want a solution that I can do for all users. 

     

    If you can't wrap your head around a scenario where this would be necessary. Think about this. You have a multi user environment let's say a cms. When you try to edit or create a new user record, safari asks to save it to keychain. Now whenever they try to edit an existing user record it now overrides the fields with the one saved on the keychain. Can you understand how this behavior can be unacceptable and how simply disabling that on safari or manually deleting the saved keychain entry is not a long term solution to this issue.

  • by Kingoftypos,

    Kingoftypos Kingoftypos Mar 29, 2014 11:18 PM in response to davidksalazar
    Level 3 (757 points)
    Mar 29, 2014 11:18 PM in response to davidksalazar

    Then click on "Never for this Web Site."

     

    KOT

  • by davidksalazar,

    davidksalazar davidksalazar Mar 29, 2014 11:19 PM in response to Kingoftypos
    Level 1 (0 points)
    Mar 29, 2014 11:19 PM in response to Kingoftypos

    I can't rely on other users doing it.

  • by coranda,

    coranda coranda Mar 30, 2014 5:11 AM in response to davidksalazar
    Level 1 (0 points)
    Mar 30, 2014 5:11 AM in response to davidksalazar

    The problem is in the default behaviour of Safari.  We can't expect novice users to make browser configuration changes.

     

    As an illustration of the problem:

     

    I administer a site and registered users have a profile page where they can change various parameters - including their email address.  Whenever a user goes to their profile page in Safari 7 it immediately overwrites their email field with their username.  They then can't save any changes to their profile until they replace their username with  a valid email address.  Why is Safari putting their username into an email address field?

     

    I can prevent this behaviour by allowing users to change their username and hence exposing that field in their profile.  This is not ideal as I don't want people changing their identity at will.  However, this doesn't solve the underlying problem because when I, as the administrator, visit a user's profile it overwrites their email address with my username.

     

    This is definitely a bug and not a feature.  A field that has a value tag, or autocomplete set to off, should not be overwritten by the browser.

  • by davidksalazar,

    davidksalazar davidksalazar Mar 30, 2014 5:15 AM in response to coranda
    Level 1 (0 points)
    Mar 30, 2014 5:15 AM in response to coranda

    Precisely.

  • by davidksalazar,

    davidksalazar davidksalazar Apr 1, 2014 9:22 AM in response to coranda
    Level 1 (0 points)
    Apr 1, 2014 9:22 AM in response to coranda

    I submitted this as a bug here http://www.apple.com/feedback/safari.html i suggest anyone with this issue do the same so they can fix this.

  • by James Cook2,

    James Cook2 James Cook2 Apr 7, 2014 5:59 AM in response to davidksalazar
    Level 1 (15 points)
    Notebooks
    Apr 7, 2014 5:59 AM in response to davidksalazar

    This is a serious security issue. After you've logged out, another person on the same computer can log in to your account without even trying - just opening the page.

     

    As a site owner it's a problem where we have very private data and have our pages written to prevent autofill. Safari recently began ignoring it and we have privacy at risk.

  • by coranda,

    coranda coranda Apr 7, 2014 7:06 AM in response to davidksalazar
    Level 1 (0 points)
    Apr 7, 2014 7:06 AM in response to davidksalazar

    David,

     

    Thanks for the link. Bug report lodged.

  • by calsoft,

    calsoft calsoft Apr 21, 2014 7:08 AM in response to davidksalazar
    Level 1 (0 points)
    Apr 21, 2014 7:08 AM in response to davidksalazar

    Hacky Solution....

     

    I wrapped my login control around a div and set display:none.  I then used some JavaScript (JQuery) to wait a 1/2 second after the document was loaded and then displayed the div.  Since the fields are not visible the browser has nothing to fill.  They are coming up blank every time. 

     

    Not the best solution, but will work until they are ready to start respecting autocomplete=off.

     

    <div id="control" style="display:none">

    ...login fields

    </div>

     

                            <script>

                                $(document).ready(function () {

     

                                    setTimeout(function () {

                                        $('#control').toggle();

                                    }, 500);

                                });

                            </script>

     

    Hope This Helps...

     

     


  • by davidksalazar,

    davidksalazar davidksalazar May 26, 2014 11:27 AM in response to davidksalazar
    Level 1 (0 points)
    May 26, 2014 11:27 AM in response to davidksalazar

    Here is a temporary fix.

     

    Add another password field as a dummy field. It appears to prevent safari from autofilling or saving.

     

    <input type="password" name="dummypass" value="dummypass" style="display: inline; width: 0; height: 0; border: 0;" />

Page 1 Next