i have this code to connect and login to a HTTPS website Now when i run it i get a 500 code error and if i print out the html of the website it says something went wrong. This is the website [URL]
So far i've built an array of char W= wall, O=open, R= rat, and P= path
I have another class "RAT" which will navigate through the maze. so im having trouble with the method to get the position of the rat when it is navigating through maze. this is what i have.
public class FinalMaze { static char[][] mazeArray = new char[][] { {'o','o','o','o','o','o'}, {'o','w','w','r','w','o'}, {'o','w','p','p','w','o'}, {'o','w','p','w','w','o'}, {'o','w','p','p','w','o'}, {'o','w','w','p','w','o'}, {'o','w','w','p','w','o'}, {'o','o','o','o','o','o'}, };
I have to write a code for File Transfer Protocol! It says that I only need to write code for client, but it also says that I have to run the program and send some files to server. I guess than I also need server side as well. I have to write my own classes, I cannot import some existing classes. I have to connect to the server with password and username and after that send some files to the server. I don't know anything about FTP. Can i maybe do this by Sockets and ports? I worked something with that.
This resource is about a login page.But when I logout or when I visit some pages like Contacts or Home Page, I wouldn't use HTTPS protocol.At the moment, HTTPS remain in the url even if I declared this protocol only for that resource..This is my (little) web.xml
I have noticed an error, that makes sometimes troubles, when downloading jars from https addresses, when there are many jars to download..
Best example is by opening Javas on Java version checker. [URL] ....
I get also following log...
network: Connecting https://www.java.com/jsp_utils/jreverification.jar with proxy=DIRECT network: Connecting http://www.java.com:443/ with proxy=DIRECT network: Connecting https://www.java.com/jsp_utils/jreverification.jar with cookie "JSESSIONID=22ABBA2BE9B5789629C276AC35BDF969; s_cc=true;
Even if the address is https, java try to access via http protocol on port 443, and that leads sometimes to problems..
I have noticed this, when I have used URLConnection(HttpURLConnection) for my self, as soon Java sends http link on https address, the jar gets sometimes not loaded, and i get error about missing class that get called..
On http addres it is not so bad, since same protocol is used, but evidently, that is evil for https..
As you see, that happens already when loading Jar by Applet Starter and at all, it happens each time on any URLConnection
############################### Java Plug-in 10.13.2.20 Using JRE version 1.7.0_13-b20 Java HotSpot(TM) Client VM User home directory = X:Usersadmin ---------------------------------------------------- c: clear console window f: finalize objects on finalization queue g: garbage collect
I have to write a client and server class for a UDP protocol sending integer numbers by UDP packets. So far i have this;
Client Code:
import java.io.*; import java.net.*; class UDPClient { public static void main(String args[]) throws Exception { BufferedReader inFromUser = new BufferedReader(new InputStreamReader(System.in));
[Code] ....
But i now need to change this so that:
The client;
1. Reads an integer from keyboard input and stores its value in a UDP packet. // byte[] send = ByteBuffer.allocate(4).putInt(num).array(); ???
2. Sends the UDP packet to the server, on port number 1999;
3. Listens for UDP packets from the server (until it receives a packet with a non-positive number; see step (b) below). While listening:
(a) Once it receives a UDP packet from the server, it subtracts 2 from the integer value num contained in it. // int num = ByteBuffer.wrap(receive).getInt(); ??? (b) Checks the integer value num: if the value is greater than 0 (num>0) then the client stores it in a new UDP packet and sends the packet to the server; otherwise (num<=0) the client terminates.
The Server;
1. Listens on port 1999;
2. For each UDP packet it receives from a client: (a) extracts the integer value n contained in it; (b) decreases the value of n by 2; (c) sends back to the client a UDP packet containing the new value of n.
I want to send a SOAP xml to HTTPS url using 2 way mutual ssl. I have my certificates installed in my server. I am creating the SSLSocketFactory like this -
void createSSLSocketFactory() {String clientTrustStore = *** Path to trust store file installed on my server. String clientKeyStore = *** Path to key store file installed on my server. //Reading keystore file File keyFile = new File(clientKeyStore);
[Code] ....
So my question is,
1) How can I set the TrustStore and KeyStore in the request.
I have a simple application ( only 2 JSPs files and one servlet the main components the whole webapp directory is attached ), I am using security constraint to redirect the user to HTTPS instead of HTTP when he submit from first page to the second page.
The problem is when the user submit the first page I get the error HTTP Status 405 - HTTP method GET is not supported by this URL although I m using only POST.
I have traced the firefox browser using httpfox and the result was the first HTTP request was done using POST correctly but after redirect the browser send GET.
This problem appears with FireFOx and IE but doesnot appear with google chrome.
I have a https connection from Client to Server and a malware in client. The malware modifies the message and compromises its integrity. I am using a proxy to check the Integrity of the message after the malware has changed the message and before sending it over the internet to the server.
Now, How can I check the Integrity of the message (Sure that it has not been modified by any Man in the Middle) for the second half of my communication channel(Which is from Client to the Server over the internet).
I see few conventional approaches of CRC or Checksum will work. But I am looking for some non traditional or upcoming approaches.
Ideally SSL Data shouldn't be able to be decrypted by any MIM. But my assumption is that any Protocol is subjected to attack and compromised in real world and few recent studies are proving that https is breakable. Thus, I am trying to perform a What if analysis? On the client side, lets say malware is not more powerful than just modifies the transaction amount and destination account number in a typical online Baking transaction.
i am trying to access an https request on a server and authenticating it after passing on username and passwork. I have even set up the proxy of the employer to get the request back as a zipped folder.
I always get an error on: " InputStream reader = con.getInputStream();"
Can be a proxy setting issue too but I am not sure why it should be.
Is there a way to create a secure channel in java to connect to https or by any way the below code could be modified to connect it to the server?
Code is as below:
import java.net.*; import java.net.Proxy.Type; import java.io.*; import javax.net.ssl.HttpsURLConnection; import com.sun.org.apache.xerces.internal.impl.dv.util.Ba se64; public class DownloadFile {
So that I can map the first request coming say www.xyz.net to my first page , it does the work but some of my css and images is not getting displayed .
I am working on a little project to create an App that can read contents from a website and return it back to my app. What protocol to use for that. Just the reading/retrieving content from a website.
Is it possible to use java to log on to a website? I mean,Ii know how to connect to a website and send commands, but I am not sure how to tell the server that i want to login?
And then after you logged in is it possible to then do something? like, if you logged in to gmail.com you would be able to see your emails?
I have a Java application that was built by a third party and my task is to embed this in a web site. To do so I got an HTML snippet, a .JAR and da .DAT file that seems to be called by the app. I tested this locally on my machine and it works ok. After uploading to the web server I get an error message
NumberFormatException For input string: "i>>?<html>"(the question mark is actually upside down, the >> is really one character)
At first sight this looks like a common issue with UTF-8 file being delivered when the file itself holds only ANSI characters (or vice versa). So I made sure that the .HTM and the .DAT file are indeed stored in ANSI 8-bit (and not Unicode 16-bit) format. However, this does not solve the issue. The .HTM file itself also holds a ISO 8859-1 directive. The server is set to deliver UTF-8 by default. I cannot change this due to a huge lot of other dependencies.
So I am not sure if my suspicion is right - is it indeed a character set issue? Or is it something else?
I have a secured Struts application in WebSphere that uses FORM j_security_check for authentication.There is also a Post Logon "filter" defined which runs some code after a login is processed.The extract from web.xml showing the login configuration and filter is as follows:
If a user isn't logged into the application and they try to access one of the secured servlets, for example quotes.do, they are directed to the login page to enter their information.If they login successfully, they are then directed to quotes.do, rather than the default "welcome" page. Is there a setting in the web.xml or the post logon filter where I can force j_security_check to ALWAYS go to the default welcome page after a successful login?
Today downloaded eclipse and for the database i installed MSSQL 2008 R2. I want to make a webpage where i started with the login credentials, how to make a webpage for the login credentials?
I need two boxes
ID: Password: [Submit Button]
how to make a webpage and how can i run locally should i install IIS?
example: i hava a table conex wich i inser on it two columns name and password i fill it by name : yosra password : lol name : najeh password :mdr
i don't know when i fill jTextfield of password and name correctly for ewp i put yosra as name and password as lol the loop continue to the next row and i show the two message dialog on netbeans about correct acces and refused access and the frame of my chatroom is opened
private void jButton1MouseClicked(java.awt.event.MouseEvent evt) { // TODO add your handling code here: String pass=new String(this.pass.getPassword()); String nam=this.name.getText(); acceder(nam,pass);
i have build an login form with which a user can login to see next form ,login form is working perfectly but whenever a user enters a wrong userid and clicks on login then nothing happens,i want that there a popup will be called and say wrong userid...
However when a user enters correct userid and wrong password then the popup is working but not when the user id itself wrong...
I have created a jsp page named Login.jsp, here's the followings code:
<%@ page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"%> <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"> <link type="text/css" rel="stylesheet" href="inc/style.css" >
[Code] ....
Is that the structure of my page is correct? I create a new folder below WebContent in my project, named "authentication" and i placed below home.jsp. This page will display, if the login and password is correct.