emulate PHP "crypt" function in c#?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • JamesB

    emulate PHP "crypt" function in c#?

    Not sure if this is possible, but has anyone seen (or know how to do)
    emulation of the PHP "crypt" function from within c#?

    Thanks

  • rossum

    #2
    Re: emulate PHP "crypt&quo t; function in c#?

    On Wed, 5 Mar 2008 09:26:08 -0000, "JamesB"
    <jamesb@somewhe re.com.net.com. netwrote:
    >Not sure if this is possible, but has anyone seen (or know how to do)
    >emulation of the PHP "crypt" function from within c#?
    >
    >Thanks
    According to http://www.phpbuilder.com/manual/en/function.crypt.php
    the PHP cryp() function may use either DES or MD5. Both of these are
    available in .NET

    rossum

    Comment

    • Roger Frost

      #3
      Re: emulate PHP &quot;crypt&quo t; function in c#?

      "rossum" <rossum48@coldm ail.comwrote in message
      news:isrss39uea mhhqp1fbheg1l1m hjumi8gcv@4ax.c om...
      On Wed, 5 Mar 2008 09:26:08 -0000, "JamesB"
      <jamesb@somewhe re.com.net.com. netwrote:
      >
      >>Not sure if this is possible, but has anyone seen (or know how to do)
      >>emulation of the PHP "crypt" function from within c#?
      >>
      >>Thanks
      According to http://www.phpbuilder.com/manual/en/function.crypt.php
      the PHP cryp() function may use either DES or MD5. Both of these are
      available in .NET
      >
      rossum
      >

      There is also such a thing as a PHP .NET complier. In a pinch you could
      incorporate it that way, but I'm not sure what other PHP runtime components
      are required.


      See http://www.php-compiler.net/doku.php


      --
      Roger Frost
      "Logic Is Syntax Independent"



      Comment

      • JamesB

        #4
        Re: emulate PHP &quot;crypt&quo t; function in c#?


        "Jon Skeet [C# MVP]" <skeet@pobox.co mwrote in message
        news:MPG.22387f b750c6fe43a50@m snews.microsoft .com...
        JamesB <jamesb@somewhe re.com.net.com. netwrote:
        >Not sure if this is possible, but has anyone seen (or know how to do)
        >emulation of the PHP "crypt" function from within c#?
        >
        Are you just trying to do cryptography in general, or does it have to
        match the exact format/functionality of PHP's "crypt" function?
        >
        Ideally I want to be able to "crypt" a string in a c# app, and get the same
        hash that a bit of php code on a webserver would generate... I'll have a
        play with the built in .net stuff and see what comes out I guess...
        Thanks

        Comment

        Working...