Changeset 368:a1f26147ec61 in freeDiameter for extensions/app_sip
- Timestamp:
- Jul 3, 2010, 12:40:00 AM (14 years ago)
- Branch:
- default
- Phase:
- public
- Location:
- extensions/app_sip
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/app_sip/diamsip.c
r364 r368 36 36 #include "diamsip.h" 37 37 38 static struct disp_hdl * diamsip_MAR_hdl=NULL; 39 static struct disp_hdl * diamsip_default_hdl=NULL; 38 struct disp_hdl * diamsip_MAR_hdl=NULL; 39 struct disp_hdl * diamsip_default_hdl=NULL; 40 struct session_handler * ds_sess_hdl; 41 42 struct diamsip_dict sip_dict; 40 43 41 44 int diamsip_default_cb( struct msg ** msg, struct avp * avp, struct session * sess, enum disp_action * act) … … 48 51 } 49 52 50 51 52 53 53 /* entry point */ 54 staticint ds_entry()54 int ds_entry() 55 55 { 56 56 struct dict_object * app=NULL; … … 110 110 CHECK_FCT(fd_sess_handler_create(&ds_sess_hdl, free)); 111 111 112 113 //listnonce=NULL;114 112 return 0; 115 113 } … … 127 125 close_mysql_connection(); 128 126 129 //We delete the chained list of nonces 130 //nonce_deletelistnonce(); 131 //TODO:NONCE 127 132 128 133 129 TRACE_ENTRY(); -
extensions/app_sip/diamsip.h
r364 r368 84 84 85 85 86 staticint ds_entry();86 int ds_entry(); 87 87 void fd_ext_fini(void); 88 88 int diamsip_default_cb( struct msg ** msg, struct avp * avp, struct session * sess, enum disp_action * act); … … 103 103 #define SQL_CLEARFLAG_LEN 74 104 104 105 static struct session_handler * ds_sess_hdl; 106 static struct session *dssess; 105 extern struct session_handler * ds_sess_hdl; 107 106 108 107 … … 114 113 115 114 //Storage for some usefull AVPs 116 st atic struct{115 struct diamsip_dict{ 117 116 struct dict_object * Auth_Session_State; 118 117 struct dict_object * Auth_Application_Id; … … 139 138 struct dict_object * Digest_Algorithm; 140 139 struct dict_object * Digest_HA1; 141 } sip_dict; 140 }; 141 142 extern struct diamsip_dict sip_dict; -
extensions/app_sip/multimediaauth.c
r364 r368 37 37 38 38 39 int diamsip_MAR_cb( struct msg ** msg, struct avp * avp, struct session * sess, enum disp_action * act)39 int diamsip_MAR_cb( struct msg ** msg, struct avp * paramavp, struct session * sess, enum disp_action * act) 40 40 { 41 41 struct msg *ans, *qry; 42 struct avp *a 2, *authdataitem;42 struct avp *avp, *a2, *authdataitem; 43 43 struct msg_hdr * header = NULL; 44 44 struct avp_hdr * avphdr=NULL, *avpheader=NULL, *avpheader_auth=NULL,*digestheader=NULL; … … 48 48 char * result; 49 49 char password[51]; 50 int idx=0, idx2=0, number_of_auth_items=0,i=0; ;50 int idx=0, idx2=0, number_of_auth_items=0,i=0; 51 51 //Flags and variables for Database 52 52 int sipurinotstored=0, authenticationpending=0, querylen=0, usernamelen=0; … … 82 82 { 83 83 CHECK_FCT( fd_msg_avp_new ( sip_dict.Auth_Application_Id, 0, &avp ) ); 84 ASSERT(avp); 84 85 val.i32 = header->msg_appl; 85 86 CHECK_FCT( fd_msg_avp_setvalue ( avp, &val ) ); … … 670 671 DigestCalcResponseAuth(HA1, digest_nonce, digest_noncecount, digest_cnonce, digest_qop,digest_method, digest_uri, HA2, responseauth); 671 672 672 673 TRACE_DEBUG(FULL,"Response calculated by Diameter server:%s",response); 674 TRACE_DEBUG(FULL,"Response calculated by UA:%s",digest_response); 673 675 if(strcmp(digest_qop,"auth-int")==0) 674 676 {
Note: See TracChangeset
for help on using the changeset viewer.