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

  • SEARCH
  • Home
  • 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 8014671
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T20:00:47+00:00 2026-06-04T20:00:47+00:00

We have a server that securely sends a key to the client via a

  • 0

We have a server that securely sends a key to the client via a custom login program. The key is subsequently used for encrypting further client requests. That key is kept on the client’s disk, like a cookie, and is used by a program that might be started and stopped multiple times before the client decides to logout and cause the key to be obsolete (hence the key is saved on disk, because there may be long periods between login and logout when no program is running).

It would seem to be a bit more secure to keep the key only in memory instead of on disk (it’s OK if a crash or restart loses the key and subsequently forces a new login).

On Windows, what’s the best way to retain the key only in memory (ignoring that the memory might be virtual and paged to disk) between separate executions of a program?

One possible solution is to leave a trivial Windows service running on the client that accepts the key, retains it in the service’s memory, and returns it upon request (or use an equivalent trivial DDE server that does the same thing). A non-.net solution is preferred.

Is there a standard Windows service usually running that already provides this ability?

Is there a better approach?

  • 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-06-04T20:00:49+00:00Added an answer on June 4, 2026 at 8:00 pm

    There are probably a couple of solutions you can try that does not involve a running process:

    • Store it in a volatile registry key (REG_OPTION_VOLATILE)

    • Store it in the global atom table. The key has to be stored as a string. You would probably require two atoms; one that stores the key and one used to locate the first atom so you can call GlobalGetAtomName. The second atom should have a known name like “YourAppName:S-UsersSidGoesHere” so you can call GlobalFindAtom.

    If you decide to store it in a file in %temp% you could use TOKEN_STATISTICS.AuthenticationId as part of a key used to encrypt the real key. You could encrypt the file itself with EFS (FILE_ATTRIBUTE_ENCRYPTED)…

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

Sidebar

Related Questions

I have server application that listens for clients. Let's client lost internet connection and
On our server, we have several periodical jobs that login to external accounts through
I have an issue when a client (not mine) connects to my server securely.
I have a server that is running Ubuntu Linux Server Edition. I once had
I have a server that has several virtual machines running on it. I'm trying
I have a server that connects to multiple clients using TCP/IP connections, using C
I have a server that I have no control over, it's JSON based and
I have a server that communicates to a lot of devices (>1000). Each connection
I have a server that receives various xml messages from clients (one thread per
Alright, I have a server that serves a motion-jpeg stream over http. What I

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.