Skip to content
This repository was archived by the owner on Jun 9, 2022. It is now read-only.

Commit eabff1e

Browse files
committed
Fixed register.py and switched back to read instead of readline
1 parent fc1c63a commit eabff1e

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

u2flib_host/authenticate.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ def main():
110110
else:
111111
if sys.stdin.isatty():
112112
sys.stderr.write('Enter AuthenticateRequest JSON data...\n')
113-
data = sys.stdin.readline()
113+
data = sys.stdin.read()
114114

115115
params = json.loads(data)
116116
if args.soft:

u2flib_host/register.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -95,15 +95,15 @@ def parse_args():
9595
def main():
9696
args = parse_args()
9797

98-
facet = text_type(args.facet, sys.stdin.encoding or sys.getdefaultencoding())
98+
facet = text_type(args.facet)
9999
if args.infile:
100100
with open(args.infile, 'r') as f:
101101
data = f.read()
102102
else:
103103
if sys.stdin.isatty():
104104
sys.stderr.write('Enter RegistrationRequest JSON data...\n')
105105
data = sys.stdin.read()
106-
params = json.loads(data, object_hook=u2str)
106+
params = json.loads(data)
107107

108108
if args.soft:
109109
from u2flib_host.soft import SoftU2FDevice

0 commit comments

Comments
 (0)