Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re: Golf: Replacing part of a string with "*"

by explorer (Chaplain)
on Aug 18, 2006 at 15:36 UTC ( #568195=note: print w/replies, xml ) Need Help??


in reply to Golf: Replacing part of a string with "*"

More fuzzy (the result)

substr($string,rand length $string,1,"*") foreach 1..12; # 5****23** +*34**7*
Update: No guarantee included :-)

Replies are listed 'Best First'.
Re^2: Golf: Replacing part of a string with "*"
by ikegami (Pope) on Aug 18, 2006 at 15:40 UTC
    That's bad for readability (harder for the user to figure out which one of his cards was used), and it's bad security (since the number could be obtained over time or if multiple retailers did this). And of course, there's are times when two, one and even no digits are hidden.

      I know one bank that use it... but I agree with you...

Re^2: Golf: Replacing part of a string with "*"
by suaveant (Parson) on Aug 18, 2006 at 17:29 UTC
    Actually a couple issues with this, 1) not guaranteed to use any asterisks (usually will), 2) since they are different each time with enough receipts you could get the whole number.

                    - Ant
                    - Some of my best work - (1 2 3)

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://568195]
help
Chatterbox?
[MidLifeXis]: Project Admin, a while ago: "No, I would prefer you didn't close that ticket yet confirming $vendor's support process yet. Continue to periodically check back to see if it has changed."...
[MidLifeXis]: Project Admin, today, after many periodic updates from me: "Why hasn't this been closed yet? Is there anything I can do to get this closed?" <facepalm>
[MidLifeXis]: In addition to SOAP (last hour of cb), try water. ;-)

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (11)
As of 2017-01-19 12:09 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Do you watch meteor showers?




    Results (170 votes). Check out past polls.