[ https://issues.apache.org/jira/browse/UNOMI-170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16389434#comment-16389434 ]
Mitesh Jain edited comment on UNOMI-170 at 3/7/18 12:26 PM: ------------------------------------------------------------ Hi Serge, Thanks for your response, it is helping me a lot, Sample code is uploaded here: [https://github.com/mitijain123/unomi-rules] This is a angular 4 application you can run it with command: npm start I had passed the credentials as headers.append('Authorization', "Basic " + btoa("karaf:karaf")); If you can tell me, what is the right way to authenticating and then passing the credentials over to the rules API, it will be really helpful. Thanks was (Author: mitijain...@gmail.com): Hi Serge, Thanks for your response, it is helping me a lot, Sample code is uploaded here: https://github.com/mitijain123/unomi-rules This is a angular 4 application you can run it with command: npm start I had passed the credentials as headers.append('Authorization', "Basic " + btoa("karaf:karaf")); If you can telling what is the right way to authenticating and then passing the credentials over to the rules API, it will be really helpful. Thanks > UNOMI CORS Issue is coming when trying to fetch RULES > ----------------------------------------------------- > > Key: UNOMI-170 > URL: https://issues.apache.org/jira/browse/UNOMI-170 > Project: Apache Unomi > Issue Type: Bug > Components: core > Affects Versions: 1.2.0-incubating > Environment: Mac OS > Reporter: Mitesh Jain > Priority: Blocker > Labels: security > Attachments: Screen Shot 2018-03-07 at 11.35.27 AM.png > > > Hi, > My Name is Mitesh Jain, > I am new to Unomi. > All installations are done according to this link: > [http://unomi.incubator.apache.org/] > When I am trying to access the rest api cxs to fetch all the rules, it is > showing properly in browser when I browse, > [https://localhost:9443/cxs/rules] > but when I am trying to access the same using my Angular application to fetch > rules using above url, > [https://localhost:9443/cxs/rules|https://localhost:9443/cxs/rules/] it will > make a OPTIONS call and I am getting the error as "No > 'Access-Control-Allow-Origin' header is present on the requested resource." > Please Let me know how to fix this CORS issue. > Mitesh Jain > -- This message was sent by Atlassian JIRA (v7.6.3#76005)