Connecting declarative software tools Declarative tools [for] - - PowerPoint PPT Presentation

connecting declarative software tools
SMART_READER_LITE
LIVE PREVIEW

Connecting declarative software tools Declarative tools [for] - - PowerPoint PPT Presentation

Connecting declarative software tools Declarative tools [for] connecting software Salvador Lucas Dep. de Sistemas Informticos y Computacin Universidad Politcnica de Valencia slucas@dsic.upv.es Summary Connecting declarative software


slide-1
SLIDE 1

Connecting declarative software tools Declarative tools [for] connecting software

Salvador Lucas

  • Dep. de Sistemas Informáticos y Computación

Universidad Politécnica de Valencia slucas@dsic.upv.es

slide-2
SLIDE 2

Summary

 Connecting declarative software tools:

 The verifying compiler project  Concrete problems  Interoperability for declarative tools and languages

 Declarative tools for connecting software:

 Models and logics for Web analysis and development  Declarative models for security protocols

 Conclusions and future work

slide-3
SLIDE 3

Connecting declarative software tools

slide-4
SLIDE 4

Connecting declarative tools

 As part of the 50th anniversary of the Journal of

the ACM, an special issue of the journal by highly renowned researchers was published (Journal of the ACM vol 50, issue 1, January 2003)

 The aim was to establish the most important

challenges in Informatics and Computer Science for the XXI century

slide-5
SLIDE 5

Connecting declarative tools

 The verifying compiler: a grand (although

classic!) challenge revisited by T. Hoare

 Program verification, program debugging,

and program analysis will be essential components of such a tool

 Its effective development will require an

incremental and cooperative effort from different work teams all around the world

slide-6
SLIDE 6

Motivation: declarative languages

Maude Interpreter

MU-TERM CiME

User’s program Constraints Report of proof Solution (coeff)

slide-7
SLIDE 7

Motivation: declarative languages

How to connect these tools for automatically proving termination of such programs?

slide-8
SLIDE 8

Connecting software tools: concrete problems

slide-9
SLIDE 9

Connecting tools: concrete problems

Maude Interpreter

MU-TERM CiME

No connection Exchange file

slide-10
SLIDE 10

Connecting tools: concrete problems

Maude Interpreter

MU-TERM CiME

Haskell C++ OCaml Data structures:

Although they could be linked as object modules, the data representations should be (made) compatible for exchanging data through primary memory

slide-11
SLIDE 11

Connecting tools: concrete problems

Maude Interpreter

MU-TERM CiME CS restrictions Concrete syntax Constraint solving

Distributed:

Proofs of termination of Programs involve different kinds of knowledge and

  • expertise. Combining

different tools to prove termination is often necessary

slide-12
SLIDE 12

Connecting tools: concrete problems

Maude Interpreter

MU-TERM CiME

Laptop Laptop Server (Intra/Inter Net) Efficiency:

Proofs of termination involve search problems which are costly. Having specialized servers devoted to prove termination can be useful

slide-13
SLIDE 13

Connecting tools: concrete problems

Maude Interpreter

MU-TERM CiME

International:

Maude is developed and maintained (mainly) by the UIUC and SRI at USA; MU-TERM has been made at the UPV (Spain) CiME is being developed at the U. Paris VII (France) Spain France USA

slide-14
SLIDE 14

Connecting applications: interoperability

slide-15
SLIDE 15

Connecting applications

 Interoperability: making possible for a

program on one system to get access to programs and data on another system

 Solutions: Middleware systems, e.g.,

 COM  .NET  XML WWW Services

slide-16
SLIDE 16

Connecting applications

 Example: .NET: A core language (CLR) provides an

abstract machine to implement more sophisticated languages:

 C++ (or C#),  Java (or Java#)  ML,  Haskell (Mondrian), etc.

The implementations can use a number of

libraries (for GUIs, remote access,…)

slide-17
SLIDE 17

Connecting applications

 .NET Remoting:

Client Stub Proxy Stub Proxy

Frontier of AppDomain Frontier of AppDomain

Server AppDomains represent local or remote applications

slide-18
SLIDE 18

Connecting applications

 Joining .NET through COM:

Haskell COM Component

EXAMPLE.hs

ExampleProxy.hs

Com.lhs (lib) RTS Example.idl HDirect

RCW

slide-19
SLIDE 19

Connecting applications

 WWW services:

Client XML XML SOAP SOAP

UDDI / WSDL UDDI / WSDL

Server

slide-20
SLIDE 20

Connecting applications

 Common problems Exchanging data Defining remote services Finding external applications / servers Implementing remote calls Receiving results of remote calls

slide-21
SLIDE 21

Connecting software tools: concrete actions

slide-22
SLIDE 22

Connecting applications: actions

 TPDB Recent common format for TRSs and

termination problems:

Conditional equations / rules Strategies Type of problem (TRS, SRS, LP, …)

slide-23
SLIDE 23

Connecting applications: actions

 Add information for specifying proofs  Simple / Cε / DP-Simple termination  Constraint solving  Modular structure  Heuristics (and its combinations)  Ad-hoc partial / external proofs  Use of XML for producing input / output

information on proofs (e.g., for certification purposes)

slide-24
SLIDE 24

Connecting applications: actions

This is an ambitious project which should eventually be agreed / addressed by the interested community. Coordination with some technical groups (e.g., IFIP WG 1.6 or 1.3,…) would be interesting / desirable

slide-25
SLIDE 25

Declarative tools for connecting software

slide-26
SLIDE 26

Declarative tools for connectivity

 Web site: a collection of connected

Web pages

 Dynamic modeling: focus on the transitions

between Web pages

slide-27
SLIDE 27

Rewriting model

p2 p3 p4 p5 p1

href= href= href=

slide-28
SLIDE 28

Rewriting model

p2 p3 p4 p5 p1(U)→ p2(U) p1(U)→ p3(U) p1(U)→ p5(U)

slide-29
SLIDE 29

Rewriting model

p3 p4 p5 p1(U)→ p2(U) p1(U)→ p3(U) p1(U)→ p5(U)

slide-30
SLIDE 30

Rewriting model

p4 p5 p1(U)→ p2(U) p1(U)→ p3(U) p1(U)→ p5(U) p3(u)→ p4(u) p3(u’)→ p5(u’)

slide-31
SLIDE 31

 Term Rewriting System (TRS):

 Rewriting theories: first order logic (with variables

ranging on terms) together with a binary predicate R(x,y) associated to a TRS R:

 R(x,y) = x→ y : one-step rewriting theory  R(x,y) = x→∗ y : rewriting theory

Rewriting model

p1(U)→ p2(U) p1(U)→ p3(U) p1(U)→ p5(U) p3(u)→ p4(u) p3(u’)→ p5(u’)

slide-32
SLIDE 32

Rewriting model and logics

 Example: there is no ‘disconnected’ page:

™y ∃x ((x ≠ y) ∧ ((x → y) ∨ (y → x))) where ‘=‘ is the predicate R(x,y) associated to the empty TRS

 Example: there is no unreachable page (from the ‘main’

page): ™x (main →∗ x) ™x ∃u (main(u) →∗ x)

slide-33
SLIDE 33

Rewriting model and logics

 Example: “there is no ‘disconnected’ page”:

™y ∃x ((x ≠ y) ∧ ((x → y) ∨ (y → x))) where ‘=‘ is the predicate R(x,y) associated to the empty TRS

 Example: “there is no unreachable page (from the ‘main’

page)”: ™x (main →∗ x) ™x ∃u (main(u) →∗ x) ™x (main(u1) →∗ x)∨…∨ (main(un) →∗ x))

slide-34
SLIDE 34

Rewriting model: improvements

 Example: “no ‘unsafe’ access is possible”:

™p ™q ™u ™v ((p(u) → ∗ q(v)) ⇒ (u=v))

 This is a higher-order sentence which does not

belong to any rewriting theory!

slide-35
SLIDE 35

Rewriting model: improvements

 This can be solved by introducing a new binary

symbol to put together web pages and users as constant symbols: e.g., browse(p,u)

 Problem: no decidability results are available!!

™p ™q ™u ™v ((browse(p,u) → ∗ browse(q,v)) ⇒ (u=v))

slide-36
SLIDE 36

Rewriting model: in practice

 Rewriting-based specification languages like Maude are

well-suited to express dynamic models of Web sites

 In Maude a small query language is available (see the

proceedings for some examples)

 Some existential queries are even possible on the basis of

traversing the (finite) state space by using a breadth-first search strategy

slide-37
SLIDE 37

Rewriting model: network protocols

 The NRL Protocol Analyzer (NPA) is a well-known tool

for the formal specification and analysis of cryptographic protocols

 For the first time a precise formal specification of its

grammar-based techniques for invariant generation, one

  • f the main features of the NPA inference system, has been

given

 This formal specification is given within the well-known

framework of the rewriting logic

slide-38
SLIDE 38

Conclusions / future work

slide-39
SLIDE 39

Conclusions

 We are approaching the use of software

tools with more complex systems (e.g., interpreters of programming languages)

 The combination of different tools with

different expertise domain is required here

slide-40
SLIDE 40

Conclusions

 Interoperability issues should be

systematically considered when developing termination tools

 Rewriting-based logics are useful to model

and analyze network systems and Web sites

slide-41
SLIDE 41

Future work

 Which are the appropriate (fragments of)

logics which are useful to specify (and reason about) the dynamic behavior of Web sites?

 How types, strategies, conditions, etc. can

help to get a more expressive model or to improve its power from a logic point of view (e.g., recovering decidability of the theories)

slide-42
SLIDE 42

Salvador Lucas

  • Dep. de Sistemas Informáticos y Computación

Universidad Politécnica de Valencia slucas@dsic.upv.es

Connecting declarative software tools