Page MenuHomePhabricator

Backport Core P10997 and PR11125: Add bitcoin-cli -stdin and -stdinrpcpass
Closed, ResolvedPublic

Description

commit affe9271aa4953ddbceb1bfe4e60838570272c56
Merge: 00ada1723 79191f51b
Author: Wladimir J. van der Laan <laanwj@gmail.com>
Date: Thu Aug 24 08:35:42 2017 +0200

Merge #10997: RPC: Add option -stdinrpcpass to bitcoin-cli to allow RPC password to be read from standard input

79191f5 Add option -stdinrpcpass to allow RPC password to be read from standard input (Joe Harvell)

Pull request description:

  Add a new command-line option to bitcoin-cli that allows the RPC password to be read from standard intput.  The purpose of this option is to allow secure RPC password input to bitcoin-cli through an external program that is capable of disabling terminal echo.

  This option works similarly to the existing -stdin option, and also works when combined with that option.

  I have also written a simple ncurses based program that disables echo, gets input from the terminal and writes to standard output.  I couldn't find an existing askpass program that doesn't require graphics libraries, since they are primarily used for getting passwords in a graphics environment.  Unless someone can point out a suitable existing askpass program, I plan to submit my ncurses program to the contrib directory separately from this pull request.

Tree-SHA512: 6d426d757de325d928fab42ea8e423273a7dea9f838acb745ccf9f9daa2b47e23044ec1c019cda1a081253f5145fc10f79ae82dfe7f8e952e1f271ec56018e14

and also

commit 645a7ecc0b8d69c7a4733b1f8548730b8ffa033c
Merge: 66a5b419e 29e1dfbd9
Author: Wladimir J. van der Laan <laanwj@gmail.com>
Date: Thu Sep 7 01:43:16 2017 +0200

Merge #11125: Add bitcoin-cli -stdin and -stdinrpcpass functional tests

29e1dfbd9 [test] Add bitcoin-cli -stdin and -stdinrpcpass functional tests (João Barbosa)
ce379b47b [test] Replace check_output with low level version (João Barbosa)
232e3e847 [test] Add assert_raises_process_error to assert process errors (João Barbosa)
5c18a84b9 [test] Add support for custom arguments to TestNodeCLI (João Barbosa)
e1274947d [test] Improve assert_raises_jsonrpc docstring (João Barbosa)
769684132 Fix style in -stdin and -stdinrpcpass handling (João Barbosa)

Pull request description:

  This patch adds tests for `bitcoin-cli` options `-stdin` (#7550) and `-stdinrpcpass` #10997.

Tree-SHA512: fd8133f44876f2b5b41dfd3762b1988598f6b7bf13fb2385ad95876825d9c0b2b896ce4ea6eeb21012158e1f276907f155d37bb967198b609d2d3dddbfa334c1

Event Timeline

schancel renamed this task from Backport Core PR11125: Add bitcoin-cli -stdin and -stdinrpcpass functional tests to Backport Core PR11125 and PR10883.Jan 30 2018, 06:15
schancel renamed this task from Backport Core PR11125 and PR10883 to Backport Core PR11125: Add bitcoin-cli -stdin and -stdinrpcpass functional tests.
schancel updated the task description. (Show Details)
schancel updated the task description. (Show Details)
schancel renamed this task from Backport Core PR11125: Add bitcoin-cli -stdin and -stdinrpcpass functional tests to Backport Core P10997 and PR11125: Add bitcoin-cli -stdin and -stdinrpcpass.Jan 30 2018, 19:09
schancel updated the task description. (Show Details)