From manuelsc at um.es Thu Mar 26 08:41:54 2009 From: manuelsc at um.es (=?ISO-8859-1?Q?Manuel_S=E1nchez_Cuenca?=) Date: Thu, 26 Mar 2009 13:41:54 +0100 Subject: [Avispa-users] Problem with sets Message-ID: <49CB7812.5070108@um.es> Hi all, I have some problems using sets in the HLPSL specification of a protocol. I have the set SSLInfo : (agent.public_key) set which is initialized as SSLInfo := {a.ka,b.kb} The purpose of this set is to provide the public key for a given agent. The problem is that if the variable representing the agent has been initialized in a transition of the role, the process works correctly. for example: local A: agent, N1: text 1. State = 1 /\ RCV(A'.N1') /\ in(A'.Ka',SSLInfo) =|> ... % In this case, Ka' is assigned with the right value, that is ka On the contrary, if the variable representing the agent has been received as a parameter of the role, the key is assigned always to the last element in the set. Event the variable of the agent, that is not primed, is assigned to the agent associated with that key. For example: role bob( A,B : agent, ... 1. State = 1 /\ RCV(A.N1') /\ in(A.Ka',SSLInfo) =|> ... % In this case, Ka' is assigned to kb and A (note that is not primed) is assigned to b. Does anybody know what the problem is? Thanks in advance. -- ----------------------------- Manuel Sanchez Cuenca Departamento de Ingenieria de la Informacion y las Comunicaciones Departamento de Ingenier?a y Tecnolog?a de Computadores Facultad de Informatica. Universidad de Murcia Campus de Espinardo - 30080 Murcia (SPAIN) Tel.: +34-968-364644 Fax: +34-968-364151 email: msc at dif.um.es | manuelsc at um.es url: http://webs.um.es/manuelsc From manuelsc at um.es Thu Mar 26 12:12:16 2009 From: manuelsc at um.es (=?ISO-8859-1?Q?Manuel_S=E1nchez_Cuenca?=) Date: Thu, 26 Mar 2009 17:12:16 +0100 Subject: [Avispa-users] Problem with sets In-Reply-To: <49CB7812.5070108@um.es> References: <49CB7812.5070108@um.es> Message-ID: <49CBA960.4090304@um.es> I forgot to specify that I'm analyzing this code using the graphic tool SPAN. Maybe, some of the developers of this tool can help me. I have attached two hlpsl files wich show this problem. Manuel S?nchez Cuenca escribi?: > Hi all, > > I have some problems using sets in the HLPSL specification of a protocol. > > I have the set > > SSLInfo : (agent.public_key) set > > which is initialized as > > SSLInfo := {a.ka,b.kb} > > The purpose of this set is to provide the public key for a given agent. > The problem is that if the variable representing the agent has been > initialized in a transition of the role, the process works correctly. > for example: > > local A: agent, > N1: text > > 1. State = 1 /\ RCV(A'.N1') > /\ in(A'.Ka',SSLInfo) =|> ... > > % In this case, Ka' is assigned with the right value, that is ka > > On the contrary, if the variable representing the agent has been > received as a parameter of the role, the key is assigned always to the > last element in the set. Event the variable of the agent, that is not > primed, is assigned to the agent associated with that key. For example: > > role bob( > A,B : agent, > ... > > 1. State = 1 /\ RCV(A.N1') > /\ in(A.Ka',SSLInfo) =|> ... > > % In this case, Ka' is assigned to kb and A (note that is not primed) > is assigned to b. > > Does anybody know what the problem is? > > Thanks in advance. > > > > > -- ----------------------------- Manuel Sanchez Cuenca Departamento de Ingenieria de la Informacion y las Comunicaciones Departamento de Ingenier?a y Tecnolog?a de Computadores Facultad de Informatica. Universidad de Murcia Campus de Espinardo - 30080 Murcia (SPAIN) Tel.: +34-968-364644 Fax: +34-968-364151 email: msc at dif.um.es | manuelsc at um.es url: http://webs.um.es/manuelsc -------------- next part -------------- An embedded and charset-unspecified text was scrubbed... Name: set_test_ko.hlpsl Url: http://mail63.csoft.net/pipermail/avispa-users/attachments/20090326/f9a6a2e3/attachment.ksh -------------- next part -------------- An embedded and charset-unspecified text was scrubbed... Name: set_test_ok.hlpsl Url: http://mail63.csoft.net/pipermail/avispa-users/attachments/20090326/f9a6a2e3/attachment-0001.ksh From laurent.vigneron at loria.fr Tue Mar 31 11:53:35 2009 From: laurent.vigneron at loria.fr (Laurent Vigneron) Date: Tue, 31 Mar 2009 17:53:35 +0200 Subject: [Avispa-users] Problem with sets In-Reply-To: <49CBA960.4090304@um.es> References: <49CB7812.5070108@um.es> <49CBA960.4090304@um.es> Message-ID: <49D23C7F.6020805@loria.fr> Dear Manuel, I did not see any problem in your reasoning about sets. However, could you check the next remarks, some of them looking like specification corrections...? ;) - in set_test_ok.hlpsl, role bob: replace /\ secret(N2',secret,{A',B}) by /\ secret(N2',secret,{A',B}) as A is learnt in that transition. - in set_test_ko.hlpsl, role alice: replace(???) 2. State = 2 /\ RCV({B.N2'}_Kb') by 2. State = 2 /\ RCV({B.N2'}_Ka) otherwise you do not specify the same protocol... as the OK one (and also according to the bob role) I hope this will help. Best regards, Laurent.