Check whether Old and New Passwords are similar (ASP.NET) [closed] - passwords

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 10 years ago.
I have a Password Reset Functionality ,I have to check whether Old and New Passwords are
similar, If similar or same through error .
If,
Old Password : BradPitt
New Password :JohnPitt
Here passwords are similar
What I have to do is, I have to check whether PASSWORDS ARE ATLEAST 50% SIMILAR. in ASP.NET

This can get very complicated. It all depends on how you define "similar". Once you have that, the rest becomes easier.
Here it may mean: a password is seen as similar if it starts with or ends with the same sequence of at least n characters (say, 4) than the previous one.
Or it may mean: if you count +1 for every place where the character in the old password is the same as in the new password, and have at least 50% of the number of characters the same. In that case, "BradPitt" and "JohnPitt" would be similar, but "BradPitt" and "McDonaldPitt" would not.
So the first thing to do is to define similarity. Implementing it then becomes a snap.
Good luck!

Related

How can I represent this idea to the database design? [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 10 years ago.
I am new to database design, I am trying to build a database of shopping system.
Assume we have a Customer table and a Staff table.
The requirement is:
To allow part of the customers to have privilege of "Item return & refund".
To allow part of the staff to have the authority to process the refund.
My idea is to simply add a column with a Boolean value to "Flag" which customer or which staff has the authority or not?
Is that correct to solve this problem? Any potential problem?
This would be correct for a simplistic design. However, if you want to be able to expand on your website or if your needs grow over time, you may need to allow for more detailed permissions. A user_permissions table and an employee_permission table would be desirable in that case.

Openstreetmap headers and contact infos [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 10 years ago.
I'm trying setting up headers for Openstreetmap. I use AJAX to send requests.
Which HTTP header field is used for contacts? I thought it was "From" but the request doesn't allow that field.
Any suggestions?
So from your clarification about it sounds like you are probably talking about one of our usage policies:
http://wiki.openstreetmap.org/wiki/API_usage_policy
http://wiki.openstreetmap.org/wiki/Tile_usage_policy
http://wiki.openstreetmap.org/wiki/Nominatim_usage_policy
The only one which explicitly talks about contact information seems to be the Nominatim one for the geocoder, though all require a valid User-Agent header to help us identify any problem users.
The best way to send the contact information requested by the Nominatim policy is probably as part of the User-Agent though using a URL parameter will work fine as well - anything that lets the administrators work out who you are from the logs if there is a problem basically.

Dynamic code generation and execution without writing code to database [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 10 years ago.
Is it possible to generate ABAP code and execute it in memory without writing code to DB?
Yes. Use Google. Use Google. Use Google. Use Google. Use Google. (I have to write at least 30 characters although I really don't have anything else to say besides that wanting to generate code dynamically is usually a sign you're on the wrong track.)

RoR - How To Count & Display Comments [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 11 years ago.
I'm looking to have a count of the number of comments left under an article and display it on the index page beside that particular article - like the example here in red circles. Any suggestions as to how I might do this?
The picture is an example of what I'm trying to do, its not my site.
This sounds like a good candidate for Rails.cache. Every time you create a new comment simply increment that cache counter using the post id.
If the cache entry does not exist, do a simple article.comments.count (depends on your domain model of course) query and re-cache it.
Storing it in a cache is one idea, yes.
But storing it in a counter_cache column is probably a better idea. That way even if your server was restarted somehow you wouldn't loose the cached values. See http://guides.rubyonrails.org/association_basics.html, section 4.1.2.4.

Can anybody write the test cases for sticky note? [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 12 years ago.
Test cases for manual testing.
Step by step procedure to test this functionality(sticky note) so that it gives desired output.
Probably that it sticks, stay stuck for awhile, removable (and doesn't leave residue behind), and writable.
if its just the functionalities..
check whether it displays what ur tying in,
check if its saved wen pressing enter,
closes properly,
shows the saved noted wen opened afresh,
can edit previously entered notes,
can b moved form one place to another,
wen restarted it gets displayed at the previous location..