Welcome to the Coding Planet!
HomeHome  RegisterRegister  Log inLog in  
Post new topic   Reply to topic
 

Proxy Server in C#...

View previous topic View next topic Go down 
AuthorMessage
r1Nu-
Admin
Admin



Age : 18
Joined : 24 Apr 2008
Posts : 17
Location : 192.178.**.**

PostSubject: Proxy Server in C#...   Fri May 02, 2008 8:55 pm

Loipon edw exoume enan Proxy Server...min fantasteite tipota to trelo apla kanei get...exw kai epeksigiseis gia na katalabainoume to ti kanei ti...
einai sta agglika dioti to sikwsa kai se kseno forum kai eprepe na me katalabainoun...kai san diethni forum pou eimaste lol! prepei na mas katalabainoun!!! Smile ehehe! telos pantwn..as pame sto source!

Code:
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using Microsoft.Win32;
 
namespace proxyViolater
{
    public partial class Form1 : Form
    {
        bool alert = false;
        public Form1()
        {
            InitializeComponent();
            checkProxy();
            alert = true;
        }
 
    //check the state of the proxy settings
    //
    //
        private void checkProxy()
        {
            //check the registry for the 'ProxyEnable' value
            RegistryKey proxy = Registry.CurrentUser.OpenSubKey(
        "Software\\Microsoft\\Windows\\CurrentVersion\\Internet Settings", true);
 
            //the possible values are 1 - enabled, or 0 - disabled
            int enabled = int.Parse(proxy.GetValue("ProxyEnable").ToString());
 
            //update the GUI
            if (enabled == 1)
            {
                lblStatus.ForeColor = Color.Red;
                lblStatus.Text = "Enabled";
            }
            else
            {
                lblStatus.ForeColor = Color.Green;
                lblStatus.Text = "Disabled";
            }
        }
 
    //Enable the proxy server
    //
    //
        private void btnEnable_Click(object sender, EventArgs e)
        {
            //connect to the registry and enable the proxy
            RegistryKey cUser = Registry.CurrentUser.OpenSubKey(
        "Software\\Microsoft\\Windows\\CurrentVersion\\Internet Settings", true);
            cUser.SetValue("ProxyEnable", 1);
            checkProxy();
        }
 
    //Disable the proxy server
    //
    //
        private void btnDisable_Click(object sender, EventArgs e)
        {
            //connect to the registry and disable the proxy
            RegistryKey cUser = Registry.CurrentUser.OpenSubKey(
        "Software\\Microsoft\\Windows\\CurrentVersion\\Internet Settings", true);
            cUser.SetValue("ProxyEnable", 0);
            checkProxy();
        }
 
    //Monitor the label that is update on proxy change
    //
    //
        private void lblStatus_TextChanged(object sender, EventArgs e)
        {
            //alert the user to restart the browser after every proxy change event.
            if (alert)
            {
                MessageBox.Show("Please restart all open browsers for proxy change to take effect.");
            }
        }
 
    //Check for proxy changes every 5 seconds
    //
    //
        private void timer1_Tick(object sender, EventArgs e)
        {
            //check to see if the GPO refresh interval has changed the setting back
            checkProxy();
        }
    }
}


Auto einai..perimenw sxolia!!

r1Nu-
Back to top Go down
pr0n




Joined : 07 May 2008
Posts : 2

PostSubject: Re: Proxy Server in C#...   Wed May 07, 2008 6:57 pm

Prwton .. 8elw na pw ena megalo geiaa se olous Smile
Defteron mpenw kateu8eian sto zoumi ths istorias ...




Diabazontas ton parakatw kwdika .. kati de mou kolage kala ... Olo kai kati mou 8umize xwris na mporousa na 8umi8w ti akribws ... Etc "zhtontas boh8eia" apo ena filaraki to "google" .. kateli3a sta parakatw apotelesma ... Sad ta opoia einai an mi ti allo oxi kai poli kolakeutika gia ton feromeno os dhmiourgo tou kwdika ... (de 3erw poios ap tous 2 einai kai pios oxi)

O agaphtos filos (kai admin) r1Nu- autoapokaleite dhmiourgos tou parakatw kwdika .. bebaia sto parakatw site

http://www.codeproject.com/KB/dotnet/proxyViolater.aspx


o dimiourgos tou ferete na einai o :

Quote:
xExTxCx
Status Gold. Member No. 3506066

blog View Member's Blog

Blog: RSS Feed
Messages Posted 14 - Poster
Articles Submitted 7 - Writer
Biography None provided
Location United States United States
Job Title Systems Engineer
Company ETC
Member since Wednesday, November 01, 2006
(1 year, 6 months) [Gold]
Homepage http://antidesign.us


me kwdika :

Code:
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using Microsoft.Win32;

namespace proxyViolater
{
    public partial class Form1 : Form
    {
        bool alert = false;
        public Form1()
        {
            InitializeComponent();
            checkProxy();
            alert = true;
        }

    //check the state of the proxy settings
    //
    //
        private void checkProxy()
        {
            //check the registry for the 'ProxyEnable' value
            RegistryKey proxy = Registry.CurrentUser.OpenSubKey(
        "Software\\Microsoft\\Windows\\CurrentVersion\\Internet Settings", true);

            //the possible values are 1 - enabled, or 0 - disabled
            int enabled = int.Parse(proxy.GetValue("ProxyEnable").ToString());

            //update the GUI
            if (enabled == 1)
            {
                lblStatus.ForeColor = Color.Red;
                lblStatus.Text = "Enabled";
            }
            else
            {
                lblStatus.ForeColor = Color.Green;
                lblStatus.Text = "Disabled";
            }
        }

    //Enable the proxy server
    //
    //
        private void btnEnable_Click(object sender, EventArgs e)
        {
            //connect to the registry and enable the proxy
            RegistryKey cUser = Registry.CurrentUser.OpenSubKey(
        "Software\\Microsoft\\Windows\\CurrentVersion\\Internet Settings", true);
            cUser.SetValue("ProxyEnable", 1);
            checkProxy();
        }

    //Disable the proxy server
    //
    //
        private void btnDisable_Click(object sender, EventArgs e)
        {
            //connect to the registry and disable the proxy
            RegistryKey cUser = Registry.CurrentUser.OpenSubKey(
        "Software\\Microsoft\\Windows\\CurrentVersion\\Internet Settings", true);
            cUser.SetValue("ProxyEnable", 0);
            checkProxy();
        }

    //Monitor the label that is update on proxy change
    //
    //
        private void lblStatus_TextChanged(object sender, EventArgs e)
        {
            //alert the user to restart the browser after every proxy change event.
            if (alert)
            {
                MessageBox.Show("Please restart all open browsers for proxy change to take effect.");
            }
        }

    //Check for proxy changes every 5 seconds
    //2:)
    //
        private void timer1_Tick(object sender, EventArgs e)
        {
            //check to see if the GPO refresh interval has changed the setting back
            checkProxy();
        }
    }
}


Klinontas auto to 8ema 8a h8ela na zhthsw apo ton filo r1Nu na mas diafwtisei panw sto 8ema ...

1.) An r1Nu = xExTxCx
2.) kai an oxi ... tote ti akribws paizei re paidia?? ...

ps.1)Kwdikas apo ton xExTxCx egeine upload [ 3-25-08 ]
ps.2) Oxi tipota allo ... alla kati tetoia 8a perebene kai tous kanones tou forum

Quote:
3) Επίσης posts που έχουν ένα κομμάτι κώδικα μονο ξέρω κλπ κλπ θα σβήνονται κατευθείαν.Οι κώδικες θα είναι όσο πιο αναλυτικοί γίνεται.Επίσης αν ο κώδικας δεν είναι δικός σας από κάτω στο τέλος το όνομα αυτού που είναι.
That's it!


...perimenw gia merikes dieukriniseis Very Happy ... What a Face
Back to top Go down
r1Nu-
Admin
Admin



Age : 18
Joined : 24 Apr 2008
Posts : 17
Location : 192.178.**.**

PostSubject: Re: Proxy Server in C#...   Wed May 07, 2008 7:24 pm

Geia sou pr0n..kai se euxaristw polu...giauto pou ekanes..esteila mail ston xExTxCx gia dieukriniseis giati kai egw den mporw na katalabw ti paizei..auton edw ton eggrapsa prin kairo kai o Brolly an thimamai kala ton eixe dei prin autos o xExTxCx ton kanei paste..alla episis ton exei dei kai o Parkman...pr0n den mporw na katalabw pws to idio source graftike..pantws thnx pou mou to eipes..exw steilei idi mail gia na mou pei kai autos ti egine...pantws to mono sigouro einai oti den ton eklepsa dioti to ekana prin tin imerominia pou exei to upload tou sugkekrimenou atomoou...
auta apo emena..

r1Nu-
Back to top Go down
pr0n




Joined : 07 May 2008
Posts : 2

PostSubject: Re: Proxy Server in C#...   Wed May 07, 2008 7:33 pm

*)Basika sto forum pou exei anebasei ekeinos exei pliri epe3hghsh tou ti akribws kanei ka8e kommati tou kwdika ka8ws kai mas dinei enan pio "akribh" orismo tou ti eidous kwdikas einai ... afou to xarakthrizei ws ... Proxy Violater kai oxi apla "proxy server" opws ekanes esu .. (+ executables_)

*)Den eimai edw gia na krinw pios ekane ctrl-c ctrl-v to kwdika .. kai opws oloi eides ouden kripton upo to google .. apla 8a h8ela otan kapoios kanei ena post .. na koitaei gia tetoies toixon "pare3hghseis" idika otan briskete se hgetiki 8esh opws auth tou admin Smile

*)Ta sxolia mou einai se panta filiko tono .. apla 8a 8ewrousa san na koroideuw ton eauto mou an to ekana gargara logo ths gnwrimias mas kai ths koinhs mas poria stos s3cure.gr .. apla pisteuw oti to la8os (h an exei ginei pare3hghgsh zhtw sugnwmh) prepei na legete me kapws pio xuma tropo gia na mhn epanalabanete !! ..

auta apo emena...
Back to top Go down
r1Nu-
Admin
Admin



Age : 18
Joined : 24 Apr 2008
Posts : 17
Location : 192.178.**.**

PostSubject: Re: Proxy Server in C#...   Wed May 07, 2008 8:16 pm

Ok pr0n nai exeis dikio..kai eimai mazi sou...apla to thema einai oti egw to source to eggrapsa kai to eggrapsa prin kairo..otan eixa arxisei na mpainw gia ta kala sto zoumi tis C#...kai opws eipa esteila to mail se auton pou leei oti exei grapsei to source..apla twra sto na apodeiksw oti eggrapsa to source mporw na kanw mono to eksis na sou pw oti polu apla to eggrapsa to en logo programma dioti tote asxoliomoun me proxy servers kai se java kai ithela na dw pws douleuei kati paromoio se C# an einai pio eukolo i pio diskolo...kai afou eggrapsa prwta ton proxy server se java apofafisa na ton grapsw kai C# gia na dw tin xrisi tou stin pragmatikotita..bebaia twra oti kai na leme i megali malakia einai i eksis...o sugkekrimenos user exei kanei kai license..to kserw oti dinei polles analutikes plirofories opws kai allagi tou onomatos..kai egw ton exw onomasei Proxy Server..ara auto simainei polla..an ithela na kanw kati tetoio...den tha to onomaza etsi pou einai polu eukolo ontws psaxnontas sto google na breis kati tetoio...ara tha hmoun xazos na nomizw oti kaneis den mporei na to brei klp klp...episis exw kapoies skepseis gia to pws brike to source mou alla kai pali xwris na mou kanei reply sto mail mou kai na paradextei oti egine auto..tote den mporw na kanw tpt allo...opoios pisteuei oti einai diko mou as to pistepsei..alliws as meinei se auton ton user...telos pantwn..tha doume..mporei kai na mou apantisei..pantws an den mou apantisei tha kanw report to post pou exei kanei autos sto site pou mou edwses..einai to mono pou mporw na kanw... twra o kathenas as parei tin pleura pou thelei na parei!

r1Nu
Back to top Go down

Proxy Server in C#...

View previous topic View next topic Back to top 
Page 1 of 1

Permissions of this forum:You cannot reply to topics in this forum
Code-Masters :: Coding :: C#-
Post new topic   Reply to topic