Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PER constraints on REAL are not respected #148

Open
mouse07410 opened this issue Apr 18, 2017 · 1 comment
Open

PER constraints on REAL are not respected #148

mouse07410 opened this issue Apr 18, 2017 · 1 comment

Comments

@mouse07410
Copy link

mouse07410 commented Apr 18, 2017

Example:

Test2c DEFINITIONS ::=
BEGIN

Test2c ::= SEQUENCE {

      count  INTEGER (40..20000),
      weight REAL (1.00 .. 21999.00),
      data   OCTET STRING SIZE (40..20000)
}

END

Generated code accepts the following PDU with no problem, complaint, or report:

<Test2c>
    <count>41</count>
    <weight>0</weight>
    <data>
        26 EA 13 16 98 8E D2 ED 35 05 4B 77 08 D9 CD 13 
        00 A1 F7 76 32 E9 B1 BC 14 F9 83 BC 35 B4 D1 49 
        24 28 74 2B 59 DF 88 A8 50
    </data>
</Test2c>

@velichkov if you know how to fix it, please feel free to submit a PR against my fork. ;-)

Update. OSS tools don't seem to respect constraints on REAL, but does that mean we shouldn't...?

velichkov added a commit to velichkov/asn1c that referenced this issue Apr 18, 2017
mouse07410 referenced this issue in mouse07410/asn1c Apr 18, 2017
velichkov added a commit to velichkov/asn1c that referenced this issue Apr 19, 2017
brchiu pushed a commit to brchiu/asn1c that referenced this issue Apr 20, 2017
brchiu pushed a commit to brchiu/asn1c that referenced this issue Apr 20, 2017
@vlm
Copy link
Owner

vlm commented May 8, 2017

We should respect REAL constraints. Thank you!

attina pushed a commit to attina/asn1c that referenced this issue Dec 26, 2023
jer: GraphicString missing operation definition
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants