public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: Atul Gupta <atul.gupta@chelsio.com>
To: "edk2-devel@lists.01.org" <edk2-devel@lists.01.org>
Subject: VFR validation of IP address and iSCSI IQN
Date: Thu, 11 Jan 2018 06:51:34 +0000	[thread overview]
Message-ID: <CY4PR1201MB02306E24DC01BBD6CB0932C597160@CY4PR1201MB0230.namprd12.prod.outlook.com> (raw)

Hi,

I want to validate IP address and iSCSI IQN within the vfr form. Want to avoid callback hence removed the INTERACTIVE flags, tried few things but none seems to work except for input length check, how to validate the input buffer.

Eg:

string  name    = iqn,
            varid   = UD_CONFIG_IFR_NVDATA.InitiatorName,
            prompt  = STRING_TOKEN(STR_ISCSI_CONFIG_INIT_NAME),
            help    = STRING_TOKEN(STR_ISCSI_CONFIG_INIT_NAME_HELP),
            flags   = 0,
            key     = KEY_INITIATOR_NAME2,
            minsize = 8,
            maxsize = ISCSI_NAME_IFR_MAX_SIZE,
                                             inconsistentif prompt = STRING_TOKEN(STR_INVALID_IQN),
                                             NOT
                                             pushthis != stringref(STRING_TOKEN(STR_STRING_CHECK))
                                             endif
    endstring;

also tried
span (flags = LAST_NON_MATCH, pushthis, stringref(STRING_TOKEN(STR_STRING_CHECK)), 0) != 0, but did not help.

Any reference to validate the input buffer?

Thanks
Atul


             reply	other threads:[~2018-01-11  6:46 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-11  6:51 Atul Gupta [this message]
2018-01-11  7:31 ` VFR validation of IP address and iSCSI IQN Bi, Dandan
2018-01-11  7:57   ` Atul Gupta

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-list from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CY4PR1201MB02306E24DC01BBD6CB0932C597160@CY4PR1201MB0230.namprd12.prod.outlook.com \
    --to=devel@edk2.groups.io \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox