comp.lang.java.programmer
http://groups-beta.google.com/group/comp.lang.java.programmer
[EMAIL PROTECTED]

Today's topics:

* Setzen Fokus über JavaScript im CnC-JSP-Workflow-Framework - 2 messages, 2 
authors
 
http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/5e9346cf97a99a70
* jsp servlet code seperation confusion - 1 messages, 1 author
 
http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/e71d75f30f442d21
* math.pow rounding problem - 5 messages, 5 authors
 
http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/3e00e118892196bb
* cmsg cancel <[EMAIL PROTECTED]> - 1 messages, 1 author
 
http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/6c3011b838c9fe42
* [OT] Using hobby source code in your job ? - 8 messages, 5 authors
 
http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/a60dfe865a7807c4
* OT: Valid filenames on operating systems - 3 messages, 3 authors
 
http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/938eed95c48901c5
* javax.comm - 1 messages, 1 author
 
http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/4b1823ed49da2e4b
* applet security issues - 1 messages, 1 author
 
http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/826c15e115e334c0
* Ann: SimpleW - 1 messages, 1 author
 
http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/6605a639e83f7cb2
* Jetty and http to https redirect - 2 messages, 2 authors
 
http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/d09f917cdfa62188

==============================================================================
TOPIC: Setzen Fokus über JavaScript im CnC-JSP-Workflow-Framework
http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/5e9346cf97a99a70
==============================================================================

== 1 of 2 ==
Date: Sat, Dec 4 2004 11:32 am
From: "Heiner Kücker"  

Anleitung Setzen Fokus über JavaScript im CnC-JSP-Workflow-Framework
--------------------------------------------------------------------

Auf der JSP-Seite muss zum Setzen des Focus auf ein
FORM-Feld folgender JavaScript-Code (hinter der Form </form>)

<script language="JavaScript" type="text/javascript">
  <!--
  document.forms[0].elements[ '<feld-name>' ].focus();
  //-->
</script>

eingefügt werden.

Dies wird durch das CnC-Custom-Tag

  <cnc:setfocus elemName="date"/>

erledigt (siehe SetFocusTag.java).

Es benutzt entweder das optionale Attribut

  elemName="date"

oder den auf dem SessionKey CNC_FOCUS hinterlegten
Form-Element-Namen, wobei der SessionKey Vorrang hat.
Nach dem Erzeugen des JavaScript-Codes löscht das
SetFocusTag.java den Session-Wert auf dem Key
CNC_FOCUS (message consumed).

Im Fluss-Steuer-Script flow.cnc kann der Name des zu
fokussierenden Form-Elementes mit

  session.CNC_FOCUS := "date";

gesetzt werden.

Bei indizierten Formularen (Tabellen) ist der Index des zu
fokussierenden Form-Elementes in eckigen Klammern mit zu
übergeben:

  session.CNC_FOCUS := "txt[" + cnc_button_index + "]";

Es dürfen keine Leerzewichen, führende Nullen oder Dezimalstellen
auftauchen.

Hier besteht eine Abhängigkeit zur internen Arbeitsweise des CnC-
Frameworks. Der Einfachheit wegen habe ich diese Lösung fürs
erste gewählt.


Heiner Kuecker
Internet: http://www.heinerkuecker.de  http://www.heiner-kuecker.de
JSP WorkFlow PageFlow Page Flow FlowControl Navigation: 
http://www.control-and-command.de
Expression Language Parser: http://www.heinerkuecker.de/Expression.html





== 2 of 2 ==
Date: Sat, Dec 4 2004 11:49 am
From: Joona I Palaste  

"Heiner Kücker" <[EMAIL PROTECTED]> scribbled the following:
> Anleitung Setzen Fokus über JavaScript im CnC-JSP-Workflow-Framework

Falsches Newsgroup. Sie wollen in comp.lang.javascript zu schreiben.

-- 
/-- Joona Palaste ([EMAIL PROTECTED]) ------------- Finland --------\
\-------------------------------------------------------- rules! --------/
"Make money fast! Don't feed it!"
   - Anon




==============================================================================
TOPIC: jsp servlet code seperation confusion
http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/e71d75f30f442d21
==============================================================================

== 1 of 1 ==
Date: Sat, Dec 4 2004 11:41 am
From: "Heiner Kücker"  

> The idea is to
> separate display-related code from the program logic and use JSPs for
> (and *onyl* for) rendering HTML pages, while servlets and regular Java
> classes handle the program logic.

Ack

-- 
Heiner Kuecker
Internet: http://www.heinerkuecker.de  http://www.heiner-kuecker.de
JSP WorkFlow PageFlow Page Flow FlowControl Navigation: 
http://www.control-and-command.de
Expression Language Parser: http://www.heinerkuecker.de/Expression.html






==============================================================================
TOPIC: math.pow rounding problem
http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/3e00e118892196bb
==============================================================================

== 1 of 5 ==
Date: Sat, Dec 4 2004 11:42 am
From: "VisionSet"  



"Jimmy zhang" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Hi, I tried Math.pow(10,-21) and expected to see 1e-21.
> But instead I saw 1.00000000001e-21. what should I
> do to get rid of the trailing 0.0000000000001??
>

Floating point arithemtic loses accuracy when dealing with decimal values,
because a floating point number can only approximate the decimal equivalent.

If you know your result will be in the int range ie -2^31 to 2^31
then do this:

int result = (int) Math.round(Math.pow(10, exp))

or for results in the range -2^63 to 2^63

long result = Math.round(Math.pow(10, exp))

if you wanted to keep it as a double then:

double result = Math.rint(Math.pow(10, exp))

-- 
Mike W





== 2 of 5 ==
Date: Sat, Dec 4 2004 12:17 pm
From: "Jimmy zhang"  

what if the result is actually a float or double?
I am trying implement my own parseDouble and parseFloat function ??
"VisionSet" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
>
>
> "Jimmy zhang" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]
> > Hi, I tried Math.pow(10,-21) and expected to see 1e-21.
> > But instead I saw 1.00000000001e-21. what should I
> > do to get rid of the trailing 0.0000000000001??
> >
>
> Floating point arithemtic loses accuracy when dealing with decimal values,
> because a floating point number can only approximate the decimal
equivalent.
>
> If you know your result will be in the int range ie -2^31 to 2^31
> then do this:
>
> int result = (int) Math.round(Math.pow(10, exp))
>
> or for results in the range -2^63 to 2^63
>
> long result = Math.round(Math.pow(10, exp))
>
> if you wanted to keep it as a double then:
>
> double result = Math.rint(Math.pow(10, exp))
>
> -- 
> Mike W
>
>





== 3 of 5 ==
Date: Sat, Dec 4 2004 12:38 pm
From: Mark Thornton  

Jimmy hang wrote:
> what if the result is actually a float or double?
> I am trying implement my own parseDouble and parseFloat function ??

I suggest that you leave that task to the experts, which you clearly are 
not. Correctly implementing parseDouble is rather more complex than it 
might appear at first sight. If you want to learn, then some courses in 
numerical analysis and the behaviour of binary floating point arithmetic 
would be a good start.

Mark Thornton



== 4 of 5 ==
Date: Sat, Dec 4 2004 1:23 pm
From: "Boudewijn Dijkstra"  

"Jimmy zhang" <[EMAIL PROTECTED]> schreef in bericht 
news:[EMAIL PROTECTED]
> what if the result is actually a float or double?
> I am trying implement my own parseDouble and parseFloat
> function ??

Powers of ten above a certain value will no longer fit into a float or double, 
simply because representing the value in a binary 
sign-exponent-significand-representation will take too many bits of the 
significand. 





== 5 of 5 ==
Date: Sat, Dec 4 2004 4:20 pm
From: "Albert Greinöcker"  

I think these kind of problems could be solved with class
java.math.BigDecimal...

"Jimmy zhang" <[EMAIL PROTECTED]> schrieb im Newsbeitrag 
news:[EMAIL PROTECTED]
> Hi, I tried Math.pow(10,-21) and expected to see 1e-21.
> But instead I saw 1.00000000001e-21. what should I
> do to get rid of the trailing 0.0000000000001??
>
> Thanks,
> Jimmy
>
> 






==============================================================================
TOPIC: cmsg cancel <[EMAIL PROTECTED]>
http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/6c3011b838c9fe42
==============================================================================

== 1 of 1 ==
Date: Sat, Dec 4 2004 11:49 am
From: Joona I Palaste  

Article cancelled by author




==============================================================================
TOPIC: [OT] Using hobby source code in your job ?
http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/a60dfe865a7807c4
==============================================================================

== 1 of 8 ==
Date: Sat, Dec 4 2004 12:06 pm
From: RCollins  



Stephen Sprunk wrote:
> "E. Robert Tisdale" <[EMAIL PROTECTED]> wrote in message 
> news:[EMAIL PROTECTED]
> 
>> Keith Thompson wrote:
>>
>>> My understanding is that any written work
>>> is automatically copyrighted as soon as it's set down in tangible form.
>>
>>
>> It probably is but how does a judge and jury determine
>> that the copyright belongs to you and not someone else?
> 
> 
> Article 3 of the Berne Convention states that, at least for citizens of 
> member countries, all works by an author are protected whether published 
> or not.
> 
> Article 15 states that, "in the absence of proof to the contrary, ... it 
> shall be sufficient for [the author's] name to appear on the work in the 
> usual manner."
> 
>>> I'm not sure what, if any, additional legal protection is added
>>> by using a copyright header.
>>
>>
>> It's evidence that you claimed the copyright at some point in time.
> 
> 
> It's prima facie evidence; once someone provides evidence that you are 
> not the author, what name is on the work is irrelevant.
> 
>>>> Your employer cannot compel you to transfer the copyright
>>>> for code that you wrote on your own time
>>>> or code that you wrote for another employer.
>>>
>>>
>>> I'm not convinced that that's accurate.  It's at least partly a matter
>>> of whatever contractual arrangement you have with your employer.
>>
>>
>> No legal contractual agreement
>> can compel you to help your new employer steal code
>> that you wrote for a former employer.
> 
> 
> Obviously a contract cannot compel you to violate the copyright of a 
> former employer.
> 
> However, if the code is yours (not a work for hire), you can certainly 
> by compelled by contract to hand all of your copyrights over to 
> someone. 

I'm sorry, I don't understand this.  How can a company (whether I work
for them or not) lay claim to a product that I developed on my own time,
using my own equipment and resources?  (Excluding, of course, the normal
"conflict of interest" clauses, which says I may not compete for
business with my employer.)

> In fact, that seems to be a standard part of most employment 
> contracts these days.  

I have dealt with quite a few software contract workers, both
self-employed and those employed by an agency, but I've never seen
anything like this.  OTOH, my professional arena is rather specialized,
with not a lot of players.  In what engineering discipline would the
contract clause you mentioned above be considered "standard"?  (I may
want to avoid that area in the future!)

> Specifically, you must typically name all works 
> that you are _not_ handing over.  That makes it difficult to exclude 
> future works, but there is at least one creative solution to that.
> 
> S
> 

-- 
Ron Collins
Raytheon Air Defense/RTSC/BCS




== 2 of 8 ==
Date: Sat, Dec 4 2004 12:30 pm
From: "Andrew Koenig"  

"RCollins" <[EMAIL PROTECTED]> wrote in message 
news:[EMAIL PROTECTED]

> I'm sorry, I don't understand this.  How can a company (whether I work
> for them or not) lay claim to a product that I developed on my own time,
> using my own equipment and resources?  (Excluding, of course, the normal
> "conflict of interest" clauses, which says I may not compete for
> business with my employer.)

Unless you're being paid by the hour, there is no such thing as "your own 
time".






== 3 of 8 ==
Date: Sat, Dec 4 2004 12:42 pm
From: Joona I Palaste  

Andrew Koenig <[EMAIL PROTECTED]> scribbled the following
on comp.lang.c:
> "RCollins" <[EMAIL PROTECTED]> wrote in message 
> news:[EMAIL PROTECTED]
>> I'm sorry, I don't understand this.  How can a company (whether I work
>> for them or not) lay claim to a product that I developed on my own time,
>> using my own equipment and resources?  (Excluding, of course, the normal
>> "conflict of interest" clauses, which says I may not compete for
>> business with my employer.)

> Unless you're being paid by the hour, there is no such thing as "your own 
> time".

Not even on weekends?

-- 
/-- Joona Palaste ([EMAIL PROTECTED]) ------------- Finland --------\
\-------------------------------------------------------- rules! --------/
"Bad things only happen to scoundrels."
   - Moominmamma



== 4 of 8 ==
Date: Sat, Dec 4 2004 2:02 pm
From: "Andrew Koenig"  

"Joona I Palaste" <[EMAIL PROTECTED]> wrote in message 
news:[EMAIL PROTECTED]

>> Unless you're being paid by the hour, there is no such thing as "your own
>> time".
>
> Not even on weekends?

In general, no.  It's a matter of what you and your employer agree on.





== 5 of 8 ==
Date: Sat, Dec 4 2004 2:39 pm
From: Keith Thompson  

"MikeB" <m.byerleyATVerizonDottieNettie> writes:
>> My understanding is that any written work is automatically copyrighted
>> as soon as it's set down in tangible form.  I'm not sure what, if any,
>> additional legal protection is added by using a copyright header.
>
>   I think it's awfully presumptuous that any snippet that you write
> is so unique that it could be NOT considered part of the public
> domain and could have a copyright applied...

I believe the term "public domain" has a specific legal meaning.
I won't discuss it further here.

> All this talk about hobby code, unless it applies to an application,
> independent in its' own right, and applicable to a specific task, or
> at very least a group of tasks, is much ado about nothing..

I suppose it might depend on what you mean by "hobby code".  Some
hobby code can be quite large, and copyright law can definitely apply
to it.

> And definitely not On Topic here...

Agreed.

I've redirected followups to /dev/null.  If you insist on posting a
followup, you can post to these same newsgroups, but please don't.

-- 
Keith Thompson (The_Other_Keith) [EMAIL PROTECTED]  <http://www.ghoti.net/~kst>
San Diego Supercomputer Center             <*>  <http://users.sdsc.edu/~kst>
We must do something.  This is something.  Therefore, we must do this.



== 6 of 8 ==
Date: Sat, Dec 4 2004 3:42 pm
From: "E. Robert Tisdale"  

MikeB wrote:

> And definitely not On Topic here...

It is topical only to the extent that
every source file should include a copyright notice
including the date and the name of the copyright owner.
If you are unsure about who the copyright belongs,
you (the author) should claim it for yourself.
You can always transfer copyright ownership
to the rightful owner later.



== 7 of 8 ==
Date: Sat, Dec 4 2004 3:34 pm
From: "E. Robert Tisdale"  

Andrew Koenig wrote:

> Unless you're being paid by the hour, 
> there is no such thing as "your own time".

Spoken like a true company man.
Who owns you?



== 8 of 8 ==
Date: Sat, Dec 4 2004 4:22 pm
From: "Andrew Koenig"  

"E. Robert Tisdale" <[EMAIL PROTECTED]> wrote in message 
news:[EMAIL PROTECTED]

> Andrew Koenig wrote:
>
>> Unless you're being paid by the hour, there is no such thing as "your own 
>> time".
>
> Spoken like a true company man.
> Who owns you?

No one.  Not any more.  That's part of the reason.






==============================================================================
TOPIC: OT: Valid filenames on operating systems
http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/938eed95c48901c5
==============================================================================

== 1 of 3 ==
Date: Sat, Dec 4 2004 12:33 pm
From: Dimitri Maziuk  

Ann sez:
> 
> "Bruce Lee" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]
>>
>> "Joona I Palaste" <[EMAIL PROTECTED]> wrote in message
>> news:[EMAIL PROTECTED]
>> > Bruce Lee <[EMAIL PROTECTED]> scribbled the following:
>> > > Windows doesn't allow filename's containing the following characters:
>> > > \/:*?"<>|
>> >
>> > > Is this the same on all operating systems?
>> >
>> > > I'm asking because I'm writing a html parser which needs to find valid
>> urls.
>> >
>> > No. AmigaOS only disallows : and /. Unix only disallows /, although with
>> > clever trickery - in practice accessing the file system's name table
>> > directly - it's possible to use even / in filenames. You won't be able
>> > to access that file from the command line, though.
>> >
> 
> Let us know how you handle the space character.
> (How do you tell the end of the filename.)

The easiest way is to never ever use spaces in the filenames
& to use underscore instead.

HTH
Dima
-- 
... If you want to make sure you don't put a Pig in a List of airplanes and
have it fail at insertion rather than extraction, use
planelist.add((Airplane)o) instead of planelist.add(o).  It's that easy.
                                                     -- Mark 'Kamikaze' Hughes



== 2 of 3 ==
Date: Sat, Dec 4 2004 1:18 pm
From: "Ann"  


"Thomas G. Marshall" <[EMAIL PROTECTED]>
wrote in message news:[EMAIL PROTECTED]
> Ann coughed up:
> > "Bruce Lee" <[EMAIL PROTECTED]> wrote in message
> > news:[EMAIL PROTECTED]
> >>
> >> "Joona I Palaste" <[EMAIL PROTECTED]> wrote in message
> >> news:[EMAIL PROTECTED]
> >>> Bruce Lee <[EMAIL PROTECTED]> scribbled the following:
> >>>> Windows doesn't allow filename's containing the following
> >>>> characters: \/:*?"<>|
> >>>
> >>>> Is this the same on all operating systems?
> >>>
> >>>> I'm asking because I'm writing a html parser which needs to find
> >>>> valid urls.
> >>>
> >>> No. AmigaOS only disallows : and /. Unix only disallows /, although
> >>> with clever trickery - in practice accessing the file system's name
> >>> table directly - it's possible to use even / in filenames. You
> >>> won't be able to access that file from the command line, though.
> >>>
> >
> > Let us know how you handle the space character.
> > (How do you tell the end of the filename.)
>
> If it's a string, presumably then it's the end of the string.
>
> I'm not sure what you're asking/implying.....Unix can clearly use the
space
> character.  From a shell, you just have to be crafty.  But within an app?
> You can do "anything"....

Oh, ok. I thought the OP was "writing a html parser which needs to find
valid urls."
So you are saying that the url being questioned is available as a string.
Existing methods should do the trick then.





== 3 of 3 ==
Date: Sat, Dec 4 2004 4:25 pm
From: "Thomas G. Marshall"  

Joona I Palaste coughed up:
> Thomas G. Marshall
> <[EMAIL PROTECTED]> scribbled the
> following:
>> Ann coughed up:
>>> "Bruce Lee" <[EMAIL PROTECTED]> wrote in message
>>> news:[EMAIL PROTECTED]
>>>> "Joona I Palaste" <[EMAIL PROTECTED]> wrote in message
>>>> news:[EMAIL PROTECTED]
>>>>> Bruce Lee <[EMAIL PROTECTED]> scribbled the following:
>>>>>> Windows doesn't allow filename's containing the following
>>>>>> characters: \/:*?"<>|
>>>>>
>>>>>> Is this the same on all operating systems?
>>>>>
>>>>>> I'm asking because I'm writing a html parser which needs to find
>>>>>> valid urls.
>>>>>
>>>>> No. AmigaOS only disallows : and /. Unix only disallows /,
>>>>> although with clever trickery - in practice accessing the file
>>>>> system's name table directly - it's possible to use even / in
>>>>> filenames. You won't be able to access that file from the command
>>>>> line, though.
>>>
>>> Let us know how you handle the space character.
>>> (How do you tell the end of the filename.)
>
> Putting the filename in double quotes "" works for both AmigaOS and
> Unix. If the filename itself contains double quotes, you have to
> escape them. The escape character is * for AmigaOS and \ for Unix.
> Escaping the escape character itself is done by doubling it.


You replied to me, when you meant Ann I think.

-- 
Whyowhydidn'tsunmakejavarequireanuppercaselettertostartclassnames....






==============================================================================
TOPIC: javax.comm
http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/4b1823ed49da2e4b
==============================================================================

== 1 of 1 ==
Date: Sat, Dec 4 2004 1:03 pm
From: "Ann"  


"lin shen" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Has anyone out there tried to use javax.comm to communicate with a rfid
> reader?
>
> lin
GOOGLE -> this is the first item found, there are plenty of others.
===
Sun Java System RFID
The Java System RFID Software is Sun's unique RFID middleware platform
offering that is based on widely accepted industry standards including those
defined by EPCglobal. It provides the foundation for deploying your
company's Electronic Product Code (EPC) Network that will enable improved
asset visibility,safety and integrity across your supply chain. Sun's RFID
software is designed specifically to provide high levels of reliability and
scalability for your EPC Networkwhile also simplifying the task of
integrating with multiple existing back-end enterprise systems.

The Java System RFID Software consists of two software components: The Java
System RFID Event Manager and the Java System RFID Information Server. Both
are available for download.






==============================================================================
TOPIC: applet security issues
http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/826c15e115e334c0
==============================================================================

== 1 of 1 ==
Date: Sat, Dec 4 2004 12:49 pm
From: Andrew Thompson  

On Sat, 4 Dec 2004 19:58:25 +0100, Matthijs Blaasthijs_blaas wrote:

> ..I have a couple more questions concerning (signed) applets:
> 
> 1.) If I sign my applet will this always popup a warning to the user asking 
> if they trust it (even if I use a real certificate)?

If the user chooses to accept 'all further content' from the 
certificate signer, no.  Otherwise, yes.  If they refuse it,
your applet will still appear*, but it will constrained by 
the default applet security sandbox. * Unless you were silly
enough to invoke security exceptions during the GUI construction.

> 2.) Is there any way of making an unsigned applet instanciate a class file 
> from another jar? 

Add the Jar of the other class to the archive param and it's classes
can be found using getResource(name)

> ..I thought I needed to have a classloader to do 
> this. 

No.

>...This works ok, but if I want to download the game jar & library jar 
> from the loader, is there a way I can start the game in an unsigned applet?

Yes.  So long as you load the classes via URL, and never try
to access or use any File object, that will be fine.

> 3.) Is it possible to cache files I download in my applet?

The browser will do it automatically in an haphazzard fashion according 
to the its current settings.  But once you have a Jar'd applet you can
install it via JWS and the components (class Jar's or toher resources) 
will only be updated if they have changed.

> I'd greatly appreciate if anyone could help me with any of these questions!

No worries.

-- 
Andrew Thompson
http://www.PhySci.org/codes/  Web & IT Help
http://www.PhySci.org/  Open-source software suite
http://www.1point1C.org/  Science & Technology
http://www.LensEscapes.com/  Images that escape the mundane




==============================================================================
TOPIC: Ann: SimpleW
http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/6605a639e83f7cb2
==============================================================================

== 1 of 1 ==
Date: Sat, Dec 4 2004 2:02 pm
From: [EMAIL PROTECTED] (Frank Gerlach) 

SimpleW is a  simple web server with server pages technology. The
latter is a simplified version of SUN's Java Server pages. The goal of
this project is to provide an extremely simple and robust system. This
means that there are no complex deployment schemes or class loaders.
Only the methods GET and POST are  implemented. SSL is supported via
JSSE.

more here: http://84.244.1.52:8080/simplew.html




==============================================================================
TOPIC: Jetty and http to https redirect
http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/d09f917cdfa62188
==============================================================================

== 1 of 2 ==
Date: Sat, Dec 4 2004 2:30 pm
From: [EMAIL PROTECTED] (Forrest Samuels) 

I am working on an embedded web application using Jetty 4.2.10pre1.
The webapp has traditionally been run using just http on port 8082.
For the next release, we will be handling more sensitive passwords and
plan on using SSL/https instead. We are using the SunJsseListener for
our SSL support.

The problem we have is often users will still go to
http://127.0.0.1:8082 when they should go to https://127.0.0.1:8082.
Using http in IE causes an error and in Firefox it attempts to
download a file.

Is there a way to setup Jetty to recognize users are attempting to use
HTTP and redirect them to HTTPS?

It would be easier if we could use the standard port 443 but since
users may also be running a web server with SSL, we can't by default.
I am open to switching to a newer version of Jetty if need be.

Thanks for the help.



== 2 of 2 ==
Date: Sat, Dec 4 2004 4:17 pm
From: Steve Sobol  

Forrest Samuels wrote:

> Is there a way to setup Jetty to recognize users are attempting to use
> HTTP and redirect them to HTTPS?

You should be able to set up a standard security constraint that forces SSL, 
although I don't know if it'll automatically redirect them.

Barring that, you could set up a servlet that redirects everyone going to http 
on port 8082 to https on port 443.

Neither of these solutions are Jetty-specific, but they should both work fine.

-- 
JustThe.net Internet & New Media Services, http://JustThe.net/
Steven J. Sobol, Geek In Charge / 888.480.4NET (4638) / [EMAIL PROTECTED]
PGP Key available from your friendly local key server (0xE3AE35ED)
Apple Valley, California     Nothing scares me anymore. I have three kids.



==============================================================================

You received this message because you are subscribed to the Google
Groups "comp.lang.java.programmer" group.

To post to this group, send email to [EMAIL PROTECTED] or
visit http://groups-beta.google.com/group/comp.lang.java.programmer

To unsubscribe from this group, send email to
[EMAIL PROTECTED]

To change the way you get mail from this group, visit:
http://groups-beta.google.com/group/comp.lang.java.programmer/subscribe

To report abuse, send email explaining the problem to [EMAIL PROTECTED]

==============================================================================
Google Groups: http://groups-beta.google.com 

Reply via email to