Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6013177
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T02:30:40+00:00 2026-05-23T02:30:40+00:00

What are the best practices, for doing this in .NET? My problem is, I

  • 0

What are the best practices, for doing this in .NET?
My problem is, I want to interact with a webservice, I have created. To make sure no “creative” user, can abuse the service, I want to encrypt the argument (the output is sensitive).

I thought I was being clever, by using webservices, instead of having my application go directly into our DB, but I am apparently not clever enough, to know what to do with the key.

So, how do I store the key, I encrypt the argument with, in my locally installed application?
I would, of course, like to prevent “creative” users, from being able to retrieve it.

I suppose I could feed the key, from a webservice instead, but I don’t really see any benefits to this. People can still just invoke the service, and get the key.

TL;DR
Generally speaking, how do I handle encryption/decryption keys in .NET, when everyone can decompile the code, and get the key (if it is stored in the code)?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T02:30:40+00:00Added an answer on May 23, 2026 at 2:30 am

    A simple way is to store the key in configuration, then encrypt the configuration file (either web.config or app.config) – details are here.

    Another approach is to secure the link to the Web service using a certificate, and embed the certificate into the application as a resource. This would then stop very creative users from using e.g. Wireshark to read the traffic going to and from the service. Details on that are here.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Does anyone have any suggestions/ best practices for doing master/ detail pages using the
Best practices or tools for installing a SQL Server database I have a SQL
Yahoo best practices states that putting JavaScript files on bottom might make your pages
What best practices have you used in unit testing embedded software that are peculiar
I am using ASP.NET MVC with ASP.NET membership. Following best practices for 'I forgot
I have an ASP.NET 3.5 e-commerce site that has an admin section. I want
In an ASP.Net application, the user clicks a button on the webpage and this
Hoping there's been a best practices way to accomplish this so far. Basically, I'm
I'm doing update data into SQL Server in ASP.Net. and I only have a
I have found this tutorial online http://net.tutsplus.com/tutorials/php/creating-a-php5-framework-part-1/ I have created myself a simple sort

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.