All of lore.kernel.org
 help / color / mirror / Atom feed
From: Denis Kenzior <denkenz@gmail.com>
To: ofono@ofono.org
Subject: Re: Ofono has too tight limits for SIM lock code lengths
Date: Thu, 20 Jan 2011 11:35:16 -0600	[thread overview]
Message-ID: <4D387254.1050706@gmail.com> (raw)
In-Reply-To: <1295427884.3171.0.camel@jussi-desktop>

[-- Attachment #1: Type: text/plain, Size: 1217 bytes --]

Hi Jussi,

On 01/19/2011 03:04 AM, Jussi Kangas wrote:
> Hi,
> 
> I've been testing SIM locks with Ofono and it looks to me that method
> is_valid_pin in src/common.c has somewhat too tight rules for PIN
> lenghts. SIM or subsidy lock codes can be longer than 8 digits (as
> dictated in 22.022 chapter 14)
> 

You might very well be correct.  The current assumptions are based on
11.11, but I'm not sure if USIMs or newer have relaxed these
restrictions.  Maybe others can chime in here.

> There are several ways to fix this. My current favourite is changing the
> is_valid_pin so that it takes the actual return value of
> sim_string_to_passwd instead of pin_type enumaration as parameter and
> checks with 16-digit limit the SIM locks.
> 
> Other option that comes to my mind would be separate a valid check
> method for SIM locks. 
> 
> As third option I suggest adding fifth value to pin_type enumeration and
> give that as a parameter for is_valid_pin to make it use different
> limits. It would require more specific code type recognition in calling
> function though. 

The first option sounds reasonable to me as a first attempt.  Care to
submit a proposal?

Regards,
-Denis

  reply	other threads:[~2011-01-20 17:35 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-01-19  9:04 Ofono has too tight limits for SIM lock code lengths Jussi Kangas
2011-01-20 17:35 ` Denis Kenzior [this message]
  -- strict thread matches above, loose matches on Subject: below --
2011-01-27 12:52 Jussi Kangas
2011-01-27 13:09 ` Marcel Holtmann
2011-01-27 14:31   ` Jussi Kangas
2011-01-28 15:20     ` Pekka Pessi

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-all 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=4D387254.1050706@gmail.com \
    --to=denkenz@gmail.com \
    --cc=ofono@ofono.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.