If you have a current (rather than past) addiction to illegal drugs, know that the chief priority is health, however in getting into drug rehab or seeing a drug counselor, be careful about disclosing too much to your company's HR representative. You want to maintain your employee benefits and protect your job. (Employees with current drug addictions are not considered disabled whereas recovering addicts are considered disabled and thus enjoy the protections under the Americans with Disabilities Act.)
Ideally, work through your company nurse or medical department if this department exists for your employer, or if you must work with HR, then work exclusively with the individual who handles employee leaves of absence. You or someone who cares for you will need to work with your insurance to get you into a rehab facility and arrange for a company medical leave of absence to verify you are qualified for this.
It's fine to ask HR general questions about a medical leave (Family and Medical Leave of Absence or FMLA and Short Term Disability Leave and whether you meet the criteria). You DON'T have to tell an HR rep that it is drug-related -- it could be a hernia surgery for all they know and either way, it's none of their business. Any medical leave will require authorization forms that a doctor will have to sign and return, and this is normal. These forms are confidential and all medical information should be kept totally separate from your personnel file. Expect to be drug tested before being released to return to work from your leave.
Please understand that you are not the first and not the last person to have a drug addiction although you may feel alone. Your first priority is your health but also you owe it to your coworkers and others you interact with not to work in an altered state. Think of their health and safety working alongside an addict.
GET HELP TODAY by taking that first step. You can do this, friend.