1

How can I change the kind of a Keychain item?

I'd prefer to do this via a GUI, command line (if no GUI), then lastly code (if no GUI or command line tool).

XDR
  • 635
  • 1
    Run man security to see some more details https://apple.stackexchange.com/questions/115507/visualizing-keychain-item-details?rq=1 – anki Dec 17 '19 at 16:31

1 Answers1

1

You can't directly change the kind of a Keychain item because item details use different schemas.

  generic        internet
  ═══════        ════════
  account ────── account
  creator ────── creator
  type    ────── type
  kind    ───┐  ★domain
 ★value      └── kind
  comment ────── comment
  label   ────── label
 ★service       ★path
  password───┐   port
             │  ★protocol
             │  ★server
             │  ★authenticationType
             └── password

You'll need to read out the information for the item you want to change, then create a new item with the new values where applicable.

grg
  • 201,078