Skip to content

Conversation

@Diapolo
Copy link

@Diapolo Diapolo commented Dec 12, 2014

This continues my work on the payment request / server part of our BIP70 implementation.
Please see individual commits for detailed descriptions.

@Diapolo
Copy link
Author

Diapolo commented Dec 12, 2014

Seems I used some Qt5 stuff, need to check ;).

@gmaxwell gmaxwell added the GUI label Jan 9, 2015
@Diapolo
Copy link
Author

Diapolo commented Jan 10, 2015

I'd love to see that reviewed or ACKd @laanwj @gavinandresen, mind taking a look?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This method is unused. Is there a plan to make use of it soon? IMO we should keep unused implementation in master at minimum. Better keep this in a separate branch and add it if we use it.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nevermind.
You removed it. Sorry.

@jonasschnelli
Copy link
Contributor

Needs rebase.

@jonasschnelli
Copy link
Contributor

It's not related to this pull, but better here than in a new issue:
I did try creating a payment-request over gavins php tool and selected bitcoincore as merchant.
I got a GUI: PaymentRequestPlus::getMerchant : Payment request: empty certificate chain.
A) is there no merchant cert behind "bitcoincore"?
B) IMO we should show something to the user in case of a invalid or missing cert chain.

@Diapolo
Copy link
Author

Diapolo commented Jan 30, 2015

@jonasschnelli Rebased

As for the cert problems with gavins php tool, IMHO you won't get any authenticated payment request from it and consensus then is to silently treat it as valid unauthenticated request. I had that discussion with @laanwj @gavinandresen and @mikehearn ;).

@jonasschnelli
Copy link
Contributor

Tested, reviewed, stepped.
Mostly move-only, cleanup things (does that require 7 commits, squash?).

ACK

@Diapolo
Copy link
Author

Diapolo commented Jan 30, 2015

I did each change in a seperate commit to make it easy to review :).

@luke-jr
Copy link
Member

luke-jr commented Jan 30, 2015

Does anyone have a test plan for this?

@Diapolo
Copy link
Author

Diapolo commented Jan 30, 2015

@luke-jr Are you serious??

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

NACK on changing this. There is check for certs.empty() that prevents this from becoming a bug, but for loops that count down, I generally prefer to use signed types. In this case, i will never visit 0, but normally a loop like this would look like:

for (int i = certs.size() - 1; i >= 0; i--) {

If you then change the int to e.g. size_t, it will loop forever.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reverted!

@Diapolo
Copy link
Author

Diapolo commented Feb 3, 2015

@jonasschnelli If you've got an idea how to group the commits so they can get merged I'll gladly do this. Guess this needs an ACK from @laanwj still :).

@Diapolo
Copy link
Author

Diapolo commented Mar 18, 2015

@laanwj @jonasschnelli Is there some consensus possible to at least pick most of these commits or some, so we can get on here!?

@Diapolo
Copy link
Author

Diapolo commented Apr 12, 2015

I'd like to improve payment request stuff, but not getting on with this is blocking, you know ;).

@laanwj
Copy link
Member

laanwj commented Apr 15, 2015

ACK apart from the char* change.

Philip Kaufmann added 7 commits April 15, 2015 14:31
- also add a few more comments in PaymentServer::LoadRootCAs
Before and after was tested in Windows:

before:
GUI: ReportInvalidCertificate : Payment server found
an invalid certificate:  ("Microsoft Authenticode(tm) Root Authority")
GUI: ReportInvalidCertificate : Payment server found
an invalid certificate:  ()
GUI: ReportInvalidCertificate : Payment server found
an invalid certificate:  ()
GUI: ReportInvalidCertificate : Payment server found
an invalid certificate:  ()

after:
GUI: ReportInvalidCertificate: Payment server found an
invalid certificate:  "01" ("Microsoft Authenticode(tm) Root Authority")
() ()
GUI: ReportInvalidCertificate: Payment server found an
invalid certificate:  "01" () () ("Copyright (c) 1997 Microsoft Corp.",
"Microsoft Time Stamping Service Root", "Microsoft Corporation")
GUI: ReportInvalidCertificate: Payment server found an
invalid certificate:  "4a:19:d2:38:8c:82:59:1c:a5:5d:73:5f:15:5d:dc:a3" ()
() ("NO LIABILITY ACCEPTED, (c)97 VeriSign, Inc.", "VeriSign Time Stamping
Service Root", "VeriSign, Inc.")
GUI: ReportInvalidCertificate: Payment server found an
invalid certificate:  "e4:9e:fd:f3:3a:e8:0e:cf:a5:11:3e:19:a4:24:02:32" ()
() ("Class 3 Public Primary Certification Authority")
- used in sendcoinsdialog.cpp and paymentserver.cpp
- removes an unneded translation string
@Diapolo
Copy link
Author

Diapolo commented Apr 15, 2015

@laanwj Thanks for review, I fixed the spelling error and remove the QVariant commit, should be ready now :).

@laanwj laanwj merged commit 6171e49 into bitcoin:master Apr 15, 2015
laanwj added a commit that referenced this pull request Apr 15, 2015
6171e49 [Qt] Use identical strings for expired payment request message (Philip Kaufmann)
06087bd [Qt] minor comment updates in PaymentServer (Philip Kaufmann)
35d1595 [Qt] constify first parameter of processPaymentRequest() (Philip Kaufmann)
9b14aef [Qt] take care of a missing typecast in PaymentRequestPlus::getMerchant() (Philip Kaufmann)
d19ae3c [Qt] remove unused PaymentRequestPlus::getPKIType function (Philip Kaufmann)
6e17a74 [Qt] paymentserver: better logging of invalid certs (Philip Kaufmann)
5a53d7c [Qt] paymentserver: do not log NULL certificates (Philip Kaufmann)
@Diapolo Diapolo deleted the paymentserver_2 branch April 15, 2015 14:26
@bitcoin bitcoin locked as resolved and limited conversation to collaborators Sep 8, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants