Return-Path: Delivered-To: apmail-incubator-esme-dev-archive@minotaur.apache.org Received: (qmail 62570 invoked from network); 12 Jul 2010 14:45:25 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 12 Jul 2010 14:45:25 -0000 Received: (qmail 53094 invoked by uid 500); 12 Jul 2010 14:45:25 -0000 Delivered-To: apmail-incubator-esme-dev-archive@incubator.apache.org Received: (qmail 53044 invoked by uid 500); 12 Jul 2010 14:45:25 -0000 Mailing-List: contact esme-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: esme-dev@incubator.apache.org Delivered-To: mailing list esme-dev@incubator.apache.org Received: (qmail 53036 invoked by uid 99); 12 Jul 2010 14:45:25 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 12 Jul 2010 14:45:25 +0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests=FREEMAIL_FROM,SPF_PASS,T_TO_NO_BRKTS_FREEMAIL X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of hirsch.dick@gmail.com designates 209.85.161.47 as permitted sender) Received: from [209.85.161.47] (HELO mail-fx0-f47.google.com) (209.85.161.47) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 12 Jul 2010 14:45:17 +0000 Received: by fxm12 with SMTP id 12so2531947fxm.6 for ; Mon, 12 Jul 2010 07:43:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:content-type :content-transfer-encoding; bh=vvGHxxt1w47AGoWt3fIdaya3HbhkrMSY2/JBNvHPPIw=; b=CGcBVQN8L3pFjPEiCi7/k0IWDtEzRi9LnmRsfoNCo8+FoazRLdxccB6HIB1evd3oCK DGMC3vmzr35YqMF55UORmLiou9uD15HQ0/QrdzNdzkGviB41u+hVIHlTe0Vop3qU+JQU bVx/aXCQW3/LOdVZM9a3IM/xBQaQ5FttfW4CQ= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; b=K9UplLtomcd3UFnC0dc7Cwdb9gGkLllKB6nuJDKU0YPIgZFxFbsQocA8lCcbdm1gfM laQD6XxGoYjxAFG/MaaK9Mi21vbhAc6F+P3jLWHlErrczz0WnQPkG3doAJl8lecyemoE l637LizNyKq6Bzj+jMJP6r5/yBs75E83IEsuE= MIME-Version: 1.0 Received: by 10.103.172.10 with SMTP id z10mr2239329muo.44.1278945836729; Mon, 12 Jul 2010 07:43:56 -0700 (PDT) Received: by 10.103.239.5 with HTTP; Mon, 12 Jul 2010 07:43:56 -0700 (PDT) In-Reply-To: <865FDE640BF44D36B653107FB8FF6D0C@imtiaz20100131> References: <264264D3F5D342ED908C887216F518A5@imtiaz20100131> <790726548-1278918592-cardhu_decombobulator_blackberry.rim.net-1738752235-@bda188.bisx.produk.on.blackberry> <865FDE640BF44D36B653107FB8FF6D0C@imtiaz20100131> Date: Mon, 12 Jul 2010 16:43:56 +0200 Message-ID: Subject: Re: integration-admin role required for api2 calls ? From: Richard Hirsch To: esme-dev@incubator.apache.org Content-Type: text/plain; charset=ISO-8859-2 Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org On Mon, Jul 12, 2010 at 4:28 PM, Imtiaz Ahmed H E wro= te: > BTW, the steps I follow are: > > 1. mvn jetty:run > 2. Open cygwin prompt > 3, Execute curl commands. What command do you run in curl? When you run jetty - tomcat must be shut down. It usually listens on the same 8080 port. > > When previously opened Esme may have been left in logged in OR logged out > state... > > Please find attached a jpg with the My Tokens page of ESME showing the to= ken > I have used in my curl command to dump headers. The esme-dev mailer usually deletes all attachments - so we won't get it :-= < > > Maybe I need to step through API2's addSession() method. I stopped steppi= ng > through code when I moved to Java development 10 years back !. Or I need = to > figure out the basics of all that's going on inside addSession(), especia= lly > Lift-related, then maybe I can stick to my no-stepping-through-code attit= ude > ! > > Tried it again just now after shutting down a Tomcat instance of Esme > leaving Esme user, imtiaz2, logged in...got the same '403 Forbidden' in t= he > dumped header. > Imtiaz > > ----- Original Message ----- From: "Ethan Jewett" > To: > Cc: > Sent: Monday, July 12, 2010 7:35 PM > Subject: Re: integration-admin role required for api2 calls ? > > > For me, the following works fine: > > curl --dump-header headers -d "token=3DKMETDTRX01VV5MVS1RHV2CNGMUKENUB3" > http://localhost:8080/api2/session > > Returns: > > > 24testNoneEthan > Jewett > > Headers (from "cat headers"): HTTP/1.1 200 OK > Expires: Mon, 12 Jul 2010 14:02:15 UTC > Set-Cookie: JSESSIONID=3D2041ucsme2i8;Path=3D/ > Content-Length: 179 > Date: Mon, 12 Jul 2010 14:02:15 UTC > Pragma: no-cache > Content-Type: text/xml; charset=3Dutf-8 > Cache-Control: no-cache; private; no-store > X-Lift-Version: 2.0-SNAPSHOT > Server: Jetty(6.1.22) > > If you can confirm that the token exists in your installation, then we > have some sort of bug that I am unable to recreate at the moment and > we'll need to dig into it further. > > Ethan > > > On Mon, Jul 12, 2010 at 9:30 AM, Vassil Dichev wrote= : >> >> It might also mean that there's no such URL so you have no access to >> such a resource. >> >> On Mon, Jul 12, 2010 at 10:09 AM, wrote: >>> >>> Why am I getting 403, the token is exactly as got from one of the users >>> in the UI without an integration-admin role. >>> >>> Sent from BlackBerry=AE on Airtel >>> >>> -----Original Message----- >>> From: Richard Hirsch >>> Date: Mon, 12 Jul 2010 09:05:21 >>> To: >>> Reply-To: esme-dev@incubator.apache.org >>> Subject: Re: integration-admin role required for api2 calls ? >>> >>> you don't need the role to login in via the session method . You just >>> need the role when creating users or tokens via the api2. >>> >>> D. >>> >>> On Mon, Jul 12, 2010 at 9:01 AM, Imtiaz Ahmed H E >>> wrote: >>>> >>>> and how do you get this role ? Not having that role is probably why I'= m >>>> getting '403 Forbidden' in the following... >>>> >>>> >>>> imtiaz@imtiaz-20100131 /cygdrive/d/temp >>>> $ curl --dump-header headers -d "token=3DRCJ44VUZEOEES3NR1EZEIK32PF1BN= OBQ" >>>> http:/ >>>> /localhost:8080/api2/session >>>> >>>> imtiaz@imtiaz-20100131 /cygdrive/d/temp >>>> $ cat headers >>>> HTTP/1.1 403 Forbidden >>>> Expires: Sun, 11 Jul 2010 08:29:09 UTC >>>> Set-Cookie: JSESSIONID=3Dd8a63eqezeownsy8qnayuhwy;Path=3D/ >>>> Content-Length: 0 >>>> Date: Sun, 11 Jul 2010 08:29:09 UTC >>>> Pragma: no-cache >>>> Content-Type: text/plain; charset=3Dutf-8 >>>> Cache-Control: no-cache; private; no-store >>>> X-Lift-Version: 2.0-SNAPSHOT >>>> Server: Jetty(6.1.24) >>>> >>>> >>>> imtiaz@imtiaz-20100131 /cygdrive/d/temp >>>> $ >>>> >>>> Imtiaz >>> >> >