Bugzilla – Attachment 434 Details for
Bug 2737
Ship script to make it easier to extra smart card key to authorized_keys
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
Code from Pierre that mangles to SSH format.
sshenc (text/plain), 446 bytes, created by
Peter Åstrand
on 2012-03-29 09:19:18 CEST
(
hide
)
Description:
Code from Pierre that mangles to SSH format.
Filename:
MIME Type:
Creator:
Peter Åstrand
Created:
2012-03-29 09:19:18 CEST
Size:
446 bytes
patch
obsolete
>#!/usr/bin/python > >import sys >import base64 >import struct > >line = sys.stdin.readline() > >(type, exp, mod) = line.split() > >exp = exp.decode("hex") >mod = mod.decode("hex") > >if ord(exp[0]) & 0x80: > exp = '\x00' + exp >if ord(mod[0]) & 0x80: > mod = '\x00' + mod > >pubkey = struct.pack("!I", 7) + "ssh-rsa" + struct.pack("!I", len(exp)) + exp + struct.pack("!I", len(mod)) + mod > >print pubkey.encode("hex") > >print "ssh-rsa %s" % base64.b64encode(pubkey)
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 2737
:
272
|
340
|
345
|
346
|
430
| 434