virendra bhati
2011-Nov-21 06:42 UTC
[asterisk-users] How to use password file with Authenticate Application
Hi List, I want to use text file to get password information with Authenticate Application. I am using asterisk 1.6.2.11. I made text file at /tmp/pass.txt with below information. *pass.txt* Virendra: 81dc9bdb52d04dc20036dbd8313ed055 Vijay : 9996535e07258a7bbfd8b132435c5962 Virendra Bhati: 7bccfde7714a1ebadf06c5f4cea752c1 * SIP.conf :- [2218]* type=friend secret=****** callerid="Virendra" <9172341457> host=dynamic ; This device needs to register nat=yes ; X-Lite is behind a NAT router canreinvite=no ; Typically set to NO if behind NAT disallow=all dtmfmode=inband allow=speex allow=ulaw allow=alaw allow=gsm ; GSM consumes far less bandwidth than ulaw insecure=invite,port context=bhati-test qualify=yes accountcode=Virendra* **extensions.conf* [bhati-test] exten => 1234,1,Answer() same => n,NoOp(Welcome to WaveCrest Conferencing Soultion) same => n,playback(WC) same => n,Authenticate(/tmp/pass.txt,am,5) same => n,MeetMe(1234,Mp) same => n,Hangup() *CLI output:- * == Using SIP RTP CoS mark 5 -- Executing [1234 at bhati-test:1] Answer("SIP/2218-0000064f", "") in new stack -- Executing [1234 at bhati-test:2] NoOp("SIP/2218-0000064f", "Welcome to WaveCrest Conferencing Soultion") in new stack -- Executing [1234 at bhati-test:3] Playback("SIP/2218-0000064f", "WC") in new stack -- <SIP/2218-0000064f> Playing 'WC.gsm' (language 'en') -- Executing [1234 at bhati-test:4] Authenticate("SIP/2218-0000064f", "/tmp/pass.txt,am,5") in new stack -- <SIP/2218-0000064f> Playing 'agent-pass.ulaw' (language 'en') -- <SIP/2218-0000064f> Playing 'auth-incorrect.ulaw' (language 'en') -- <SIP/2218-0000064f> Playing 'auth-incorrect.ulaw' (language 'en') -- <SIP/2218-0000064f> Playing 'vm-goodbye.ulaw' (language 'en') == Spawn extension (bhati-test, 1234, 4) exited non-zero on 'SIP/2218-0000064f' Please help me where I am wrong -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20111121/836cc1ef/attachment.htm>
bakko
2011-Nov-21 12:05 UTC
[asterisk-users] How to use password file with AuthenticateApplication
hello, try to delete all spaces between user and password on the pass.txt Regards - Bakko -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20111121/5b3b43f8/attachment.htm>
virendra bhati
2011-Nov-21 12:15 UTC
[asterisk-users] How to use password file with AuthenticateApplication
Hi, After deleting all space no improvements. On Mon, Nov 21, 2011 at 5:35 PM, bakko <asannucci at gmail.com> wrote:> ** > hello, > > try to delete all spaces between user and password on the pass.txt > > Regards > > - Bakko > > -- > _____________________________________________________________________ > -- Bandwidth and Colocation Provided by http://www.api-digital.com -- > New to Asterisk? Join us for a live introductory webinar every Thurs: > http://www.asterisk.org/hello > > asterisk-users mailing list > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/mailman/listinfo/asterisk-users >-- ----- Thanks and regards Virendra Bhati +91-9172341457 Software Engineer -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20111121/ef4a515c/attachment.htm>
Warren Selby
2011-Nov-22 16:17 UTC
[asterisk-users] How to use password file with AuthenticateApplication
On Mon, Nov 21, 2011 at 6:15 AM, virendra bhati <virbhati at gmail.com> wrote:> Hi, > > After deleting all space no improvements. >Try reversing the account code and password hash, like this: 81dc9bdb52d04dc20036dbd8313ed055:Virendra 9996535e07258a7bbfd8b132435c5962:Vijay 7bccfde7714a1ebadf06c5f4cea752c1:VirendraBhati -- Thanks, --Warren Selby, dCAP http://www.SelbyTech.com <http://www.selbytech.com> -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20111122/975eb9a7/attachment.htm>
virendra bhati
2011-Nov-24 10:13 UTC
[asterisk-users] How to use password file with AuthenticateApplication
Hi Edwin, I did the same as you mention like that *echo -n "1234" | md5sum * On Thu, Nov 24, 2011 at 3:13 AM, Edwin Lam <edwin.lam at officegeneral.com>wrote:> On 11/22/11 9:02 PM, virendra bhati wrote: > >> On Mon, Nov 21, 2011 at 6:15 AM, virendra bhati <virbhati at gmail.com >> <mailto:virbhati at gmail.com>> wrote: >> >> Hi, >> >> After deleting all space no improvements. >> >> >> Try reversing the account code and password hash, like this: >> >> 81dc9bdb52d04dc20036dbd8313ed0**55:Virendra >> 9996535e07258a7bbfd8b132435c59**62:Vijay >> 7bccfde7714a1ebadf06c5f4cea752**c1:VirendraBhati >> > > the original format (i.e. <accountcode>:<md5hash>) was correct. > one question, when you create the md5hash did you use the echo > command? if so, did you specify the "-n" option? > e.g. echo -n 12345 | md5sum > > > -- > Edwin Lam <edwin.lam at officegeneral.com> > Systems Engineer, OfficeWyze, Inc. > Ph: +1 415 439 4988 Fax: +1 415 283 3370 > http://pgpkeys.mit.edu:11371/**pks/lookup?op=get&search=**0xD6506D20<http://pgpkeys.mit.edu:11371/pks/lookup?op=get&search=0xD6506D20> > > > > -- > ______________________________**______________________________**_________ > -- Bandwidth and Colocation Provided by http://www.api-digital.com -- > New to Asterisk? Join us for a live introductory webinar every Thurs: > http://www.asterisk.org/hello > > asterisk-users mailing list > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/**mailman/listinfo/asterisk-**users<http://lists.digium.com/mailman/listinfo/asterisk-users> >-- ----- Thanks and regards Virendra Bhati +91-9172341457 Software Engineer -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20111124/aeea5d8e/attachment.htm>
Tzafrir Cohen
2011-Nov-29 14:33 UTC
[asterisk-users] How to use password file with AuthenticateApplication
On Tue, Nov 22, 2011 at 10:17:52AM -0600, Warren Selby wrote:> On Mon, Nov 21, 2011 at 6:15 AM, virendra bhati <virbhati at gmail.com> wrote: > > > Hi, > > > > After deleting all space no improvements. > > > > Try reversing the account code and password hash, like this: > > 81dc9bdb52d04dc20036dbd8313ed055:Virendra > 9996535e07258a7bbfd8b132435c5962:Vijay > 7bccfde7714a1ebadf06c5f4cea752c1:VirendraBhatiIs that really the format to use? A plain hash? No salt? See e.g. http://kernel.org/doc/man-pages/online/pages/man3/crypt.3.html#NOTES -- Tzafrir Cohen icq#16849755 jabber:tzafrir.cohen at xorcom.com +972-50-7952406 mailto:tzafrir.cohen at xorcom.com http://www.xorcom.com iax:guest at local.xorcom.com/tzafrir
bakko
2011-Nov-29 14:46 UTC
[asterisk-users] How to use password file with AuthenticateApplication
I use this system to authenticate my users and work fine. Asterisk: 1.6.2.20 Asterisk user: root Maybe if you active debug on the Asterisk console, you can find the error. Regards - Bakko
virendra bhati
2011-Dec-23 08:33 UTC
[asterisk-users] How to use password file with AuthenticateApplication
Hi list, I have upgrade my linux version to Asterisk 1.6.2.20. now Authenticate() function is working. But 1 question I want to add this thread.. I have 3 password in my pass.txt file. i want that only sip 2209( just example,) will come with 1234 pass and 2208 with 1235 and rest will come with 1236 password. So how I can make so ? On Tue, Nov 29, 2011 at 8:16 PM, bakko <asannucci at gmail.com> wrote:> I use this system to authenticate my users and work fine. > > Asterisk: 1.6.2.20 > Asterisk user: root > > Maybe if you active debug on the Asterisk console, you can find the error. > > Regards > > - Bakko > > > -- > ______________________________**______________________________**_________ > -- Bandwidth and Colocation Provided by http://www.api-digital.com -- > New to Asterisk? Join us for a live introductory webinar every Thurs: > http://www.asterisk.org/hello > > asterisk-users mailing list > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/**mailman/listinfo/asterisk-**users<http://lists.digium.com/mailman/listinfo/asterisk-users> >-- Thanks and regards Virendra Bhati +91-8885268942 Software Engineer -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20111223/b8a2f678/attachment.htm>