Bug 537062 - samba: add share resource fail if added with special characters (for example:test's”t#$%*) input for 'Resource Name' and 'Name' fields from iManage UI
Summary: samba: add share resource fail if added with special characters (for example:...
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: RHQ Project
Classification: Other
Component: Configuration
Version: 1.4
Hardware: x86_64
OS: Linux
low
low
Target Milestone: ---
: ---
Assignee: RHQ Project Maintainer
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-11-12 11:12 UTC by Rajan Timaniya
Modified: 2014-05-16 13:52 UTC (History)
4 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2014-05-16 13:52:44 UTC
Embargoed:


Attachments (Terms of Use)
screenshot for exception (183.83 KB, image/png)
2009-11-12 11:14 UTC, Rajan Timaniya
no flags Details

Description Rajan Timaniya 2009-11-12 11:12:21 UTC
Description of problem:
add share resource fail if added with special characters (for example:test's”t#$%*) input for 'Resource Name' and 'Name' fields from iManage UI

Test case: https://engineering.redhat.com/trac/IntegratedMgmtQE/wiki/Spearhead_RHEL_config_samba_Testplan (User_story_278:Testcase -14)

Version-Release number of selected component (if applicable):
version: 1.4.0-SNAPSHOT

How reproducible:


Steps to Reproduce:
1. Log in to imanage
2. Click on Overview and then Dashboard
3. Click on 'Samba Server' under the 'Recently Added  
     Resources'
4. Click on 'INVENTORY' and select the option 
    'OVERVIEW'
5. In 'Child Resources' there is selection box to select 
     '- Samba Share' or 'Services'. Select '- Samba Share' 
     and click on 'OK' button
6. To create new samba share, input given below 
     values and then click on 'SUBMIT' button
     Resource Name: test's”t#$%*
     Name: test's”t#$%*
     Path: /tmp/myshare
     Comment: myshare
     Browseable : Yes
     Read only: Yes
     Printable: Yes
     Guest ok: Yes
     Valid Users: testboy, rhqadmin
  
Actual results:
add resource fail with following exception
net.augeas.AugeasException: exists failed
	at net.augeas.Augeas.processLastCall(Augeas.java:396)
	at net.augeas.Augeas.exists(Augeas.java:222)
	at org.rhq.plugins.augeas.AugeasConfigurationComponent.createResource(AugeasConfigurationComponent.java:172)
	at org.rhq.plugins.samba.SambaServerComponent.createResource(SambaServerComponent.java:61)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:616)
	at org.rhq.core.pc.inventory.ResourceContainer$ComponentInvocationThread.call(ResourceContainer.java:525)
	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
	at java.util.concurrent.FutureTask.run(FutureTask.java:166)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
	at java.lang.Thread.run(Thread.java:636)

Expected results:
There should be a user error/alert message.

Additional info:

Comment 1 Rajan Timaniya 2009-11-12 11:14:28 UTC
Created attachment 369182 [details]
screenshot for exception

Comment 2 Sunil Kondkar 2009-12-10 12:02:32 UTC
This bug is also reproducible in sudoers and cron plugin.

Comment 3 Sunil Kondkar 2009-12-24 09:48:42 UTC
In cron plugin, it is observed that if user inputs any junk data in 'Name' and 'Value' fields for environment settings, the crontab creation shows failure status.

Steps to reproduce:
1. Login to Imanage UI.
2. Navigate to the 'Inventory' tab of cron resource.
3. Click on OK button to create new cron tab.
4. Enter the resource name as /etc/cron.d/bld101_6 and click on the button 'Add New' for environment settings.
5. Add junk values as in 'Name' field add input 'asdasdasd'.
6. In 'Value' field, add value as 'sadasdasdas'.
7. Click on OK button.
8. Click on Submit button.

It displays below error when clicked on 'Failure' link in 'History' subtab.

java.lang.RuntimeException:File "/etc/cron.d/bld101_6/error/path":
/files/etc/cron.d/bld101_6(root)
File "/etc/cron.d/bld101_6/error/lens":
/usr/share/augeas/lenses/dist/cron.aug:134.10-.49
File "/etc/cron.d/bld101_6/error/message":
Short iteration
 -> net.augeas.AugeasException:save failed

Comment 4 wes hayutin 2010-02-16 16:56:34 UTC
Temporarily adding the keyword "SubBug" so we can be sure we have accounted for all the bugs.

keyword:
new = Tracking + FutureFeature + SubBug

Comment 5 wes hayutin 2010-02-16 17:01:44 UTC
making sure we're not missing any bugs in rhq_triage

Comment 6 Corey Welton 2010-10-07 03:03:45 UTC
reducing priority/severity - not an enterprise plugin.


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