4

On the official web site it says that Payment ID

consists of 32 bytes (64 hexadecimal characters) or 8 bytes (in the case of integrated addresses).

Can it be less? If no, why?

1 Answer 1

4

I'm pretty sure the payment id can be shorter, and it is simply padded if it's too short. That said it shouldn't matter too much as it is encrypted so only the sender and receiver knows the contents.

5
  • 2
    monero-wallet-cli (and MyMonero) will currently reject hex strings of "invalid" length, rather than padding them. One could pad your preferred ID with zeros and use that, however.
    – Luigi
    Sep 20, 2016 at 0:06
  • 1
    Note that you have to use an integrated address to use encrypted payment IDs. By default they are in plain text, you can search and see them on any block explorer for instance.
    – binaryFate
    Sep 20, 2016 at 11:32
  • 1
    I tried Poloniex and a shorter PID (less then 64) was not accepted - so same result as Luigi said. I'm not sure if we can say that it can be shorter without padding. Is it possible on network/protocol level and right now it's just disallowed in software (wallet)?
    – A.D.
    Sep 22, 2016 at 5:57
  • "payment ID" and "short payment ID" have specific definitions in the code and need to be the appropriate length. However, you can make up other fields in the extra field of whatever length if you so desire.
    – Luigi
    Sep 22, 2016 at 22:37
  • @ferretinjapan can you edit your answer according to comments so I can accept it? Mainly first sentence seems to be not accurate.
    – A.D.
    Oct 16, 2016 at 21:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.