SPDH框架分析仪 [英] An analyzer for SPDH frame

查看:421
本文介绍了SPDH框架分析仪的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我必须产生SPDH协议的解析自动机。

I must produce a parsing automat of SPDH protocol.

SPDH定义了在电子支付终端和银行服务器之间交换的请求和响应消息的结构。

SPDH defines the structure of request and response messages exchanged between an electronic payment terminal and the server of the bank.

此协议的规范在本文档中描述:
http://www.trauco.com/docs/SPDH-specification_070212.pdf

The specifications of this protocol are described in this document: http://www.trauco.com/docs/SPDH-specification_070212.pdf

我指定了以下内容语法:

I specified the following grammar for this protocol:

Frame           : = header fids etx ;

header          : = fields ;

fields          : = field fields | epsilon ;

field           : = string | number ;

fids            : = fid FieldSeparator fids | epsilon ;

fid             : = exp | subfids ;

exp             : = string | number| whitespace ;

subfids         : = exp RecordSeparator subfids |epsilon ;

whitespace      : = space whitespace | epsilon ;

space           : = ' ' ;

string          : = letter string | digits string | '-' string | period string |epsilon ;

FieldSeparator  : = period | epsilon ;

RecordSeparator : = '!'| epsilon    ;

number          : = digits number | epsilon    ;

digits          : = '0'|'1'|...|'8'| '9'    ;

letter          : = 'a'|...|'z'|'A'|...|'Z'    ;

period          : = '.'              ;

etx             : = 'ETX'| epsilon  ;



我需要一些帮助来构思我的应用程序和实现我的语法。

I need some help to conceive my application and to implement my grammar.

推荐答案

尝试创建框架的状态图。也许你第一次没有得到它的权利,但这种方式,你会得到一个更好的了解框架结构。

Try creating a state diagram of the frame. Maybe the first time you wown't get it right but this way you will get a better understanding of the frame strucuture.

我会给你一只手,但提供的链接是无法访问的。请通过电子邮件发送文件或发送替代链接。

I would give you a hand but the link provided is not accessible for me. Please email the file or send an alternative link.

这篇关于SPDH框架分析仪的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆