Bug 998768 - [origin_broker_86]The value of env variable will be incorrect if the value contains special character '='
Summary: [origin_broker_86]The value of env variable will be incorrect if the value co...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: OpenShift Online
Classification: Red Hat
Component: Master
Version: 2.x
Hardware: All
OS: All
medium
medium
Target Milestone: ---
: ---
Assignee: Ravi Sankar
QA Contact: libra bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-08-20 03:20 UTC by zhaozhanqi
Modified: 2015-05-15 00:55 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-08-29 12:53:19 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description zhaozhanqi 2013-08-20 03:20:41 UTC
Description of problem:
if the value of env variable contain special character '=', it will be added or updated successfully. But the value is incorrect.
for example, set name=foo and value=@im=ibus, the result will be 'foo=ibus'

Version-Release number of selected component (if applicable):
devenv_3676

How reproducible:
always

Steps to Reproduce:
1. creat one app 
2. add one env variable with special charcter '=' for this app
   curl -k -H 'Accept: application/xml' --user $user:$pass https://ec2-50-16-53-228.compute-1.amazonaws.com/broker/rest/applications/441479955229558381215744/environment-variables -X POST -d name=foo -d value=@im=ibus
3. check its env
   rhc ssh app --gear env|grep foo

Actual results:

[zqzhao@dhcp-13-222 build]$ rhc ssh app --gear env |grep foo
foo=ibus

Expected results:
foo=@im=ibus

Additional info:

Comment 1 Ravi Sankar 2013-08-20 19:42:29 UTC
Fixed in https://github.com/openshift/origin-server/pull/3439

Comment 2 zhaozhanqi 2013-08-22 02:11:22 UTC
Tested this issue on devenv_3683,it has been fixed. 

curl -k -H 'Accept: application/xml' --user zzhao:redhat https://$instance/broker/rest/applications/4edc59800acf11e3b0d412313d08bd61/environment-variables -X POST -d name=foo -d value=@dd=394=sg


[zqzhao@dhcp-13-222 .openshift]$ rhc ssh zqphp --gear env |grep foo
foo=@dd=394=sg

Comment 3 zhaozhanqi 2013-08-22 02:37:49 UTC
Tested this issue on devenv_stage_448 as well, it works well


Note You need to log in before you can comment on or make changes to this bug.