rabbitmqctl encode command fail during chipher operation #11053
-
Describe the bugThe Reproduction steps
Expected behaviorAnticipating an encrypted value but encountering this error instead:
Additional contextNo response |
Beta Was this translation helpful? Give feedback.
Replies: 5 comments 4 replies
-
Different ciphers may have different limitations as to what are the input values they can accept. You are welcome to investigate this further:
This is open source software after all. |
Beta Was this translation helpful? Give feedback.
-
A few more drive-by findings:
Here are the supported ciphers:
|
Beta Was this translation helpful? Give feedback.
-
So the value is parsed as an Erlang term, which allows you to encode arbitrary values but sadly, exposing the internals of Erlang data structures used. # <<"Abc">> is an Erlang binary
rabbitmqctl encode '<<"Binary value to encode">>' '<<"pa$$phAs3">>' --print-stacktrace works just fine because it does not interpret Perhaps the command should by default assume that the value is a binary but that may or may not be a safe thing to ship in 3.13.x. |
Beta Was this translation helpful? Give feedback.
-
Now that I've started looking at the docs, I see that the |
Beta Was this translation helpful? Give feedback.
-
Some relevant (and minor) doc updates rabbitmq/rabbitmq-website@4a6666f. I conclude that there isn't anything to change in CLI tools per se. Unless we want to lose the ability to encode more than one data type without additional CLI flags. |
Beta Was this translation helpful? Give feedback.
So the value is parsed as an Erlang term, which allows you to encode arbitrary values but sadly, exposing the internals of Erlang data structures used.
works just fine because it does not interpret
Abc
as an unbound local ("variable").Perhaps the command should by default assume that the value is a binary but that may or may not be a safe thing to ship in 3.13.x.