Preview

engineering ethics

Satisfactory Essays
Open Document
Open Document
643 Words
Grammar
Grammar
Plagiarism
Plagiarism
Writing
Writing
Score
Score
engineering ethics
Genrate 7 letters password
; Example3.asm: A Simple Random Password Generator (7 characters)

.386
.model flat, STDCALL

; INCLUDE FILES include \masm32\include\kernel32.inc include \masm32\include\windows.inc include \masm32\include\user32.inc include getseg.inc ; Our include file

; LIBRARY includelib \masm32\lib\kernel32.lib includelib \masm32\lib\user32.lib includelib getseg.lib ; Our include file

; random number generating function
Random PROTO :DWORD,:DWORD

.data msg_caption db "Random password generator",0 my_data db "a:b:c:d:e:f:g:h:i:j:k:l:m:n:o:p:q:r:s:" db "t:u:v:w:x:y:z:A:B:C:D:E:F:G:H:I:J:K:L:" db "M:N:O:P:Q:R:S:T:U:V:W:X:Y:Z:0:1:2:3:4:" db "5:6:7:8:9",0

out_data db 123 dup(0) ; pass_out db 123 dup(0) ; ctr dd 0 ;

.code start: Passloop:

invoke Random, 1,62 ; random number generator function invoke GetSegStr, ADDR my_data, eax, ":", ADDR out_data ; get a random character from the table invoke lstrcat, ADDR pass_out, ADDR out_data ; add character to pass_out invoke Sleep, 10 ; for random numgen function (GetTickCount) add ctr, 1 ; increment loop counter cmp ctr, 7 ; does pass_out contain 7 characters already? jne Passloop ; nah, add some more random character
Done:

; Display randomly generated password invoke MessageBox, NULL, ADDR pass_out, ADDR msg_caption, MB_OK

; got this random number generator function from some masm board posting

Random PROC first:DWORD,second:DWORD
LOCAL rand:DWORD

invoke GetTickCount mov rand, eax

mov ebx,second sub ebx,first inc ebx xor edx,edx mov eax,rand div ebx add rand,eax add edx,first mov eax,edx ret Random ENDP

invoke ExitProcess,0 end start

Check Validity of Password
.386
.model flat,stdcall option casemap:none

You May Also Find These Documents Helpful

  • Powerful Essays

    Ethics Case Analysis

    • 1127 Words
    • 4 Pages

    “It depends on how careful they were, if they were there at all. We’re checking on that.”…

    • 1127 Words
    • 4 Pages
    Powerful Essays
  • Satisfactory Essays

    Hrm Labor

    • 363 Words
    • 2 Pages

    | (TCO 2) Use the ____ data type for columns that contain letters and special characters and for columns containing numbers that will not be used in calculations.…

    • 363 Words
    • 2 Pages
    Satisfactory Essays
  • Powerful Essays

    Megastat

    • 6791 Words
    • 28 Pages

    5 Output ............................................................................................................................ 5 Repeat Last Option....................................................................................................... 5 Generate Random Numbers ........................................................................................ 6 Utilities ........................................................................................................................... 6 Insert descriptive information ..........................................................................................6 ChartDataSheet utilities ..................................................................................................…

    • 6791 Words
    • 28 Pages
    Powerful Essays
  • Good Essays

    Ethics Case Study

    • 824 Words
    • 3 Pages

    Dr. Williams assistant Jerry does have the training but does not have the ability to make a call for a patient because if he prescribed the wrong dosage amount then there will be in trouble with the patient and also with HIPAA. It will not be in the best interest of Jerry to make this call for Dr. Williams without making a call to Dr. Williams first. In order for this to happen without breaking any laws, Jerry needs to have communication with Dr. Williams. To keep the integrity of office Jerry should ensure that the proper medication and make sure that it is the patient’s correct prescription if Dr. Williams gives the okay for jerry to provide the Valium for the patient. This might have to be a medication that this patient have to go without on his trip.…

    • 824 Words
    • 3 Pages
    Good Essays
  • Powerful Essays

    Final exam Review Guide

    • 3135 Words
    • 13 Pages

    Researchers can use a table of random numbers to randomize. A small portion of such a table is shown in Table 9.2. In a table of random numbers, any digit from 0 to 9 is equally likely to follow any other digit.…

    • 3135 Words
    • 13 Pages
    Powerful Essays
  • Good Essays

    Ethics Case Study

    • 819 Words
    • 4 Pages

    Medical laws have been put into place to protect not only the patient, but also the physicians, nurses, and medical office staff. The laws were put into place to ensure that these professionals follow the correct procedures and steps that only qualified persons follow. The definition of practicing medicine has also been clearly explained. Those professionals who do not abide by these set laws are therefore subject to punishment by law (Baxter 2005).…

    • 819 Words
    • 4 Pages
    Good Essays
  • Good Essays

    Ethics Case Study

    • 1136 Words
    • 5 Pages

    Everyday health care workers around the world are faced with tough decisions. The law guides many decisions but some decisions require ethical considerations. Making good ethical decisions is not always as easy as it seems. Making ethical decisions is even harder when the primary intention is to be helpful, but it is beyond an employee’s qualifications.…

    • 1136 Words
    • 5 Pages
    Good Essays
  • Good Essays

    The long debated question of the importance of men and women and their roles has raged on for years. Should men and women be treated equally, that truly is the question that seems to have more answers than resolution. Applying the question to Deontology and the work of Immanuel Kant, the answer would be all people regardless of gender should be treated equally. However, these theories do not take into account the actions of the male or female in question. The question still remains, should men and women be treated equally or should it be based on the situation, all accounts will be taken into further consideration.…

    • 756 Words
    • 2 Pages
    Good Essays
  • Satisfactory Essays

    Ethics Case Study

    • 715 Words
    • 3 Pages

    In the scenario Jerry McCall is Dr. Williams office assistant. Jerry has received training for a medical assistant and licensed practical Nurse. Although Jerry is handling the incoming calls while the receptionist is at lunch a patient of Dr. Williams had called in the office and stated that he needed two refill an antidepressant and Valium right away because he is leaving the airport within 30 minutes. The patient states that Dr. Williams always gives him a small supply of Valium when he goes to fly. Does Jerry have the correct medical training to refill this type of prescription? If it were another type of medication, such as high blood pressure to be ordered to take on daily basis would this make a difference for Jerry to call in the refill? I f Jerry calls in the prescription and the patient has a reaction while flying is Jerry protected from a lawsuit under the doctrine of respondeat superior?…

    • 715 Words
    • 3 Pages
    Satisfactory Essays
  • Satisfactory Essays

    applying ethics

    • 528 Words
    • 2 Pages

    This brief synopsis as a human service worker in which I make every effort to help people, groups, and communities to triumph over their issues and struggles. As a human service worker I almost certainly would come across many ethical predicaments that involve susceptible issues such as discrimination, social unfairness, and oppression, poverty, substance abuse and mental health issues. As a human service worker or provider my personal principles may become an ethical difficulty with reference to discrimination of any sort because of my private belief but of course I am conscious of how many ethical standards that can be challenged if I allow my individual view to develop into concern. Nevertheless of course I identify with knowing and should no bet use as an unbiased conclusion unless the circumstances turn out to be dangerous to myself or the client involved. Next, if this circumstance come to pass then I would use the code of moral principles produced by the national association of human service workers as a most important point addressing ethical predicament which it may cause. On the other hand, I was in a circumstance where a person that I was helping he was very serious and clear in his mind and full detail about who he wanted to work with and talk too. He was discriminating against a co worker because of skin color and race although we were on the job and others was watching him he decided to be rude and very sarcastic for no apparent reason. I wanted to voice my opinion but I didn’t but finally one day I decided to read the code of ethics at work and fill out a report on him with other co workers so that the discrimination could stop. It ended up being better than before the man was disciplined but functioning in the human service department there will be times when you do not agree with your client and your own principles could turn…

    • 528 Words
    • 2 Pages
    Satisfactory Essays
  • Good Essays

    Chapter 6 solutions

    • 4145 Words
    • 41 Pages

    b. Modify the reverse-display program so that the user can enter up to 10 numbers…

    • 4145 Words
    • 41 Pages
    Good Essays
  • Satisfactory Essays

    HCS12 microcontroller is an 8bit microcontroller, manufactured by Free scale Semiconductors. It has three 8bit registers (A, B, CCR) and four 16bit pointers(X, Y, SP, PC).…

    • 328 Words
    • 2 Pages
    Satisfactory Essays
  • Good Essays

    Ethics Case Analysis

    • 1712 Words
    • 7 Pages

    This case presents a very typical situation that people encounter while working in the corporate environment. What is ethical, what is morally correct and what is just right out against the law are the questions that we all face while working in a corporate environment. Some of the ethical questions are governed by the law facing the situation. For example while working in an investment bank you most probably have access to inside information about upcoming deals that one could possibly use for personal monetary gain or you could act as a tippie and possibly share that confidential information with others. This kind of a situation is definilety governed by the law and you can actually be charged with various insider trading laws and possibly do some jail time as well. The other situation that is presented in the case is purely about ones ethical and moral standards. The analyst either has to compromise her loyalty towards her company B&B or towards her best friend Lori. While the situation presented is not a real zero-sum game, i.e., one player’s loss does not equal to the gain of the other player. When faced in a situation like this one has to think about what decisions can be made that will have the least affect on the players involved. The analyst should not look at the situation she faces as black or white. She should rather think about other options she might have to retain her friend’s loyalty while not compromising her loyalty towards her current employer. For example, Lori has already been laid off by her current employer, Universal group. The Universal group has already broken certain ethical and moral laws by not informing about the situation to B&B. So can the analyst come up with a situation where she can get Lori immediately and legally hired at B&B and convince her to share the information with B&B. In essence Lori will not have to feel guilty about not keeping the information confidential as has been laid off and the…

    • 1712 Words
    • 7 Pages
    Good Essays
  • Powerful Essays

    Ethics and Safety essay

    • 879 Words
    • 4 Pages

    5. Briefly explain the following approaches to handling ethical behavior: best ratio, black and white, full potential.…

    • 879 Words
    • 4 Pages
    Powerful Essays
  • Good Essays

    Computers have an important role in our day to day life. Software engineers contribute directly in developing and maintaining all these machines, indispensable to our life. Because their role is so important in developing software systems, software engineers have chance to do good, cause harm, or to allow others to do bad things. To ensure that they work for the good side, software engineers must commit themselves to making software engineering a beneficial and respected profession.…

    • 629 Words
    • 3 Pages
    Good Essays

Related Topics