Take advantage of the largest STIC '12 conference discounts by registering this week

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
111 messages Options
123456
Reply | Threaded
Open this post in threaded view
|

Re: Configuring Seaside for deployment

Larry Kellogg

On Jan 13, 2012, at 5:23 PM, Lawrence Kellogg wrote:

>
> On Jan 13, 2012, at 4:49 PM, Dale Henrichs wrote:
>
>> Lawrence,
>>
>> That should have been:
>>
>> ConfigurationOfGsMisc project currentVersion load: 'System-Digital-Signatures'.
>>
>
>  Well, this seems to work and returns this:
>
> Loading 0.239.1 of ConfigurationOfGsMisc...
> ...finished 0.239.1
>
> but the SecureHashAlgorithm class does not exist in the image, I don't get System-Digital-Signatures but I do have System-Digital-Signatures-Tests. Puzzling.
> Also, I can no longer reach my running server with a http, it insists on trying to use https, where it fails.
>

  Well, I spoke a little too soon, as I had to go to Monticello and load the package. Now, I have the SecureHashAlgorithm. I still can't reach my server though, as it tries to connect with https.
My production server is running blissfully along with http, and works fine.


>
>
>> I recommend that you perform a backup[1] before doing a load of software, because then it is very easy to restore[2] to a known point ... I typically keep a number of backups around for this purpose.
>>
>
>  At the moment, I have spun up two AMI instances, one called production and one called staging. I am doing my hacking on the staging instance.
> Nothing is live, yet, but I should get used to not destroying the production system. ;-) Your point is well taken, I will start making backups.
>
>> If SystemHashing is the only problem area (and you don't have a backup:), then you can unload the SystemHashing package using the Monticello browser[3], then load the GemStone version using the expression above ...
>>
>> Let me know if you have other issues,
>>
>> Dale
>>
>>
>> [1] http://code.google.com/p/glassdb/wiki/GemToolsAdmin#Backup
>> [2] http://code.google.com/p/glassdb/wiki/GemToolsAdmin#Restore_w/o_tranlogs
>> [3] http://code.google.com/p/glassdb/wiki/GemToolsTools#Monticello
>> ----- Original Message -----
>> | From: "Lawrence Kellogg" <[hidden email]>
>> | To: "GemStone Seaside beta discussion" <[hidden email]>
>> | Sent: Friday, January 13, 2012 1:03:34 PM
>> | Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
>> |
>> |
>> | On Jan 13, 2012, at 1:38 PM, Dale Henrichs wrote:
>> |
>> | > Lawrence,
>> | >
>> | > First off, there is an implementation of SecureHashAlgorithm
>> | > already ported to GemStone. To load the correct version you can
>> | > try this expression:
>> | >
>> | >  ConfigurationOfGsMisc currentVersion load:
>> | >  'System-Digital-Signatures'.
>> | >
>> |
>> |   Thanks Dale, unfortunately, my ConfigurationOfGsMisc class does not
>> |   have a current method, so it fails.
>> | I am on GemStone64Bit2.4.4.1-x86_64.Linux.
>> |
>> |   Did you mean:
>> |
>> |   ConfigurationOfGsMisc project load: 'System-Digital-Signatures' ??
>> |
>> |   but that doesn't work because it expects a version string.
>> |
>> |   I know that I totally messed up my configuration when I loaded the
>> |   System-Hashing stuff from Squeak.
>> |
>> |   How do I restore my Gemstone configuration?
>> |
>> |   Larry
>> |
>> |
>> |
>> | > Using the version that is already ported to GemStone will
>> | > definitely address the issue you had with the #processBuffer
>> | > method (MNU for #primHasSecureHashPrimitive).
>> | >
>> | >> From looking at the code, I would have to guess that you must be
>> | >> passing in a FileStream in the #hashStream: method.
>> | >> FileStream>>next: returns a nil explicitly and that looks like a
>> | >> bug to me ... The fix would be for FileStream to return result,
>> | >> which should be empty on an error...
>> | >
>> | > If you're not using a FileStream there, then I would be interested
>> | > in a stack to understand what is wrong ...
>> | >
>> | > Dale
>> | > ----- Original Message -----
>> | > | From: "Lawrence Kellogg" <[hidden email]>
>> | > | To: "GemStone Seaside beta discussion"
>> | > | <[hidden email]>
>> | > | Sent: Thursday, January 12, 2012 8:41:44 PM
>> | > | Subject: [GS/SS Beta] Configuring Seaside for deployment
>> | > |
>> | > | Hello,
>> | > | So, I have started going through the chapter on what it takes to
>> | > | deploy an application with Seaside.
>> | > |
>> | > |
>> | > | I can bring up the Configuration option by clicking Configure at
>> | > | the
>> | > | bottom of the browser but if I try to
>> | > | password prptect the configure app, I get a crash in the
>> | > | SecureHashAlgorithm class, with the message
>> | > |
>> | > |
>> | > | "Byte objects store values from 0 to 255, not nil"
>> | > |
>> | > |
>> | > | (Same issue if I try to execute: "WAConfigurationTool initialize"
>> | > | initialize
>> | > | (WAAdmin register: self asApplicationAt: 'config' user: 'admin'
>> | > | password: 'seaside') addLibrary: WAToolFiles)
>> | > |
>> | > |
>> | > | The trouble is:
>> | > |
>> | > |
>> | > | buf := aPositionableStream next: 64 which returns nil when it
>> | > | tries
>> | > | to go through the next 64 elements,
>> | > | there aren't 64 elements...
>> | > |
>> | > |
>> | > | from here:
>> | > |
>> | > |
>> | > |
>> | > | hashStream: aPositionableStream
>> | > | "Hash the contents of the given stream from the current position
>> | > | to
>> | > | the end using the Secure Hash Algorithm. The SHA algorithm is
>> | > | defined in FIPS PUB 180-1. It is also described on p. 442 of
>> | > | 'Applied Cryptography: Protocols, Algorithms, and Source Code in
>> | > | C'
>> | > | by Bruce Scheier, Wiley, 1996."
>> | > | "SecureHashAlgorithm new hashStream: (ReadStream on: 'foo')"
>> | > | "(SecureHashAlgorithm new hashMessage: '') radix: 16
>> | > | => 'DA39A3EE5E6B4B0D3255BFEF95601890AFD80709'"
>> | > |
>> | > | | startPosition buf bitLength |
>> | > | self initializeTotals.
>> | > |
>> | > | aPositionableStream atEnd ifTrue: [self processFinalBuffer: #()
>> | > | bitLength: 0].
>> | > |
>> | > |
>> | > | startPosition := aPositionableStream position.
>> | > | [aPositionableStream atEnd] whileFalse:
>> | > | [ buf := aPositionableStream next: 64.
>> | > | <<<<<<<<<<<<<<<<<<<<<<-----
>> | > | (aPositionableStream atEnd not and: [buf size = 64])
>> | > | ifTrue: [self processBuffer: buf]
>> | > | ifFalse: [ bitLength := (aPositionableStream position -
>> | > | startPosition) * 8.
>> | > | self processFinalBuffer: buf bitLength: bitLength]].
>> | > | ^ self finalHash
>> | > |
>> | > |
>> | > | and also in SecureHashAlgorithm, which does not understand
>> | > |
>> | > |
>> | > | self primHasSecureHashPrimitive
>> | > |
>> | > |
>> | > | from
>> | > |
>> | > |
>> | > |
>> | > | processBuffer: aByteArray
>> | > | "Process given 64-byte buffer, accumulating the results in totalA
>> | > | through totalE."
>> | > |
>> | > |
>> | > | | a b c d e w tmp |
>> | > | self <<<<<<<<<<<<<<<<<<<<<<<<<<<<
>> | > | ifTrue: [^ self processBufferUsingPrimitives: aByteArray]
>> | > | ifFalse: [totals := nil].
>> | > |
>> | > |
>> | > | "initialize registers a through e from the current totals"
>> | > | a := totalA copy.
>> | > | b := totalB copy.
>> | > | c := totalC copy.
>> | > | d := totalD copy.
>> | > | e := totalE copy.
>> | > |
>> | > |
>> | > | "expand and process the buffer"
>> | > | w := self expandedBlock: aByteArray.
>> | > | 1 to: 80 do: [:i |
>> | > | tmp := (a copy leftRotateBy: 5)
>> | > | += (self hashFunction: i of: b with: c with: d);
>> | > | += e;
>> | > | += (w at: i);
>> | > | += (self constantForStep: i).
>> | > | e := d.
>> | > | d := c.
>> | > | c := b copy leftRotateBy: 30.
>> | > | b := a.
>> | > | a := tmp].
>> | > |
>> | > |
>> | > | "add a through e into total accumulators"
>> | > | totalA += a.
>> | > | totalB += b.
>> | > | totalC += c.
>> | > | totalD += d.
>> | > | totalE += e.
>> | > |
>> | > |
>> | > |
>> | > |
>> | > | I'm wondering if I somehow messed up my SecureHashAlgorithm class
>> | > | with the other troubles I had
>> | > | with Cloudfork or am I just destined to run into all kinds of
>> | > | security problems. ;-)
>> | > |
>> | > |
>> | > | Any thoughts?
>> | > |
>> | > |
>> | > |
>> | > |
>> | > | Larry
>> | > |
>> | > |
>> |
>> |
>

Reply | Threaded
Open this post in threaded view
|

Re: Configuring Seaside for deployment

Dale Henrichs
In reply to this post by Larry Kellogg
Interesting ... Did you unload the old pacakge first? Do you happen to know if your current system (the one serving HTTP requests) was trying to use the class SecureHashAlgorithm? When you say "the SecureHashAlgorithm class does not exist in the image" do you mean you don't see it in the SystemBrowser or that you get an error message somewhere that is trying to use the class? What are you using to server http pages?

Dale

----- Original Message -----
| From: "Lawrence Kellogg" <[hidden email]>
| To: "GemStone Seaside beta discussion" <[hidden email]>
| Sent: Friday, January 13, 2012 2:23:39 PM
| Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
|
|
| On Jan 13, 2012, at 4:49 PM, Dale Henrichs wrote:
|
| > Lawrence,
| >
| > That should have been:
| >
| >  ConfigurationOfGsMisc project currentVersion load:
| >  'System-Digital-Signatures'.
| >
|
|   Well, this seems to work and returns this:
|
| Loading 0.239.1 of ConfigurationOfGsMisc...
| ...finished 0.239.1
|
| but the SecureHashAlgorithm class does not exist in the image, I
| don't get System-Digital-Signatures but I do have
| System-Digital-Signatures-Tests. Puzzling.
| Also, I can no longer reach my running server with a http, it insists
| on trying to use https, where it fails.
|
|
|
| > I recommend that you perform a backup[1] before doing a load of
| > software, because then it is very easy to restore[2] to a known
| > point ... I typically keep a number of backups around for this
| > purpose.
| >
|
|   At the moment, I have spun up two AMI instances, one called
|   production and one called staging. I am doing my hacking on the
|   staging instance.
| Nothing is live, yet, but I should get used to not destroying the
| production system. ;-) Your point is well taken, I will start making
| backups.
|
| > If SystemHashing is the only problem area (and you don't have a
| > backup:), then you can unload the SystemHashing package using the
| > Monticello browser[3], then load the GemStone version using the
| > expression above ...
| >
| > Let me know if you have other issues,
| >
| > Dale
| >
| >
| > [1] http://code.google.com/p/glassdb/wiki/GemToolsAdmin#Backup
| > [2]
| > http://code.google.com/p/glassdb/wiki/GemToolsAdmin#Restore_w/o_tranlogs
| > [3] http://code.google.com/p/glassdb/wiki/GemToolsTools#Monticello
| > ----- Original Message -----
| > | From: "Lawrence Kellogg" <[hidden email]>
| > | To: "GemStone Seaside beta discussion"
| > | <[hidden email]>
| > | Sent: Friday, January 13, 2012 1:03:34 PM
| > | Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
| > |
| > |
| > | On Jan 13, 2012, at 1:38 PM, Dale Henrichs wrote:
| > |
| > | > Lawrence,
| > | >
| > | > First off, there is an implementation of SecureHashAlgorithm
| > | > already ported to GemStone. To load the correct version you can
| > | > try this expression:
| > | >
| > | >  ConfigurationOfGsMisc currentVersion load:
| > | >  'System-Digital-Signatures'.
| > | >
| > |
| > |   Thanks Dale, unfortunately, my ConfigurationOfGsMisc class does
| > |   not
| > |   have a current method, so it fails.
| > | I am on GemStone64Bit2.4.4.1-x86_64.Linux.
| > |
| > |   Did you mean:
| > |
| > |   ConfigurationOfGsMisc project load: 'System-Digital-Signatures'
| > |   ??
| > |
| > |   but that doesn't work because it expects a version string.
| > |
| > |   I know that I totally messed up my configuration when I loaded
| > |   the
| > |   System-Hashing stuff from Squeak.
| > |
| > |   How do I restore my Gemstone configuration?
| > |
| > |   Larry
| > |
| > |
| > |
| > | > Using the version that is already ported to GemStone will
| > | > definitely address the issue you had with the #processBuffer
| > | > method (MNU for #primHasSecureHashPrimitive).
| > | >
| > | >> From looking at the code, I would have to guess that you must
| > | >> be
| > | >> passing in a FileStream in the #hashStream: method.
| > | >> FileStream>>next: returns a nil explicitly and that looks like
| > | >> a
| > | >> bug to me ... The fix would be for FileStream to return
| > | >> result,
| > | >> which should be empty on an error...
| > | >
| > | > If you're not using a FileStream there, then I would be
| > | > interested
| > | > in a stack to understand what is wrong ...
| > | >
| > | > Dale
| > | > ----- Original Message -----
| > | > | From: "Lawrence Kellogg" <[hidden email]>
| > | > | To: "GemStone Seaside beta discussion"
| > | > | <[hidden email]>
| > | > | Sent: Thursday, January 12, 2012 8:41:44 PM
| > | > | Subject: [GS/SS Beta] Configuring Seaside for deployment
| > | > |
| > | > | Hello,
| > | > | So, I have started going through the chapter on what it takes
| > | > | to
| > | > | deploy an application with Seaside.
| > | > |
| > | > |
| > | > | I can bring up the Configuration option by clicking Configure
| > | > | at
| > | > | the
| > | > | bottom of the browser but if I try to
| > | > | password prptect the configure app, I get a crash in the
| > | > | SecureHashAlgorithm class, with the message
| > | > |
| > | > |
| > | > | "Byte objects store values from 0 to 255, not nil"
| > | > |
| > | > |
| > | > | (Same issue if I try to execute: "WAConfigurationTool
| > | > | initialize"
| > | > | initialize
| > | > | (WAAdmin register: self asApplicationAt: 'config' user:
| > | > | 'admin'
| > | > | password: 'seaside') addLibrary: WAToolFiles)
| > | > |
| > | > |
| > | > | The trouble is:
| > | > |
| > | > |
| > | > | buf := aPositionableStream next: 64 which returns nil when it
| > | > | tries
| > | > | to go through the next 64 elements,
| > | > | there aren't 64 elements...
| > | > |
| > | > |
| > | > | from here:
| > | > |
| > | > |
| > | > |
| > | > | hashStream: aPositionableStream
| > | > | "Hash the contents of the given stream from the current
| > | > | position
| > | > | to
| > | > | the end using the Secure Hash Algorithm. The SHA algorithm is
| > | > | defined in FIPS PUB 180-1. It is also described on p. 442 of
| > | > | 'Applied Cryptography: Protocols, Algorithms, and Source Code
| > | > | in
| > | > | C'
| > | > | by Bruce Scheier, Wiley, 1996."
| > | > | "SecureHashAlgorithm new hashStream: (ReadStream on: 'foo')"
| > | > | "(SecureHashAlgorithm new hashMessage: '') radix: 16
| > | > | => 'DA39A3EE5E6B4B0D3255BFEF95601890AFD80709'"
| > | > |
| > | > | | startPosition buf bitLength |
| > | > | self initializeTotals.
| > | > |
| > | > | aPositionableStream atEnd ifTrue: [self processFinalBuffer:
| > | > | #()
| > | > | bitLength: 0].
| > | > |
| > | > |
| > | > | startPosition := aPositionableStream position.
| > | > | [aPositionableStream atEnd] whileFalse:
| > | > | [ buf := aPositionableStream next: 64.
| > | > | <<<<<<<<<<<<<<<<<<<<<<-----
| > | > | (aPositionableStream atEnd not and: [buf size = 64])
| > | > | ifTrue: [self processBuffer: buf]
| > | > | ifFalse: [ bitLength := (aPositionableStream position -
| > | > | startPosition) * 8.
| > | > | self processFinalBuffer: buf bitLength: bitLength]].
| > | > | ^ self finalHash
| > | > |
| > | > |
| > | > | and also in SecureHashAlgorithm, which does not understand
| > | > |
| > | > |
| > | > | self primHasSecureHashPrimitive
| > | > |
| > | > |
| > | > | from
| > | > |
| > | > |
| > | > |
| > | > | processBuffer: aByteArray
| > | > | "Process given 64-byte buffer, accumulating the results in
| > | > | totalA
| > | > | through totalE."
| > | > |
| > | > |
| > | > | | a b c d e w tmp |
| > | > | self <<<<<<<<<<<<<<<<<<<<<<<<<<<<
| > | > | ifTrue: [^ self processBufferUsingPrimitives: aByteArray]
| > | > | ifFalse: [totals := nil].
| > | > |
| > | > |
| > | > | "initialize registers a through e from the current totals"
| > | > | a := totalA copy.
| > | > | b := totalB copy.
| > | > | c := totalC copy.
| > | > | d := totalD copy.
| > | > | e := totalE copy.
| > | > |
| > | > |
| > | > | "expand and process the buffer"
| > | > | w := self expandedBlock: aByteArray.
| > | > | 1 to: 80 do: [:i |
| > | > | tmp := (a copy leftRotateBy: 5)
| > | > | += (self hashFunction: i of: b with: c with: d);
| > | > | += e;
| > | > | += (w at: i);
| > | > | += (self constantForStep: i).
| > | > | e := d.
| > | > | d := c.
| > | > | c := b copy leftRotateBy: 30.
| > | > | b := a.
| > | > | a := tmp].
| > | > |
| > | > |
| > | > | "add a through e into total accumulators"
| > | > | totalA += a.
| > | > | totalB += b.
| > | > | totalC += c.
| > | > | totalD += d.
| > | > | totalE += e.
| > | > |
| > | > |
| > | > |
| > | > |
| > | > | I'm wondering if I somehow messed up my SecureHashAlgorithm
| > | > | class
| > | > | with the other troubles I had
| > | > | with Cloudfork or am I just destined to run into all kinds of
| > | > | security problems. ;-)
| > | > |
| > | > |
| > | > | Any thoughts?
| > | > |
| > | > |
| > | > |
| > | > |
| > | > | Larry
| > | > |
| > | > |
| > |
| > |
|
|
Reply | Threaded
Open this post in threaded view
|

Re: Configuring Seaside for deployment

Dale Henrichs
In reply to this post by Larry Kellogg
Oh good ...

Since your production system and sandbox systems are running in separate stone they shouldn't be affecting each other ... BTW, you can take a back up of your production system and restore it into your sandbox system to get your sandbox functioning again (make a backup of the sandbox before doing this so that you can come back and look at this system later in case there's something important there) and then try to do the load of the CloudFork again... this time with the GemStone version of SecureHashAlgorithm...

Regarding the https thing ... a couple of questions: What are you using to serve http in GemStone? Is it possible that the CloudFork code itself is interfering with http somehow?

Dale

----- Original Message -----
| From: "Lawrence Kellogg" <[hidden email]>
| To: "GemStone Seaside beta discussion" <[hidden email]>
| Sent: Friday, January 13, 2012 2:32:50 PM
| Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
|
|
| On Jan 13, 2012, at 5:23 PM, Lawrence Kellogg wrote:
|
| >
| > On Jan 13, 2012, at 4:49 PM, Dale Henrichs wrote:
| >
| >> Lawrence,
| >>
| >> That should have been:
| >>
| >> ConfigurationOfGsMisc project currentVersion load:
| >> 'System-Digital-Signatures'.
| >>
| >
| >  Well, this seems to work and returns this:
| >
| > Loading 0.239.1 of ConfigurationOfGsMisc...
| > ...finished 0.239.1
| >
| > but the SecureHashAlgorithm class does not exist in the image, I
| > don't get System-Digital-Signatures but I do have
| > System-Digital-Signatures-Tests. Puzzling.
| > Also, I can no longer reach my running server with a http, it
| > insists on trying to use https, where it fails.
| >
|
|   Well, I spoke a little too soon, as I had to go to Monticello and
|   load the package. Now, I have the SecureHashAlgorithm. I still
|   can't reach my server though, as it tries to connect with https.
| My production server is running blissfully along with http, and works
| fine.
|
|
| >
| >
| >> I recommend that you perform a backup[1] before doing a load of
| >> software, because then it is very easy to restore[2] to a known
| >> point ... I typically keep a number of backups around for this
| >> purpose.
| >>
| >
| >  At the moment, I have spun up two AMI instances, one called
| >  production and one called staging. I am doing my hacking on the
| >  staging instance.
| > Nothing is live, yet, but I should get used to not destroying the
| > production system. ;-) Your point is well taken, I will start
| > making backups.
| >
| >> If SystemHashing is the only problem area (and you don't have a
| >> backup:), then you can unload the SystemHashing package using the
| >> Monticello browser[3], then load the GemStone version using the
| >> expression above ...
| >>
| >> Let me know if you have other issues,
| >>
| >> Dale
| >>
| >>
| >> [1] http://code.google.com/p/glassdb/wiki/GemToolsAdmin#Backup
| >> [2]
| >> http://code.google.com/p/glassdb/wiki/GemToolsAdmin#Restore_w/o_tranlogs
| >> [3] http://code.google.com/p/glassdb/wiki/GemToolsTools#Monticello
| >> ----- Original Message -----
| >> | From: "Lawrence Kellogg" <[hidden email]>
| >> | To: "GemStone Seaside beta discussion"
| >> | <[hidden email]>
| >> | Sent: Friday, January 13, 2012 1:03:34 PM
| >> | Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
| >> |
| >> |
| >> | On Jan 13, 2012, at 1:38 PM, Dale Henrichs wrote:
| >> |
| >> | > Lawrence,
| >> | >
| >> | > First off, there is an implementation of SecureHashAlgorithm
| >> | > already ported to GemStone. To load the correct version you
| >> | > can
| >> | > try this expression:
| >> | >
| >> | >  ConfigurationOfGsMisc currentVersion load:
| >> | >  'System-Digital-Signatures'.
| >> | >
| >> |
| >> |   Thanks Dale, unfortunately, my ConfigurationOfGsMisc class
| >> |   does not
| >> |   have a current method, so it fails.
| >> | I am on GemStone64Bit2.4.4.1-x86_64.Linux.
| >> |
| >> |   Did you mean:
| >> |
| >> |   ConfigurationOfGsMisc project load:
| >> |   'System-Digital-Signatures' ??
| >> |
| >> |   but that doesn't work because it expects a version string.
| >> |
| >> |   I know that I totally messed up my configuration when I loaded
| >> |   the
| >> |   System-Hashing stuff from Squeak.
| >> |
| >> |   How do I restore my Gemstone configuration?
| >> |
| >> |   Larry
| >> |
| >> |
| >> |
| >> | > Using the version that is already ported to GemStone will
| >> | > definitely address the issue you had with the #processBuffer
| >> | > method (MNU for #primHasSecureHashPrimitive).
| >> | >
| >> | >> From looking at the code, I would have to guess that you must
| >> | >> be
| >> | >> passing in a FileStream in the #hashStream: method.
| >> | >> FileStream>>next: returns a nil explicitly and that looks
| >> | >> like a
| >> | >> bug to me ... The fix would be for FileStream to return
| >> | >> result,
| >> | >> which should be empty on an error...
| >> | >
| >> | > If you're not using a FileStream there, then I would be
| >> | > interested
| >> | > in a stack to understand what is wrong ...
| >> | >
| >> | > Dale
| >> | > ----- Original Message -----
| >> | > | From: "Lawrence Kellogg" <[hidden email]>
| >> | > | To: "GemStone Seaside beta discussion"
| >> | > | <[hidden email]>
| >> | > | Sent: Thursday, January 12, 2012 8:41:44 PM
| >> | > | Subject: [GS/SS Beta] Configuring Seaside for deployment
| >> | > |
| >> | > | Hello,
| >> | > | So, I have started going through the chapter on what it
| >> | > | takes to
| >> | > | deploy an application with Seaside.
| >> | > |
| >> | > |
| >> | > | I can bring up the Configuration option by clicking
| >> | > | Configure at
| >> | > | the
| >> | > | bottom of the browser but if I try to
| >> | > | password prptect the configure app, I get a crash in the
| >> | > | SecureHashAlgorithm class, with the message
| >> | > |
| >> | > |
| >> | > | "Byte objects store values from 0 to 255, not nil"
| >> | > |
| >> | > |
| >> | > | (Same issue if I try to execute: "WAConfigurationTool
| >> | > | initialize"
| >> | > | initialize
| >> | > | (WAAdmin register: self asApplicationAt: 'config' user:
| >> | > | 'admin'
| >> | > | password: 'seaside') addLibrary: WAToolFiles)
| >> | > |
| >> | > |
| >> | > | The trouble is:
| >> | > |
| >> | > |
| >> | > | buf := aPositionableStream next: 64 which returns nil when
| >> | > | it
| >> | > | tries
| >> | > | to go through the next 64 elements,
| >> | > | there aren't 64 elements...
| >> | > |
| >> | > |
| >> | > | from here:
| >> | > |
| >> | > |
| >> | > |
| >> | > | hashStream: aPositionableStream
| >> | > | "Hash the contents of the given stream from the current
| >> | > | position
| >> | > | to
| >> | > | the end using the Secure Hash Algorithm. The SHA algorithm
| >> | > | is
| >> | > | defined in FIPS PUB 180-1. It is also described on p. 442 of
| >> | > | 'Applied Cryptography: Protocols, Algorithms, and Source
| >> | > | Code in
| >> | > | C'
| >> | > | by Bruce Scheier, Wiley, 1996."
| >> | > | "SecureHashAlgorithm new hashStream: (ReadStream on: 'foo')"
| >> | > | "(SecureHashAlgorithm new hashMessage: '') radix: 16
| >> | > | => 'DA39A3EE5E6B4B0D3255BFEF95601890AFD80709'"
| >> | > |
| >> | > | | startPosition buf bitLength |
| >> | > | self initializeTotals.
| >> | > |
| >> | > | aPositionableStream atEnd ifTrue: [self processFinalBuffer:
| >> | > | #()
| >> | > | bitLength: 0].
| >> | > |
| >> | > |
| >> | > | startPosition := aPositionableStream position.
| >> | > | [aPositionableStream atEnd] whileFalse:
| >> | > | [ buf := aPositionableStream next: 64.
| >> | > | <<<<<<<<<<<<<<<<<<<<<<-----
| >> | > | (aPositionableStream atEnd not and: [buf size = 64])
| >> | > | ifTrue: [self processBuffer: buf]
| >> | > | ifFalse: [ bitLength := (aPositionableStream position -
| >> | > | startPosition) * 8.
| >> | > | self processFinalBuffer: buf bitLength: bitLength]].
| >> | > | ^ self finalHash
| >> | > |
| >> | > |
| >> | > | and also in SecureHashAlgorithm, which does not understand
| >> | > |
| >> | > |
| >> | > | self primHasSecureHashPrimitive
| >> | > |
| >> | > |
| >> | > | from
| >> | > |
| >> | > |
| >> | > |
| >> | > | processBuffer: aByteArray
| >> | > | "Process given 64-byte buffer, accumulating the results in
| >> | > | totalA
| >> | > | through totalE."
| >> | > |
| >> | > |
| >> | > | | a b c d e w tmp |
| >> | > | self <<<<<<<<<<<<<<<<<<<<<<<<<<<<
| >> | > | ifTrue: [^ self processBufferUsingPrimitives: aByteArray]
| >> | > | ifFalse: [totals := nil].
| >> | > |
| >> | > |
| >> | > | "initialize registers a through e from the current totals"
| >> | > | a := totalA copy.
| >> | > | b := totalB copy.
| >> | > | c := totalC copy.
| >> | > | d := totalD copy.
| >> | > | e := totalE copy.
| >> | > |
| >> | > |
| >> | > | "expand and process the buffer"
| >> | > | w := self expandedBlock: aByteArray.
| >> | > | 1 to: 80 do: [:i |
| >> | > | tmp := (a copy leftRotateBy: 5)
| >> | > | += (self hashFunction: i of: b with: c with: d);
| >> | > | += e;
| >> | > | += (w at: i);
| >> | > | += (self constantForStep: i).
| >> | > | e := d.
| >> | > | d := c.
| >> | > | c := b copy leftRotateBy: 30.
| >> | > | b := a.
| >> | > | a := tmp].
| >> | > |
| >> | > |
| >> | > | "add a through e into total accumulators"
| >> | > | totalA += a.
| >> | > | totalB += b.
| >> | > | totalC += c.
| >> | > | totalD += d.
| >> | > | totalE += e.
| >> | > |
| >> | > |
| >> | > |
| >> | > |
| >> | > | I'm wondering if I somehow messed up my SecureHashAlgorithm
| >> | > | class
| >> | > | with the other troubles I had
| >> | > | with Cloudfork or am I just destined to run into all kinds
| >> | > | of
| >> | > | security problems. ;-)
| >> | > |
| >> | > |
| >> | > | Any thoughts?
| >> | > |
| >> | > |
| >> | > |
| >> | > |
| >> | > | Larry
| >> | > |
| >> | > |
| >> |
| >> |
| >
|
|
Reply | Threaded
Open this post in threaded view
|

Re: Configuring Seaside for deployment

Larry Kellogg
In reply to this post by Dale Henrichs

On Jan 13, 2012, at 5:49 PM, Dale Henrichs wrote:

> Interesting ... Did you unload the old pacakge first? Do you happen to know if your current system (the one serving HTTP requests) was trying to use the class SecureHashAlgorithm? When you say "the SecureHashAlgorithm class does not exist in the image" do you mean you don't see it in the SystemBrowser or that you get an error message somewhere that is trying to use the class? What are you using to server http pages?
>

  Yes, I unloaded the old package first. I don't believe my old system was using the SecureHashAlgorithm because that class fails when I try to
set a password on the Seaside config, which was what I was doing when I started figuring out a deployment configuration..

  I sent another note to the list. I have the SecureHashAlgorithm now, after loading it from Monticello, manually. I thought your command would load it
automatically. Sorry about that.

  I am running Seaside to serve my http pages. I'm not sure why this new instance insists on https for everything.

  Larry


> Dale
>
> ----- Original Message -----
> | From: "Lawrence Kellogg" <[hidden email]>
> | To: "GemStone Seaside beta discussion" <[hidden email]>
> | Sent: Friday, January 13, 2012 2:23:39 PM
> | Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
> |
> |
> | On Jan 13, 2012, at 4:49 PM, Dale Henrichs wrote:
> |
> | > Lawrence,
> | >
> | > That should have been:
> | >
> | >  ConfigurationOfGsMisc project currentVersion load:
> | >  'System-Digital-Signatures'.
> | >
> |
> |   Well, this seems to work and returns this:
> |
> | Loading 0.239.1 of ConfigurationOfGsMisc...
> | ...finished 0.239.1
> |
> | but the SecureHashAlgorithm class does not exist in the image, I
> | don't get System-Digital-Signatures but I do have
> | System-Digital-Signatures-Tests. Puzzling.
> | Also, I can no longer reach my running server with a http, it insists
> | on trying to use https, where it fails.
> |
> |
> |
> | > I recommend that you perform a backup[1] before doing a load of
> | > software, because then it is very easy to restore[2] to a known
> | > point ... I typically keep a number of backups around for this
> | > purpose.
> | >
> |
> |   At the moment, I have spun up two AMI instances, one called
> |   production and one called staging. I am doing my hacking on the
> |   staging instance.
> | Nothing is live, yet, but I should get used to not destroying the
> | production system. ;-) Your point is well taken, I will start making
> | backups.
> |
> | > If SystemHashing is the only problem area (and you don't have a
> | > backup:), then you can unload the SystemHashing package using the
> | > Monticello browser[3], then load the GemStone version using the
> | > expression above ...
> | >
> | > Let me know if you have other issues,
> | >
> | > Dale
> | >
> | >
> | > [1] http://code.google.com/p/glassdb/wiki/GemToolsAdmin#Backup
> | > [2]
> | > http://code.google.com/p/glassdb/wiki/GemToolsAdmin#Restore_w/o_tranlogs
> | > [3] http://code.google.com/p/glassdb/wiki/GemToolsTools#Monticello
> | > ----- Original Message -----
> | > | From: "Lawrence Kellogg" <[hidden email]>
> | > | To: "GemStone Seaside beta discussion"
> | > | <[hidden email]>
> | > | Sent: Friday, January 13, 2012 1:03:34 PM
> | > | Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
> | > |
> | > |
> | > | On Jan 13, 2012, at 1:38 PM, Dale Henrichs wrote:
> | > |
> | > | > Lawrence,
> | > | >
> | > | > First off, there is an implementation of SecureHashAlgorithm
> | > | > already ported to GemStone. To load the correct version you can
> | > | > try this expression:
> | > | >
> | > | >  ConfigurationOfGsMisc currentVersion load:
> | > | >  'System-Digital-Signatures'.
> | > | >
> | > |
> | > |   Thanks Dale, unfortunately, my ConfigurationOfGsMisc class does
> | > |   not
> | > |   have a current method, so it fails.
> | > | I am on GemStone64Bit2.4.4.1-x86_64.Linux.
> | > |
> | > |   Did you mean:
> | > |
> | > |   ConfigurationOfGsMisc project load: 'System-Digital-Signatures'
> | > |   ??
> | > |
> | > |   but that doesn't work because it expects a version string.
> | > |
> | > |   I know that I totally messed up my configuration when I loaded
> | > |   the
> | > |   System-Hashing stuff from Squeak.
> | > |
> | > |   How do I restore my Gemstone configuration?
> | > |
> | > |   Larry
> | > |
> | > |
> | > |
> | > | > Using the version that is already ported to GemStone will
> | > | > definitely address the issue you had with the #processBuffer
> | > | > method (MNU for #primHasSecureHashPrimitive).
> | > | >
> | > | >> From looking at the code, I would have to guess that you must
> | > | >> be
> | > | >> passing in a FileStream in the #hashStream: method.
> | > | >> FileStream>>next: returns a nil explicitly and that looks like
> | > | >> a
> | > | >> bug to me ... The fix would be for FileStream to return
> | > | >> result,
> | > | >> which should be empty on an error...
> | > | >
> | > | > If you're not using a FileStream there, then I would be
> | > | > interested
> | > | > in a stack to understand what is wrong ...
> | > | >
> | > | > Dale
> | > | > ----- Original Message -----
> | > | > | From: "Lawrence Kellogg" <[hidden email]>
> | > | > | To: "GemStone Seaside beta discussion"
> | > | > | <[hidden email]>
> | > | > | Sent: Thursday, January 12, 2012 8:41:44 PM
> | > | > | Subject: [GS/SS Beta] Configuring Seaside for deployment
> | > | > |
> | > | > | Hello,
> | > | > | So, I have started going through the chapter on what it takes
> | > | > | to
> | > | > | deploy an application with Seaside.
> | > | > |
> | > | > |
> | > | > | I can bring up the Configuration option by clicking Configure
> | > | > | at
> | > | > | the
> | > | > | bottom of the browser but if I try to
> | > | > | password prptect the configure app, I get a crash in the
> | > | > | SecureHashAlgorithm class, with the message
> | > | > |
> | > | > |
> | > | > | "Byte objects store values from 0 to 255, not nil"
> | > | > |
> | > | > |
> | > | > | (Same issue if I try to execute: "WAConfigurationTool
> | > | > | initialize"
> | > | > | initialize
> | > | > | (WAAdmin register: self asApplicationAt: 'config' user:
> | > | > | 'admin'
> | > | > | password: 'seaside') addLibrary: WAToolFiles)
> | > | > |
> | > | > |
> | > | > | The trouble is:
> | > | > |
> | > | > |
> | > | > | buf := aPositionableStream next: 64 which returns nil when it
> | > | > | tries
> | > | > | to go through the next 64 elements,
> | > | > | there aren't 64 elements...
> | > | > |
> | > | > |
> | > | > | from here:
> | > | > |
> | > | > |
> | > | > |
> | > | > | hashStream: aPositionableStream
> | > | > | "Hash the contents of the given stream from the current
> | > | > | position
> | > | > | to
> | > | > | the end using the Secure Hash Algorithm. The SHA algorithm is
> | > | > | defined in FIPS PUB 180-1. It is also described on p. 442 of
> | > | > | 'Applied Cryptography: Protocols, Algorithms, and Source Code
> | > | > | in
> | > | > | C'
> | > | > | by Bruce Scheier, Wiley, 1996."
> | > | > | "SecureHashAlgorithm new hashStream: (ReadStream on: 'foo')"
> | > | > | "(SecureHashAlgorithm new hashMessage: '') radix: 16
> | > | > | => 'DA39A3EE5E6B4B0D3255BFEF95601890AFD80709'"
> | > | > |
> | > | > | | startPosition buf bitLength |
> | > | > | self initializeTotals.
> | > | > |
> | > | > | aPositionableStream atEnd ifTrue: [self processFinalBuffer:
> | > | > | #()
> | > | > | bitLength: 0].
> | > | > |
> | > | > |
> | > | > | startPosition := aPositionableStream position.
> | > | > | [aPositionableStream atEnd] whileFalse:
> | > | > | [ buf := aPositionableStream next: 64.
> | > | > | <<<<<<<<<<<<<<<<<<<<<<-----
> | > | > | (aPositionableStream atEnd not and: [buf size = 64])
> | > | > | ifTrue: [self processBuffer: buf]
> | > | > | ifFalse: [ bitLength := (aPositionableStream position -
> | > | > | startPosition) * 8.
> | > | > | self processFinalBuffer: buf bitLength: bitLength]].
> | > | > | ^ self finalHash
> | > | > |
> | > | > |
> | > | > | and also in SecureHashAlgorithm, which does not understand
> | > | > |
> | > | > |
> | > | > | self primHasSecureHashPrimitive
> | > | > |
> | > | > |
> | > | > | from
> | > | > |
> | > | > |
> | > | > |
> | > | > | processBuffer: aByteArray
> | > | > | "Process given 64-byte buffer, accumulating the results in
> | > | > | totalA
> | > | > | through totalE."
> | > | > |
> | > | > |
> | > | > | | a b c d e w tmp |
> | > | > | self <<<<<<<<<<<<<<<<<<<<<<<<<<<<
> | > | > | ifTrue: [^ self processBufferUsingPrimitives: aByteArray]
> | > | > | ifFalse: [totals := nil].
> | > | > |
> | > | > |
> | > | > | "initialize registers a through e from the current totals"
> | > | > | a := totalA copy.
> | > | > | b := totalB copy.
> | > | > | c := totalC copy.
> | > | > | d := totalD copy.
> | > | > | e := totalE copy.
> | > | > |
> | > | > |
> | > | > | "expand and process the buffer"
> | > | > | w := self expandedBlock: aByteArray.
> | > | > | 1 to: 80 do: [:i |
> | > | > | tmp := (a copy leftRotateBy: 5)
> | > | > | += (self hashFunction: i of: b with: c with: d);
> | > | > | += e;
> | > | > | += (w at: i);
> | > | > | += (self constantForStep: i).
> | > | > | e := d.
> | > | > | d := c.
> | > | > | c := b copy leftRotateBy: 30.
> | > | > | b := a.
> | > | > | a := tmp].
> | > | > |
> | > | > |
> | > | > | "add a through e into total accumulators"
> | > | > | totalA += a.
> | > | > | totalB += b.
> | > | > | totalC += c.
> | > | > | totalD += d.
> | > | > | totalE += e.
> | > | > |
> | > | > |
> | > | > |
> | > | > |
> | > | > | I'm wondering if I somehow messed up my SecureHashAlgorithm
> | > | > | class
> | > | > | with the other troubles I had
> | > | > | with Cloudfork or am I just destined to run into all kinds of
> | > | > | security problems. ;-)
> | > | > |
> | > | > |
> | > | > | Any thoughts?
> | > | > |
> | > | > |
> | > | > |
> | > | > |
> | > | > | Larry
> | > | > |
> | > | > |
> | > |
> | > |
> |
> |

Reply | Threaded
Open this post in threaded view
|

Re: Configuring Seaside for deployment

Dale Henrichs
Lawrence,

I think there must be a configuration setting that has been changed ... not sure which one though?

Dale

----- Original Message -----
| From: "Lawrence Kellogg" <[hidden email]>
| To: "GemStone Seaside beta discussion" <[hidden email]>
| Sent: Friday, January 13, 2012 2:55:13 PM
| Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
|
|
| On Jan 13, 2012, at 5:49 PM, Dale Henrichs wrote:
|
| > Interesting ... Did you unload the old pacakge first? Do you happen
| > to know if your current system (the one serving HTTP requests) was
| > trying to use the class SecureHashAlgorithm? When you say "the
| > SecureHashAlgorithm class does not exist in the image" do you mean
| > you don't see it in the SystemBrowser or that you get an error
| > message somewhere that is trying to use the class? What are you
| > using to server http pages?
| >
|
|   Yes, I unloaded the old package first. I don't believe my old
|   system was using the SecureHashAlgorithm because that class fails
|   when I try to
| set a password on the Seaside config, which was what I was doing when
| I started figuring out a deployment configuration..
|
|   I sent another note to the list. I have the SecureHashAlgorithm
|   now, after loading it from Monticello, manually. I thought your
|   command would load it
| automatically. Sorry about that.
|
|   I am running Seaside to serve my http pages. I'm not sure why this
|   new instance insists on https for everything.
|
|   Larry
|
|
| > Dale
| >
| > ----- Original Message -----
| > | From: "Lawrence Kellogg" <[hidden email]>
| > | To: "GemStone Seaside beta discussion"
| > | <[hidden email]>
| > | Sent: Friday, January 13, 2012 2:23:39 PM
| > | Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
| > |
| > |
| > | On Jan 13, 2012, at 4:49 PM, Dale Henrichs wrote:
| > |
| > | > Lawrence,
| > | >
| > | > That should have been:
| > | >
| > | >  ConfigurationOfGsMisc project currentVersion load:
| > | >  'System-Digital-Signatures'.
| > | >
| > |
| > |   Well, this seems to work and returns this:
| > |
| > | Loading 0.239.1 of ConfigurationOfGsMisc...
| > | ...finished 0.239.1
| > |
| > | but the SecureHashAlgorithm class does not exist in the image, I
| > | don't get System-Digital-Signatures but I do have
| > | System-Digital-Signatures-Tests. Puzzling.
| > | Also, I can no longer reach my running server with a http, it
| > | insists
| > | on trying to use https, where it fails.
| > |
| > |
| > |
| > | > I recommend that you perform a backup[1] before doing a load of
| > | > software, because then it is very easy to restore[2] to a known
| > | > point ... I typically keep a number of backups around for this
| > | > purpose.
| > | >
| > |
| > |   At the moment, I have spun up two AMI instances, one called
| > |   production and one called staging. I am doing my hacking on the
| > |   staging instance.
| > | Nothing is live, yet, but I should get used to not destroying the
| > | production system. ;-) Your point is well taken, I will start
| > | making
| > | backups.
| > |
| > | > If SystemHashing is the only problem area (and you don't have a
| > | > backup:), then you can unload the SystemHashing package using
| > | > the
| > | > Monticello browser[3], then load the GemStone version using the
| > | > expression above ...
| > | >
| > | > Let me know if you have other issues,
| > | >
| > | > Dale
| > | >
| > | >
| > | > [1] http://code.google.com/p/glassdb/wiki/GemToolsAdmin#Backup
| > | > [2]
| > | > http://code.google.com/p/glassdb/wiki/GemToolsAdmin#Restore_w/o_tranlogs
| > | > [3]
| > | > http://code.google.com/p/glassdb/wiki/GemToolsTools#Monticello
| > | > ----- Original Message -----
| > | > | From: "Lawrence Kellogg" <[hidden email]>
| > | > | To: "GemStone Seaside beta discussion"
| > | > | <[hidden email]>
| > | > | Sent: Friday, January 13, 2012 1:03:34 PM
| > | > | Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
| > | > |
| > | > |
| > | > | On Jan 13, 2012, at 1:38 PM, Dale Henrichs wrote:
| > | > |
| > | > | > Lawrence,
| > | > | >
| > | > | > First off, there is an implementation of
| > | > | > SecureHashAlgorithm
| > | > | > already ported to GemStone. To load the correct version you
| > | > | > can
| > | > | > try this expression:
| > | > | >
| > | > | >  ConfigurationOfGsMisc currentVersion load:
| > | > | >  'System-Digital-Signatures'.
| > | > | >
| > | > |
| > | > |   Thanks Dale, unfortunately, my ConfigurationOfGsMisc class
| > | > |   does
| > | > |   not
| > | > |   have a current method, so it fails.
| > | > | I am on GemStone64Bit2.4.4.1-x86_64.Linux.
| > | > |
| > | > |   Did you mean:
| > | > |
| > | > |   ConfigurationOfGsMisc project load:
| > | > |   'System-Digital-Signatures'
| > | > |   ??
| > | > |
| > | > |   but that doesn't work because it expects a version string.
| > | > |
| > | > |   I know that I totally messed up my configuration when I
| > | > |   loaded
| > | > |   the
| > | > |   System-Hashing stuff from Squeak.
| > | > |
| > | > |   How do I restore my Gemstone configuration?
| > | > |
| > | > |   Larry
| > | > |
| > | > |
| > | > |
| > | > | > Using the version that is already ported to GemStone will
| > | > | > definitely address the issue you had with the
| > | > | > #processBuffer
| > | > | > method (MNU for #primHasSecureHashPrimitive).
| > | > | >
| > | > | >> From looking at the code, I would have to guess that you
| > | > | >> must
| > | > | >> be
| > | > | >> passing in a FileStream in the #hashStream: method.
| > | > | >> FileStream>>next: returns a nil explicitly and that looks
| > | > | >> like
| > | > | >> a
| > | > | >> bug to me ... The fix would be for FileStream to return
| > | > | >> result,
| > | > | >> which should be empty on an error...
| > | > | >
| > | > | > If you're not using a FileStream there, then I would be
| > | > | > interested
| > | > | > in a stack to understand what is wrong ...
| > | > | >
| > | > | > Dale
| > | > | > ----- Original Message -----
| > | > | > | From: "Lawrence Kellogg" <[hidden email]>
| > | > | > | To: "GemStone Seaside beta discussion"
| > | > | > | <[hidden email]>
| > | > | > | Sent: Thursday, January 12, 2012 8:41:44 PM
| > | > | > | Subject: [GS/SS Beta] Configuring Seaside for deployment
| > | > | > |
| > | > | > | Hello,
| > | > | > | So, I have started going through the chapter on what it
| > | > | > | takes
| > | > | > | to
| > | > | > | deploy an application with Seaside.
| > | > | > |
| > | > | > |
| > | > | > | I can bring up the Configuration option by clicking
| > | > | > | Configure
| > | > | > | at
| > | > | > | the
| > | > | > | bottom of the browser but if I try to
| > | > | > | password prptect the configure app, I get a crash in the
| > | > | > | SecureHashAlgorithm class, with the message
| > | > | > |
| > | > | > |
| > | > | > | "Byte objects store values from 0 to 255, not nil"
| > | > | > |
| > | > | > |
| > | > | > | (Same issue if I try to execute: "WAConfigurationTool
| > | > | > | initialize"
| > | > | > | initialize
| > | > | > | (WAAdmin register: self asApplicationAt: 'config' user:
| > | > | > | 'admin'
| > | > | > | password: 'seaside') addLibrary: WAToolFiles)
| > | > | > |
| > | > | > |
| > | > | > | The trouble is:
| > | > | > |
| > | > | > |
| > | > | > | buf := aPositionableStream next: 64 which returns nil
| > | > | > | when it
| > | > | > | tries
| > | > | > | to go through the next 64 elements,
| > | > | > | there aren't 64 elements...
| > | > | > |
| > | > | > |
| > | > | > | from here:
| > | > | > |
| > | > | > |
| > | > | > |
| > | > | > | hashStream: aPositionableStream
| > | > | > | "Hash the contents of the given stream from the current
| > | > | > | position
| > | > | > | to
| > | > | > | the end using the Secure Hash Algorithm. The SHA
| > | > | > | algorithm is
| > | > | > | defined in FIPS PUB 180-1. It is also described on p. 442
| > | > | > | of
| > | > | > | 'Applied Cryptography: Protocols, Algorithms, and Source
| > | > | > | Code
| > | > | > | in
| > | > | > | C'
| > | > | > | by Bruce Scheier, Wiley, 1996."
| > | > | > | "SecureHashAlgorithm new hashStream: (ReadStream on:
| > | > | > | 'foo')"
| > | > | > | "(SecureHashAlgorithm new hashMessage: '') radix: 16
| > | > | > | => 'DA39A3EE5E6B4B0D3255BFEF95601890AFD80709'"
| > | > | > |
| > | > | > | | startPosition buf bitLength |
| > | > | > | self initializeTotals.
| > | > | > |
| > | > | > | aPositionableStream atEnd ifTrue: [self
| > | > | > | processFinalBuffer:
| > | > | > | #()
| > | > | > | bitLength: 0].
| > | > | > |
| > | > | > |
| > | > | > | startPosition := aPositionableStream position.
| > | > | > | [aPositionableStream atEnd] whileFalse:
| > | > | > | [ buf := aPositionableStream next: 64.
| > | > | > | <<<<<<<<<<<<<<<<<<<<<<-----
| > | > | > | (aPositionableStream atEnd not and: [buf size = 64])
| > | > | > | ifTrue: [self processBuffer: buf]
| > | > | > | ifFalse: [ bitLength := (aPositionableStream position -
| > | > | > | startPosition) * 8.
| > | > | > | self processFinalBuffer: buf bitLength: bitLength]].
| > | > | > | ^ self finalHash
| > | > | > |
| > | > | > |
| > | > | > | and also in SecureHashAlgorithm, which does not
| > | > | > | understand
| > | > | > |
| > | > | > |
| > | > | > | self primHasSecureHashPrimitive
| > | > | > |
| > | > | > |
| > | > | > | from
| > | > | > |
| > | > | > |
| > | > | > |
| > | > | > | processBuffer: aByteArray
| > | > | > | "Process given 64-byte buffer, accumulating the results
| > | > | > | in
| > | > | > | totalA
| > | > | > | through totalE."
| > | > | > |
| > | > | > |
| > | > | > | | a b c d e w tmp |
| > | > | > | self <<<<<<<<<<<<<<<<<<<<<<<<<<<<
| > | > | > | ifTrue: [^ self processBufferUsingPrimitives: aByteArray]
| > | > | > | ifFalse: [totals := nil].
| > | > | > |
| > | > | > |
| > | > | > | "initialize registers a through e from the current
| > | > | > | totals"
| > | > | > | a := totalA copy.
| > | > | > | b := totalB copy.
| > | > | > | c := totalC copy.
| > | > | > | d := totalD copy.
| > | > | > | e := totalE copy.
| > | > | > |
| > | > | > |
| > | > | > | "expand and process the buffer"
| > | > | > | w := self expandedBlock: aByteArray.
| > | > | > | 1 to: 80 do: [:i |
| > | > | > | tmp := (a copy leftRotateBy: 5)
| > | > | > | += (self hashFunction: i of: b with: c with: d);
| > | > | > | += e;
| > | > | > | += (w at: i);
| > | > | > | += (self constantForStep: i).
| > | > | > | e := d.
| > | > | > | d := c.
| > | > | > | c := b copy leftRotateBy: 30.
| > | > | > | b := a.
| > | > | > | a := tmp].
| > | > | > |
| > | > | > |
| > | > | > | "add a through e into total accumulators"
| > | > | > | totalA += a.
| > | > | > | totalB += b.
| > | > | > | totalC += c.
| > | > | > | totalD += d.
| > | > | > | totalE += e.
| > | > | > |
| > | > | > |
| > | > | > |
| > | > | > |
| > | > | > | I'm wondering if I somehow messed up my
| > | > | > | SecureHashAlgorithm
| > | > | > | class
| > | > | > | with the other troubles I had
| > | > | > | with Cloudfork or am I just destined to run into all
| > | > | > | kinds of
| > | > | > | security problems. ;-)
| > | > | > |
| > | > | > |
| > | > | > | Any thoughts?
| > | > | > |
| > | > | > |
| > | > | > |
| > | > | > |
| > | > | > | Larry
| > | > | > |
| > | > | > |
| > | > |
| > | > |
| > |
| > |
|
|
Reply | Threaded
Open this post in threaded view
|

Re: Configuring Seaside for deployment

Larry Kellogg

On Jan 13, 2012, at 6:05 PM, Dale Henrichs wrote:

> Lawrence,
>
> I think there must be a configuration setting that has been changed ... not sure which one though?
>

  I suppose so, but it is a mystery to me, at the moment. The sad thing is that I don't need Cloudfork under GLASS, after all.
Yesterday, I coded around the requirement for Cloudfork.

  So, I unloaded all of the Cloudfork packages, updated GLASS, loaded all kinds of changes from Monticello, but I still
cannot reach my server with http. I have no idea what config option I managed to change. I'll keep looking at it.

  Thanks for the help.

  Larry



> Dale
>
> ----- Original Message -----
> | From: "Lawrence Kellogg" <[hidden email]>
> | To: "GemStone Seaside beta discussion" <[hidden email]>
> | Sent: Friday, January 13, 2012 2:55:13 PM
> | Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
> |
> |
> | On Jan 13, 2012, at 5:49 PM, Dale Henrichs wrote:
> |
> | > Interesting ... Did you unload the old pacakge first? Do you happen
> | > to know if your current system (the one serving HTTP requests) was
> | > trying to use the class SecureHashAlgorithm? When you say "the
> | > SecureHashAlgorithm class does not exist in the image" do you mean
> | > you don't see it in the SystemBrowser or that you get an error
> | > message somewhere that is trying to use the class? What are you
> | > using to server http pages?
> | >
> |
> |   Yes, I unloaded the old package first. I don't believe my old
> |   system was using the SecureHashAlgorithm because that class fails
> |   when I try to
> | set a password on the Seaside config, which was what I was doing when
> | I started figuring out a deployment configuration..
> |
> |   I sent another note to the list. I have the SecureHashAlgorithm
> |   now, after loading it from Monticello, manually. I thought your
> |   command would load it
> | automatically. Sorry about that.
> |
> |   I am running Seaside to serve my http pages. I'm not sure why this
> |   new instance insists on https for everything.
> |
> |   Larry
> |
> |
> | > Dale
> | >
> | > ----- Original Message -----
> | > | From: "Lawrence Kellogg" <[hidden email]>
> | > | To: "GemStone Seaside beta discussion"
> | > | <[hidden email]>
> | > | Sent: Friday, January 13, 2012 2:23:39 PM
> | > | Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
> | > |
> | > |
> | > | On Jan 13, 2012, at 4:49 PM, Dale Henrichs wrote:
> | > |
> | > | > Lawrence,
> | > | >
> | > | > That should have been:
> | > | >
> | > | >  ConfigurationOfGsMisc project currentVersion load:
> | > | >  'System-Digital-Signatures'.
> | > | >
> | > |
> | > |   Well, this seems to work and returns this:
> | > |
> | > | Loading 0.239.1 of ConfigurationOfGsMisc...
> | > | ...finished 0.239.1
> | > |
> | > | but the SecureHashAlgorithm class does not exist in the image, I
> | > | don't get System-Digital-Signatures but I do have
> | > | System-Digital-Signatures-Tests. Puzzling.
> | > | Also, I can no longer reach my running server with a http, it
> | > | insists
> | > | on trying to use https, where it fails.
> | > |
> | > |
> | > |
> | > | > I recommend that you perform a backup[1] before doing a load of
> | > | > software, because then it is very easy to restore[2] to a known
> | > | > point ... I typically keep a number of backups around for this
> | > | > purpose.
> | > | >
> | > |
> | > |   At the moment, I have spun up two AMI instances, one called
> | > |   production and one called staging. I am doing my hacking on the
> | > |   staging instance.
> | > | Nothing is live, yet, but I should get used to not destroying the
> | > | production system. ;-) Your point is well taken, I will start
> | > | making
> | > | backups.
> | > |
> | > | > If SystemHashing is the only problem area (and you don't have a
> | > | > backup:), then you can unload the SystemHashing package using
> | > | > the
> | > | > Monticello browser[3], then load the GemStone version using the
> | > | > expression above ...
> | > | >
> | > | > Let me know if you have other issues,
> | > | >
> | > | > Dale
> | > | >
> | > | >
> | > | > [1] http://code.google.com/p/glassdb/wiki/GemToolsAdmin#Backup
> | > | > [2]
> | > | > http://code.google.com/p/glassdb/wiki/GemToolsAdmin#Restore_w/o_tranlogs
> | > | > [3]
> | > | > http://code.google.com/p/glassdb/wiki/GemToolsTools#Monticello
> | > | > ----- Original Message -----
> | > | > | From: "Lawrence Kellogg" <[hidden email]>
> | > | > | To: "GemStone Seaside beta discussion"
> | > | > | <[hidden email]>
> | > | > | Sent: Friday, January 13, 2012 1:03:34 PM
> | > | > | Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
> | > | > |
> | > | > |
> | > | > | On Jan 13, 2012, at 1:38 PM, Dale Henrichs wrote:
> | > | > |
> | > | > | > Lawrence,
> | > | > | >
> | > | > | > First off, there is an implementation of
> | > | > | > SecureHashAlgorithm
> | > | > | > already ported to GemStone. To load the correct version you
> | > | > | > can
> | > | > | > try this expression:
> | > | > | >
> | > | > | >  ConfigurationOfGsMisc currentVersion load:
> | > | > | >  'System-Digital-Signatures'.
> | > | > | >
> | > | > |
> | > | > |   Thanks Dale, unfortunately, my ConfigurationOfGsMisc class
> | > | > |   does
> | > | > |   not
> | > | > |   have a current method, so it fails.
> | > | > | I am on GemStone64Bit2.4.4.1-x86_64.Linux.
> | > | > |
> | > | > |   Did you mean:
> | > | > |
> | > | > |   ConfigurationOfGsMisc project load:
> | > | > |   'System-Digital-Signatures'
> | > | > |   ??
> | > | > |
> | > | > |   but that doesn't work because it expects a version string.
> | > | > |
> | > | > |   I know that I totally messed up my configuration when I
> | > | > |   loaded
> | > | > |   the
> | > | > |   System-Hashing stuff from Squeak.
> | > | > |
> | > | > |   How do I restore my Gemstone configuration?
> | > | > |
> | > | > |   Larry
> | > | > |
> | > | > |
> | > | > |
> | > | > | > Using the version that is already ported to GemStone will
> | > | > | > definitely address the issue you had with the
> | > | > | > #processBuffer
> | > | > | > method (MNU for #primHasSecureHashPrimitive).
> | > | > | >
> | > | > | >> From looking at the code, I would have to guess that you
> | > | > | >> must
> | > | > | >> be
> | > | > | >> passing in a FileStream in the #hashStream: method.
> | > | > | >> FileStream>>next: returns a nil explicitly and that looks
> | > | > | >> like
> | > | > | >> a
> | > | > | >> bug to me ... The fix would be for FileStream to return
> | > | > | >> result,
> | > | > | >> which should be empty on an error...
> | > | > | >
> | > | > | > If you're not using a FileStream there, then I would be
> | > | > | > interested
> | > | > | > in a stack to understand what is wrong ...
> | > | > | >
> | > | > | > Dale
> | > | > | > ----- Original Message -----
> | > | > | > | From: "Lawrence Kellogg" <[hidden email]>
> | > | > | > | To: "GemStone Seaside beta discussion"
> | > | > | > | <[hidden email]>
> | > | > | > | Sent: Thursday, January 12, 2012 8:41:44 PM
> | > | > | > | Subject: [GS/SS Beta] Configuring Seaside for deployment
> | > | > | > |
> | > | > | > | Hello,
> | > | > | > | So, I have started going through the chapter on what it
> | > | > | > | takes
> | > | > | > | to
> | > | > | > | deploy an application with Seaside.
> | > | > | > |
> | > | > | > |
> | > | > | > | I can bring up the Configuration option by clicking
> | > | > | > | Configure
> | > | > | > | at
> | > | > | > | the
> | > | > | > | bottom of the browser but if I try to
> | > | > | > | password prptect the configure app, I get a crash in the
> | > | > | > | SecureHashAlgorithm class, with the message
> | > | > | > |
> | > | > | > |
> | > | > | > | "Byte objects store values from 0 to 255, not nil"
> | > | > | > |
> | > | > | > |
> | > | > | > | (Same issue if I try to execute: "WAConfigurationTool
> | > | > | > | initialize"
> | > | > | > | initialize
> | > | > | > | (WAAdmin register: self asApplicationAt: 'config' user:
> | > | > | > | 'admin'
> | > | > | > | password: 'seaside') addLibrary: WAToolFiles)
> | > | > | > |
> | > | > | > |
> | > | > | > | The trouble is:
> | > | > | > |
> | > | > | > |
> | > | > | > | buf := aPositionableStream next: 64 which returns nil
> | > | > | > | when it
> | > | > | > | tries
> | > | > | > | to go through the next 64 elements,
> | > | > | > | there aren't 64 elements...
> | > | > | > |
> | > | > | > |
> | > | > | > | from here:
> | > | > | > |
> | > | > | > |
> | > | > | > |
> | > | > | > | hashStream: aPositionableStream
> | > | > | > | "Hash the contents of the given stream from the current
> | > | > | > | position
> | > | > | > | to
> | > | > | > | the end using the Secure Hash Algorithm. The SHA
> | > | > | > | algorithm is
> | > | > | > | defined in FIPS PUB 180-1. It is also described on p. 442
> | > | > | > | of
> | > | > | > | 'Applied Cryptography: Protocols, Algorithms, and Source
> | > | > | > | Code
> | > | > | > | in
> | > | > | > | C'
> | > | > | > | by Bruce Scheier, Wiley, 1996."
> | > | > | > | "SecureHashAlgorithm new hashStream: (ReadStream on:
> | > | > | > | 'foo')"
> | > | > | > | "(SecureHashAlgorithm new hashMessage: '') radix: 16
> | > | > | > | => 'DA39A3EE5E6B4B0D3255BFEF95601890AFD80709'"
> | > | > | > |
> | > | > | > | | startPosition buf bitLength |
> | > | > | > | self initializeTotals.
> | > | > | > |
> | > | > | > | aPositionableStream atEnd ifTrue: [self
> | > | > | > | processFinalBuffer:
> | > | > | > | #()
> | > | > | > | bitLength: 0].
> | > | > | > |
> | > | > | > |
> | > | > | > | startPosition := aPositionableStream position.
> | > | > | > | [aPositionableStream atEnd] whileFalse:
> | > | > | > | [ buf := aPositionableStream next: 64.
> | > | > | > | <<<<<<<<<<<<<<<<<<<<<<-----
> | > | > | > | (aPositionableStream atEnd not and: [buf size = 64])
> | > | > | > | ifTrue: [self processBuffer: buf]
> | > | > | > | ifFalse: [ bitLength := (aPositionableStream position -
> | > | > | > | startPosition) * 8.
> | > | > | > | self processFinalBuffer: buf bitLength: bitLength]].
> | > | > | > | ^ self finalHash
> | > | > | > |
> | > | > | > |
> | > | > | > | and also in SecureHashAlgorithm, which does not
> | > | > | > | understand
> | > | > | > |
> | > | > | > |
> | > | > | > | self primHasSecureHashPrimitive
> | > | > | > |
> | > | > | > |
> | > | > | > | from
> | > | > | > |
> | > | > | > |
> | > | > | > |
> | > | > | > | processBuffer: aByteArray
> | > | > | > | "Process given 64-byte buffer, accumulating the results
> | > | > | > | in
> | > | > | > | totalA
> | > | > | > | through totalE."
> | > | > | > |
> | > | > | > |
> | > | > | > | | a b c d e w tmp |
> | > | > | > | self <<<<<<<<<<<<<<<<<<<<<<<<<<<<
> | > | > | > | ifTrue: [^ self processBufferUsingPrimitives: aByteArray]
> | > | > | > | ifFalse: [totals := nil].
> | > | > | > |
> | > | > | > |
> | > | > | > | "initialize registers a through e from the current
> | > | > | > | totals"
> | > | > | > | a := totalA copy.
> | > | > | > | b := totalB copy.
> | > | > | > | c := totalC copy.
> | > | > | > | d := totalD copy.
> | > | > | > | e := totalE copy.
> | > | > | > |
> | > | > | > |
> | > | > | > | "expand and process the buffer"
> | > | > | > | w := self expandedBlock: aByteArray.
> | > | > | > | 1 to: 80 do: [:i |
> | > | > | > | tmp := (a copy leftRotateBy: 5)
> | > | > | > | += (self hashFunction: i of: b with: c with: d);
> | > | > | > | += e;
> | > | > | > | += (w at: i);
> | > | > | > | += (self constantForStep: i).
> | > | > | > | e := d.
> | > | > | > | d := c.
> | > | > | > | c := b copy leftRotateBy: 30.
> | > | > | > | b := a.
> | > | > | > | a := tmp].
> | > | > | > |
> | > | > | > |
> | > | > | > | "add a through e into total accumulators"
> | > | > | > | totalA += a.
> | > | > | > | totalB += b.
> | > | > | > | totalC += c.
> | > | > | > | totalD += d.
> | > | > | > | totalE += e.
> | > | > | > |
> | > | > | > |
> | > | > | > |
> | > | > | > |
> | > | > | > | I'm wondering if I somehow messed up my
> | > | > | > | SecureHashAlgorithm
> | > | > | > | class
> | > | > | > | with the other troubles I had
> | > | > | > | with Cloudfork or am I just destined to run into all
> | > | > | > | kinds of
> | > | > | > | security problems. ;-)
> | > | > | > |
> | > | > | > |
> | > | > | > | Any thoughts?
> | > | > | > |
> | > | > | > |
> | > | > | > |
> | > | > | > |
> | > | > | > | Larry
> | > | > | > |
> | > | > | > |
> | > | > |
> | > | > |
> | > |
> | > |
> |
> |

Reply | Threaded
Open this post in threaded view
|

Re: Configuring Seaside for deployment

Larry Kellogg

On Jan 13, 2012, at 6:37 PM, Lawrence Kellogg wrote:

>
> On Jan 13, 2012, at 6:05 PM, Dale Henrichs wrote:
>
>> Lawrence,
>>
>> I think there must be a configuration setting that has been changed ... not sure which one though?
>>
>
>  I suppose so, but it is a mystery to me, at the moment. The sad thing is that I don't need Cloudfork under GLASS, after all.
> Yesterday, I coded around the requirement for Cloudfork.
>
>  So, I unloaded all of the Cloudfork packages, updated GLASS, loaded all kinds of changes from Monticello, but I still
> cannot reach my server with http. I have no idea what config option I managed to change. I'll keep looking at it.
>
>  Thanks for the help.
>

  Well, here is an interesting fact. I can navigate to the default Seaside page, and run the configuration, without any problems.
If I try to bring up my login task, a WATask, the request gets changed to https and I cannot reach the server.

  Does this fact help in any way? I re-ran the initialize code on my WATask but it did not make any difference.

  Larry




>  Larry
>
>
>
>> Dale
>>
>> ----- Original Message -----
>> | From: "Lawrence Kellogg" <[hidden email]>
>> | To: "GemStone Seaside beta discussion" <[hidden email]>
>> | Sent: Friday, January 13, 2012 2:55:13 PM
>> | Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
>> |
>> |
>> | On Jan 13, 2012, at 5:49 PM, Dale Henrichs wrote:
>> |
>> | > Interesting ... Did you unload the old pacakge first? Do you happen
>> | > to know if your current system (the one serving HTTP requests) was
>> | > trying to use the class SecureHashAlgorithm? When you say "the
>> | > SecureHashAlgorithm class does not exist in the image" do you mean
>> | > you don't see it in the SystemBrowser or that you get an error
>> | > message somewhere that is trying to use the class? What are you
>> | > using to server http pages?
>> | >
>> |
>> |   Yes, I unloaded the old package first. I don't believe my old
>> |   system was using the SecureHashAlgorithm because that class fails
>> |   when I try to
>> | set a password on the Seaside config, which was what I was doing when
>> | I started figuring out a deployment configuration..
>> |
>> |   I sent another note to the list. I have the SecureHashAlgorithm
>> |   now, after loading it from Monticello, manually. I thought your
>> |   command would load it
>> | automatically. Sorry about that.
>> |
>> |   I am running Seaside to serve my http pages. I'm not sure why this
>> |   new instance insists on https for everything.
>> |
>> |   Larry
>> |
>> |
>> | > Dale
>> | >
>> | > ----- Original Message -----
>> | > | From: "Lawrence Kellogg" <[hidden email]>
>> | > | To: "GemStone Seaside beta discussion"
>> | > | <[hidden email]>
>> | > | Sent: Friday, January 13, 2012 2:23:39 PM
>> | > | Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
>> | > |
>> | > |
>> | > | On Jan 13, 2012, at 4:49 PM, Dale Henrichs wrote:
>> | > |
>> | > | > Lawrence,
>> | > | >
>> | > | > That should have been:
>> | > | >
>> | > | >  ConfigurationOfGsMisc project currentVersion load:
>> | > | >  'System-Digital-Signatures'.
>> | > | >
>> | > |
>> | > |   Well, this seems to work and returns this:
>> | > |
>> | > | Loading 0.239.1 of ConfigurationOfGsMisc...
>> | > | ...finished 0.239.1
>> | > |
>> | > | but the SecureHashAlgorithm class does not exist in the image, I
>> | > | don't get System-Digital-Signatures but I do have
>> | > | System-Digital-Signatures-Tests. Puzzling.
>> | > | Also, I can no longer reach my running server with a http, it
>> | > | insists
>> | > | on trying to use https, where it fails.
>> | > |
>> | > |
>> | > |
>> | > | > I recommend that you perform a backup[1] before doing a load of
>> | > | > software, because then it is very easy to restore[2] to a known
>> | > | > point ... I typically keep a number of backups around for this
>> | > | > purpose.
>> | > | >
>> | > |
>> | > |   At the moment, I have spun up two AMI instances, one called
>> | > |   production and one called staging. I am doing my hacking on the
>> | > |   staging instance.
>> | > | Nothing is live, yet, but I should get used to not destroying the
>> | > | production system. ;-) Your point is well taken, I will start
>> | > | making
>> | > | backups.
>> | > |
>> | > | > If SystemHashing is the only problem area (and you don't have a
>> | > | > backup:), then you can unload the SystemHashing package using
>> | > | > the
>> | > | > Monticello browser[3], then load the GemStone version using the
>> | > | > expression above ...
>> | > | >
>> | > | > Let me know if you have other issues,
>> | > | >
>> | > | > Dale
>> | > | >
>> | > | >
>> | > | > [1] http://code.google.com/p/glassdb/wiki/GemToolsAdmin#Backup
>> | > | > [2]
>> | > | > http://code.google.com/p/glassdb/wiki/GemToolsAdmin#Restore_w/o_tranlogs
>> | > | > [3]
>> | > | > http://code.google.com/p/glassdb/wiki/GemToolsTools#Monticello
>> | > | > ----- Original Message -----
>> | > | > | From: "Lawrence Kellogg" <[hidden email]>
>> | > | > | To: "GemStone Seaside beta discussion"
>> | > | > | <[hidden email]>
>> | > | > | Sent: Friday, January 13, 2012 1:03:34 PM
>> | > | > | Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
>> | > | > |
>> | > | > |
>> | > | > | On Jan 13, 2012, at 1:38 PM, Dale Henrichs wrote:
>> | > | > |
>> | > | > | > Lawrence,
>> | > | > | >
>> | > | > | > First off, there is an implementation of
>> | > | > | > SecureHashAlgorithm
>> | > | > | > already ported to GemStone. To load the correct version you
>> | > | > | > can
>> | > | > | > try this expression:
>> | > | > | >
>> | > | > | >  ConfigurationOfGsMisc currentVersion load:
>> | > | > | >  'System-Digital-Signatures'.
>> | > | > | >
>> | > | > |
>> | > | > |   Thanks Dale, unfortunately, my ConfigurationOfGsMisc class
>> | > | > |   does
>> | > | > |   not
>> | > | > |   have a current method, so it fails.
>> | > | > | I am on GemStone64Bit2.4.4.1-x86_64.Linux.
>> | > | > |
>> | > | > |   Did you mean:
>> | > | > |
>> | > | > |   ConfigurationOfGsMisc project load:
>> | > | > |   'System-Digital-Signatures'
>> | > | > |   ??
>> | > | > |
>> | > | > |   but that doesn't work because it expects a version string.
>> | > | > |
>> | > | > |   I know that I totally messed up my configuration when I
>> | > | > |   loaded
>> | > | > |   the
>> | > | > |   System-Hashing stuff from Squeak.
>> | > | > |
>> | > | > |   How do I restore my Gemstone configuration?
>> | > | > |
>> | > | > |   Larry
>> | > | > |
>> | > | > |
>> | > | > |
>> | > | > | > Using the version that is already ported to GemStone will
>> | > | > | > definitely address the issue you had with the
>> | > | > | > #processBuffer
>> | > | > | > method (MNU for #primHasSecureHashPrimitive).
>> | > | > | >
>> | > | > | >> From looking at the code, I would have to guess that you
>> | > | > | >> must
>> | > | > | >> be
>> | > | > | >> passing in a FileStream in the #hashStream: method.
>> | > | > | >> FileStream>>next: returns a nil explicitly and that looks
>> | > | > | >> like
>> | > | > | >> a
>> | > | > | >> bug to me ... The fix would be for FileStream to return
>> | > | > | >> result,
>> | > | > | >> which should be empty on an error...
>> | > | > | >
>> | > | > | > If you're not using a FileStream there, then I would be
>> | > | > | > interested
>> | > | > | > in a stack to understand what is wrong ...
>> | > | > | >
>> | > | > | > Dale
>> | > | > | > ----- Original Message -----
>> | > | > | > | From: "Lawrence Kellogg" <[hidden email]>
>> | > | > | > | To: "GemStone Seaside beta discussion"
>> | > | > | > | <[hidden email]>
>> | > | > | > | Sent: Thursday, January 12, 2012 8:41:44 PM
>> | > | > | > | Subject: [GS/SS Beta] Configuring Seaside for deployment
>> | > | > | > |
>> | > | > | > | Hello,
>> | > | > | > | So, I have started going through the chapter on what it
>> | > | > | > | takes
>> | > | > | > | to
>> | > | > | > | deploy an application with Seaside.
>> | > | > | > |
>> | > | > | > |
>> | > | > | > | I can bring up the Configuration option by clicking
>> | > | > | > | Configure
>> | > | > | > | at
>> | > | > | > | the
>> | > | > | > | bottom of the browser but if I try to
>> | > | > | > | password prptect the configure app, I get a crash in the
>> | > | > | > | SecureHashAlgorithm class, with the message
>> | > | > | > |
>> | > | > | > |
>> | > | > | > | "Byte objects store values from 0 to 255, not nil"
>> | > | > | > |
>> | > | > | > |
>> | > | > | > | (Same issue if I try to execute: "WAConfigurationTool
>> | > | > | > | initialize"
>> | > | > | > | initialize
>> | > | > | > | (WAAdmin register: self asApplicationAt: 'config' user:
>> | > | > | > | 'admin'
>> | > | > | > | password: 'seaside') addLibrary: WAToolFiles)
>> | > | > | > |
>> | > | > | > |
>> | > | > | > | The trouble is:
>> | > | > | > |
>> | > | > | > |
>> | > | > | > | buf := aPositionableStream next: 64 which returns nil
>> | > | > | > | when it
>> | > | > | > | tries
>> | > | > | > | to go through the next 64 elements,
>> | > | > | > | there aren't 64 elements...
>> | > | > | > |
>> | > | > | > |
>> | > | > | > | from here:
>> | > | > | > |
>> | > | > | > |
>> | > | > | > |
>> | > | > | > | hashStream: aPositionableStream
>> | > | > | > | "Hash the contents of the given stream from the current
>> | > | > | > | position
>> | > | > | > | to
>> | > | > | > | the end using the Secure Hash Algorithm. The SHA
>> | > | > | > | algorithm is
>> | > | > | > | defined in FIPS PUB 180-1. It is also described on p. 442
>> | > | > | > | of
>> | > | > | > | 'Applied Cryptography: Protocols, Algorithms, and Source
>> | > | > | > | Code
>> | > | > | > | in
>> | > | > | > | C'
>> | > | > | > | by Bruce Scheier, Wiley, 1996."
>> | > | > | > | "SecureHashAlgorithm new hashStream: (ReadStream on:
>> | > | > | > | 'foo')"
>> | > | > | > | "(SecureHashAlgorithm new hashMessage: '') radix: 16
>> | > | > | > | => 'DA39A3EE5E6B4B0D3255BFEF95601890AFD80709'"
>> | > | > | > |
>> | > | > | > | | startPosition buf bitLength |
>> | > | > | > | self initializeTotals.
>> | > | > | > |
>> | > | > | > | aPositionableStream atEnd ifTrue: [self
>> | > | > | > | processFinalBuffer:
>> | > | > | > | #()
>> | > | > | > | bitLength: 0].
>> | > | > | > |
>> | > | > | > |
>> | > | > | > | startPosition := aPositionableStream position.
>> | > | > | > | [aPositionableStream atEnd] whileFalse:
>> | > | > | > | [ buf := aPositionableStream next: 64.
>> | > | > | > | <<<<<<<<<<<<<<<<<<<<<<-----
>> | > | > | > | (aPositionableStream atEnd not and: [buf size = 64])
>> | > | > | > | ifTrue: [self processBuffer: buf]
>> | > | > | > | ifFalse: [ bitLength := (aPositionableStream position -
>> | > | > | > | startPosition) * 8.
>> | > | > | > | self processFinalBuffer: buf bitLength: bitLength]].
>> | > | > | > | ^ self finalHash
>> | > | > | > |
>> | > | > | > |
>> | > | > | > | and also in SecureHashAlgorithm, which does not
>> | > | > | > | understand
>> | > | > | > |
>> | > | > | > |
>> | > | > | > | self primHasSecureHashPrimitive
>> | > | > | > |
>> | > | > | > |
>> | > | > | > | from
>> | > | > | > |
>> | > | > | > |
>> | > | > | > |
>> | > | > | > | processBuffer: aByteArray
>> | > | > | > | "Process given 64-byte buffer, accumulating the results
>> | > | > | > | in
>> | > | > | > | totalA
>> | > | > | > | through totalE."
>> | > | > | > |
>> | > | > | > |
>> | > | > | > | | a b c d e w tmp |
>> | > | > | > | self <<<<<<<<<<<<<<<<<<<<<<<<<<<<
>> | > | > | > | ifTrue: [^ self processBufferUsingPrimitives: aByteArray]
>> | > | > | > | ifFalse: [totals := nil].
>> | > | > | > |
>> | > | > | > |
>> | > | > | > | "initialize registers a through e from the current
>> | > | > | > | totals"
>> | > | > | > | a := totalA copy.
>> | > | > | > | b := totalB copy.
>> | > | > | > | c := totalC copy.
>> | > | > | > | d := totalD copy.
>> | > | > | > | e := totalE copy.
>> | > | > | > |
>> | > | > | > |
>> | > | > | > | "expand and process the buffer"
>> | > | > | > | w := self expandedBlock: aByteArray.
>> | > | > | > | 1 to: 80 do: [:i |
>> | > | > | > | tmp := (a copy leftRotateBy: 5)
>> | > | > | > | += (self hashFunction: i of: b with: c with: d);
>> | > | > | > | += e;
>> | > | > | > | += (w at: i);
>> | > | > | > | += (self constantForStep: i).
>> | > | > | > | e := d.
>> | > | > | > | d := c.
>> | > | > | > | c := b copy leftRotateBy: 30.
>> | > | > | > | b := a.
>> | > | > | > | a := tmp].
>> | > | > | > |
>> | > | > | > |
>> | > | > | > | "add a through e into total accumulators"
>> | > | > | > | totalA += a.
>> | > | > | > | totalB += b.
>> | > | > | > | totalC += c.
>> | > | > | > | totalD += d.
>> | > | > | > | totalE += e.
>> | > | > | > |
>> | > | > | > |
>> | > | > | > |
>> | > | > | > |
>> | > | > | > | I'm wondering if I somehow messed up my
>> | > | > | > | SecureHashAlgorithm
>> | > | > | > | class
>> | > | > | > | with the other troubles I had
>> | > | > | > | with Cloudfork or am I just destined to run into all
>> | > | > | > | kinds of
>> | > | > | > | security problems. ;-)
>> | > | > | > |
>> | > | > | > |
>> | > | > | > | Any thoughts?
>> | > | > | > |
>> | > | > | > |
>> | > | > | > |
>> | > | > | > |
>> | > | > | > | Larry
>> | > | > | > |
>> | > | > | > |
>> | > | > |
>> | > | > |
>> | > |
>> | > |
>> |
>> |
>

Reply | Threaded
Open this post in threaded view
|

Re: Configuring Seaside for deployment

Dale Henrichs
Lawrence,

I'll have to dig into Seaside a bit on over the weekend (holiday on Monday) to check into this...which adaptor are you using (FastCGI, Swazoo, or Zinc)?

Dale

----- Original Message -----
| From: "Lawrence Kellogg" <[hidden email]>
| To: "GemStone Seaside beta discussion" <[hidden email]>
| Sent: Friday, January 13, 2012 4:16:07 PM
| Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
|
|
| On Jan 13, 2012, at 6:37 PM, Lawrence Kellogg wrote:
|
| >
| > On Jan 13, 2012, at 6:05 PM, Dale Henrichs wrote:
| >
| >> Lawrence,
| >>
| >> I think there must be a configuration setting that has been
| >> changed ... not sure which one though?
| >>
| >
| >  I suppose so, but it is a mystery to me, at the moment. The sad
| >  thing is that I don't need Cloudfork under GLASS, after all.
| > Yesterday, I coded around the requirement for Cloudfork.
| >
| >  So, I unloaded all of the Cloudfork packages, updated GLASS,
| >  loaded all kinds of changes from Monticello, but I still
| > cannot reach my server with http. I have no idea what config option
| > I managed to change. I'll keep looking at it.
| >
| >  Thanks for the help.
| >
|
|   Well, here is an interesting fact. I can navigate to the default
|   Seaside page, and run the configuration, without any problems.
| If I try to bring up my login task, a WATask, the request gets
| changed to https and I cannot reach the server.
|
|   Does this fact help in any way? I re-ran the initialize code on my
|   WATask but it did not make any difference.
|
|   Larry
|
|
|
|
| >  Larry
| >
| >
| >
| >> Dale
| >>
| >> ----- Original Message -----
| >> | From: "Lawrence Kellogg" <[hidden email]>
| >> | To: "GemStone Seaside beta discussion"
| >> | <[hidden email]>
| >> | Sent: Friday, January 13, 2012 2:55:13 PM
| >> | Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
| >> |
| >> |
| >> | On Jan 13, 2012, at 5:49 PM, Dale Henrichs wrote:
| >> |
| >> | > Interesting ... Did you unload the old pacakge first? Do you
| >> | > happen
| >> | > to know if your current system (the one serving HTTP requests)
| >> | > was
| >> | > trying to use the class SecureHashAlgorithm? When you say "the
| >> | > SecureHashAlgorithm class does not exist in the image" do you
| >> | > mean
| >> | > you don't see it in the SystemBrowser or that you get an error
| >> | > message somewhere that is trying to use the class? What are
| >> | > you
| >> | > using to server http pages?
| >> | >
| >> |
| >> |   Yes, I unloaded the old package first. I don't believe my old
| >> |   system was using the SecureHashAlgorithm because that class
| >> |   fails
| >> |   when I try to
| >> | set a password on the Seaside config, which was what I was doing
| >> | when
| >> | I started figuring out a deployment configuration..
| >> |
| >> |   I sent another note to the list. I have the
| >> |   SecureHashAlgorithm
| >> |   now, after loading it from Monticello, manually. I thought
| >> |   your
| >> |   command would load it
| >> | automatically. Sorry about that.
| >> |
| >> |   I am running Seaside to serve my http pages. I'm not sure why
| >> |   this
| >> |   new instance insists on https for everything.
| >> |
| >> |   Larry
| >> |
| >> |
| >> | > Dale
| >> | >
| >> | > ----- Original Message -----
| >> | > | From: "Lawrence Kellogg" <[hidden email]>
| >> | > | To: "GemStone Seaside beta discussion"
| >> | > | <[hidden email]>
| >> | > | Sent: Friday, January 13, 2012 2:23:39 PM
| >> | > | Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
| >> | > |
| >> | > |
| >> | > | On Jan 13, 2012, at 4:49 PM, Dale Henrichs wrote:
| >> | > |
| >> | > | > Lawrence,
| >> | > | >
| >> | > | > That should have been:
| >> | > | >
| >> | > | >  ConfigurationOfGsMisc project currentVersion load:
| >> | > | >  'System-Digital-Signatures'.
| >> | > | >
| >> | > |
| >> | > |   Well, this seems to work and returns this:
| >> | > |
| >> | > | Loading 0.239.1 of ConfigurationOfGsMisc...
| >> | > | ...finished 0.239.1
| >> | > |
| >> | > | but the SecureHashAlgorithm class does not exist in the
| >> | > | image, I
| >> | > | don't get System-Digital-Signatures but I do have
| >> | > | System-Digital-Signatures-Tests. Puzzling.
| >> | > | Also, I can no longer reach my running server with a http,
| >> | > | it
| >> | > | insists
| >> | > | on trying to use https, where it fails.
| >> | > |
| >> | > |
| >> | > |
| >> | > | > I recommend that you perform a backup[1] before doing a
| >> | > | > load of
| >> | > | > software, because then it is very easy to restore[2] to a
| >> | > | > known
| >> | > | > point ... I typically keep a number of backups around for
| >> | > | > this
| >> | > | > purpose.
| >> | > | >
| >> | > |
| >> | > |   At the moment, I have spun up two AMI instances, one
| >> | > |   called
| >> | > |   production and one called staging. I am doing my hacking
| >> | > |   on the
| >> | > |   staging instance.
| >> | > | Nothing is live, yet, but I should get used to not
| >> | > | destroying the
| >> | > | production system. ;-) Your point is well taken, I will
| >> | > | start
| >> | > | making
| >> | > | backups.
| >> | > |
| >> | > | > If SystemHashing is the only problem area (and you don't
| >> | > | > have a
| >> | > | > backup:), then you can unload the SystemHashing package
| >> | > | > using
| >> | > | > the
| >> | > | > Monticello browser[3], then load the GemStone version
| >> | > | > using the
| >> | > | > expression above ...
| >> | > | >
| >> | > | > Let me know if you have other issues,
| >> | > | >
| >> | > | > Dale
| >> | > | >
| >> | > | >
| >> | > | > [1]
| >> | > | > http://code.google.com/p/glassdb/wiki/GemToolsAdmin#Backup
| >> | > | > [2]
| >> | > | > http://code.google.com/p/glassdb/wiki/GemToolsAdmin#Restore_w/o_tranlogs
| >> | > | > [3]
| >> | > | > http://code.google.com/p/glassdb/wiki/GemToolsTools#Monticello
| >> | > | > ----- Original Message -----
| >> | > | > | From: "Lawrence Kellogg" <[hidden email]>
| >> | > | > | To: "GemStone Seaside beta discussion"
| >> | > | > | <[hidden email]>
| >> | > | > | Sent: Friday, January 13, 2012 1:03:34 PM
| >> | > | > | Subject: Re: [GS/SS Beta] Configuring Seaside for
| >> | > | > | deployment
| >> | > | > |
| >> | > | > |
| >> | > | > | On Jan 13, 2012, at 1:38 PM, Dale Henrichs wrote:
| >> | > | > |
| >> | > | > | > Lawrence,
| >> | > | > | >
| >> | > | > | > First off, there is an implementation of
| >> | > | > | > SecureHashAlgorithm
| >> | > | > | > already ported to GemStone. To load the correct
| >> | > | > | > version you
| >> | > | > | > can
| >> | > | > | > try this expression:
| >> | > | > | >
| >> | > | > | >  ConfigurationOfGsMisc currentVersion load:
| >> | > | > | >  'System-Digital-Signatures'.
| >> | > | > | >
| >> | > | > |
| >> | > | > |   Thanks Dale, unfortunately, my ConfigurationOfGsMisc
| >> | > | > |   class
| >> | > | > |   does
| >> | > | > |   not
| >> | > | > |   have a current method, so it fails.
| >> | > | > | I am on GemStone64Bit2.4.4.1-x86_64.Linux.
| >> | > | > |
| >> | > | > |   Did you mean:
| >> | > | > |
| >> | > | > |   ConfigurationOfGsMisc project load:
| >> | > | > |   'System-Digital-Signatures'
| >> | > | > |   ??
| >> | > | > |
| >> | > | > |   but that doesn't work because it expects a version
| >> | > | > |   string.
| >> | > | > |
| >> | > | > |   I know that I totally messed up my configuration when
| >> | > | > |   I
| >> | > | > |   loaded
| >> | > | > |   the
| >> | > | > |   System-Hashing stuff from Squeak.
| >> | > | > |
| >> | > | > |   How do I restore my Gemstone configuration?
| >> | > | > |
| >> | > | > |   Larry
| >> | > | > |
| >> | > | > |
| >> | > | > |
| >> | > | > | > Using the version that is already ported to GemStone
| >> | > | > | > will
| >> | > | > | > definitely address the issue you had with the
| >> | > | > | > #processBuffer
| >> | > | > | > method (MNU for #primHasSecureHashPrimitive).
| >> | > | > | >
| >> | > | > | >> From looking at the code, I would have to guess that
| >> | > | > | >> you
| >> | > | > | >> must
| >> | > | > | >> be
| >> | > | > | >> passing in a FileStream in the #hashStream: method.
| >> | > | > | >> FileStream>>next: returns a nil explicitly and that
| >> | > | > | >> looks
| >> | > | > | >> like
| >> | > | > | >> a
| >> | > | > | >> bug to me ... The fix would be for FileStream to
| >> | > | > | >> return
| >> | > | > | >> result,
| >> | > | > | >> which should be empty on an error...
| >> | > | > | >
| >> | > | > | > If you're not using a FileStream there, then I would
| >> | > | > | > be
| >> | > | > | > interested
| >> | > | > | > in a stack to understand what is wrong ...
| >> | > | > | >
| >> | > | > | > Dale
| >> | > | > | > ----- Original Message -----
| >> | > | > | > | From: "Lawrence Kellogg" <[hidden email]>
| >> | > | > | > | To: "GemStone Seaside beta discussion"
| >> | > | > | > | <[hidden email]>
| >> | > | > | > | Sent: Thursday, January 12, 2012 8:41:44 PM
| >> | > | > | > | Subject: [GS/SS Beta] Configuring Seaside for
| >> | > | > | > | deployment
| >> | > | > | > |
| >> | > | > | > | Hello,
| >> | > | > | > | So, I have started going through the chapter on what
| >> | > | > | > | it
| >> | > | > | > | takes
| >> | > | > | > | to
| >> | > | > | > | deploy an application with Seaside.
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | I can bring up the Configuration option by clicking
| >> | > | > | > | Configure
| >> | > | > | > | at
| >> | > | > | > | the
| >> | > | > | > | bottom of the browser but if I try to
| >> | > | > | > | password prptect the configure app, I get a crash in
| >> | > | > | > | the
| >> | > | > | > | SecureHashAlgorithm class, with the message
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | "Byte objects store values from 0 to 255, not nil"
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | (Same issue if I try to execute:
| >> | > | > | > | "WAConfigurationTool
| >> | > | > | > | initialize"
| >> | > | > | > | initialize
| >> | > | > | > | (WAAdmin register: self asApplicationAt: 'config'
| >> | > | > | > | user:
| >> | > | > | > | 'admin'
| >> | > | > | > | password: 'seaside') addLibrary: WAToolFiles)
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | The trouble is:
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | buf := aPositionableStream next: 64 which returns
| >> | > | > | > | nil
| >> | > | > | > | when it
| >> | > | > | > | tries
| >> | > | > | > | to go through the next 64 elements,
| >> | > | > | > | there aren't 64 elements...
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | from here:
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | hashStream: aPositionableStream
| >> | > | > | > | "Hash the contents of the given stream from the
| >> | > | > | > | current
| >> | > | > | > | position
| >> | > | > | > | to
| >> | > | > | > | the end using the Secure Hash Algorithm. The SHA
| >> | > | > | > | algorithm is
| >> | > | > | > | defined in FIPS PUB 180-1. It is also described on
| >> | > | > | > | p. 442
| >> | > | > | > | of
| >> | > | > | > | 'Applied Cryptography: Protocols, Algorithms, and
| >> | > | > | > | Source
| >> | > | > | > | Code
| >> | > | > | > | in
| >> | > | > | > | C'
| >> | > | > | > | by Bruce Scheier, Wiley, 1996."
| >> | > | > | > | "SecureHashAlgorithm new hashStream: (ReadStream on:
| >> | > | > | > | 'foo')"
| >> | > | > | > | "(SecureHashAlgorithm new hashMessage: '') radix: 16
| >> | > | > | > | => 'DA39A3EE5E6B4B0D3255BFEF95601890AFD80709'"
| >> | > | > | > |
| >> | > | > | > | | startPosition buf bitLength |
| >> | > | > | > | self initializeTotals.
| >> | > | > | > |
| >> | > | > | > | aPositionableStream atEnd ifTrue: [self
| >> | > | > | > | processFinalBuffer:
| >> | > | > | > | #()
| >> | > | > | > | bitLength: 0].
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | startPosition := aPositionableStream position.
| >> | > | > | > | [aPositionableStream atEnd] whileFalse:
| >> | > | > | > | [ buf := aPositionableStream next: 64.
| >> | > | > | > | <<<<<<<<<<<<<<<<<<<<<<-----
| >> | > | > | > | (aPositionableStream atEnd not and: [buf size = 64])
| >> | > | > | > | ifTrue: [self processBuffer: buf]
| >> | > | > | > | ifFalse: [ bitLength := (aPositionableStream
| >> | > | > | > | position -
| >> | > | > | > | startPosition) * 8.
| >> | > | > | > | self processFinalBuffer: buf bitLength: bitLength]].
| >> | > | > | > | ^ self finalHash
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | and also in SecureHashAlgorithm, which does not
| >> | > | > | > | understand
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | self primHasSecureHashPrimitive
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | from
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | processBuffer: aByteArray
| >> | > | > | > | "Process given 64-byte buffer, accumulating the
| >> | > | > | > | results
| >> | > | > | > | in
| >> | > | > | > | totalA
| >> | > | > | > | through totalE."
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | | a b c d e w tmp |
| >> | > | > | > | self <<<<<<<<<<<<<<<<<<<<<<<<<<<<
| >> | > | > | > | ifTrue: [^ self processBufferUsingPrimitives:
| >> | > | > | > | aByteArray]
| >> | > | > | > | ifFalse: [totals := nil].
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | "initialize registers a through e from the current
| >> | > | > | > | totals"
| >> | > | > | > | a := totalA copy.
| >> | > | > | > | b := totalB copy.
| >> | > | > | > | c := totalC copy.
| >> | > | > | > | d := totalD copy.
| >> | > | > | > | e := totalE copy.
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | "expand and process the buffer"
| >> | > | > | > | w := self expandedBlock: aByteArray.
| >> | > | > | > | 1 to: 80 do: [:i |
| >> | > | > | > | tmp := (a copy leftRotateBy: 5)
| >> | > | > | > | += (self hashFunction: i of: b with: c with: d);
| >> | > | > | > | += e;
| >> | > | > | > | += (w at: i);
| >> | > | > | > | += (self constantForStep: i).
| >> | > | > | > | e := d.
| >> | > | > | > | d := c.
| >> | > | > | > | c := b copy leftRotateBy: 30.
| >> | > | > | > | b := a.
| >> | > | > | > | a := tmp].
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | "add a through e into total accumulators"
| >> | > | > | > | totalA += a.
| >> | > | > | > | totalB += b.
| >> | > | > | > | totalC += c.
| >> | > | > | > | totalD += d.
| >> | > | > | > | totalE += e.
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | I'm wondering if I somehow messed up my
| >> | > | > | > | SecureHashAlgorithm
| >> | > | > | > | class
| >> | > | > | > | with the other troubles I had
| >> | > | > | > | with Cloudfork or am I just destined to run into all
| >> | > | > | > | kinds of
| >> | > | > | > | security problems. ;-)
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | Any thoughts?
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | Larry
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > |
| >> | > | > |
| >> | > |
| >> | > |
| >> |
| >> |
| >
|
|
Reply | Threaded
Open this post in threaded view
|

Re: Configuring Seaside for deployment

Larry Kellogg

On Jan 13, 2012, at 8:13 PM, Dale Henrichs wrote:

> Lawrence,
>
> I'll have to dig into Seaside a bit on over the weekend (holiday on Monday) to check into this...which adaptor are you using (FastCGI, Swazoo, or Zinc)?
>

  I run the FastCGI servers on port 9001 and I'm reaching Seaside through Swazoo running on port 8080.
I'll keep poking around.

  Thanks for the help!

  Larry


> Dale
>
> ----- Original Message -----
> | From: "Lawrence Kellogg" <[hidden email]>
> | To: "GemStone Seaside beta discussion" <[hidden email]>
> | Sent: Friday, January 13, 2012 4:16:07 PM
> | Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
> |
> |
> | On Jan 13, 2012, at 6:37 PM, Lawrence Kellogg wrote:
> |
> | >
> | > On Jan 13, 2012, at 6:05 PM, Dale Henrichs wrote:
> | >
> | >> Lawrence,
> | >>
> | >> I think there must be a configuration setting that has been
> | >> changed ... not sure which one though?
> | >>
> | >
> | >  I suppose so, but it is a mystery to me, at the moment. The sad
> | >  thing is that I don't need Cloudfork under GLASS, after all.
> | > Yesterday, I coded around the requirement for Cloudfork.
> | >
> | >  So, I unloaded all of the Cloudfork packages, updated GLASS,
> | >  loaded all kinds of changes from Monticello, but I still
> | > cannot reach my server with http. I have no idea what config option
> | > I managed to change. I'll keep looking at it.
> | >
> | >  Thanks for the help.
> | >
> |
> |   Well, here is an interesting fact. I can navigate to the default
> |   Seaside page, and run the configuration, without any problems.
> | If I try to bring up my login task, a WATask, the request gets
> | changed to https and I cannot reach the server.
> |
> |   Does this fact help in any way? I re-ran the initialize code on my
> |   WATask but it did not make any difference.
> |
> |   Larry
> |
> |
> |
> |
> | >  Larry
> | >
> | >
> | >
> | >> Dale
> | >>
> | >> ----- Original Message -----
> | >> | From: "Lawrence Kellogg" <[hidden email]>
> | >> | To: "GemStone Seaside beta discussion"
> | >> | <[hidden email]>
> | >> | Sent: Friday, January 13, 2012 2:55:13 PM
> | >> | Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
> | >> |
> | >> |
> | >> | On Jan 13, 2012, at 5:49 PM, Dale Henrichs wrote:
> | >> |
> | >> | > Interesting ... Did you unload the old pacakge first? Do you
> | >> | > happen
> | >> | > to know if your current system (the one serving HTTP requests)
> | >> | > was
> | >> | > trying to use the class SecureHashAlgorithm? When you say "the
> | >> | > SecureHashAlgorithm class does not exist in the image" do you
> | >> | > mean
> | >> | > you don't see it in the SystemBrowser or that you get an error
> | >> | > message somewhere that is trying to use the class? What are
> | >> | > you
> | >> | > using to server http pages?
> | >> | >
> | >> |
> | >> |   Yes, I unloaded the old package first. I don't believe my old
> | >> |   system was using the SecureHashAlgorithm because that class
> | >> |   fails
> | >> |   when I try to
> | >> | set a password on the Seaside config, which was what I was doing
> | >> | when
> | >> | I started figuring out a deployment configuration..
> | >> |
> | >> |   I sent another note to the list. I have the
> | >> |   SecureHashAlgorithm
> | >> |   now, after loading it from Monticello, manually. I thought
> | >> |   your
> | >> |   command would load it
> | >> | automatically. Sorry about that.
> | >> |
> | >> |   I am running Seaside to serve my http pages. I'm not sure why
> | >> |   this
> | >> |   new instance insists on https for everything.
> | >> |
> | >> |   Larry
> | >> |
> | >> |
> | >> | > Dale
> | >> | >
> | >> | > ----- Original Message -----
> | >> | > | From: "Lawrence Kellogg" <[hidden email]>
> | >> | > | To: "GemStone Seaside beta discussion"
> | >> | > | <[hidden email]>
> | >> | > | Sent: Friday, January 13, 2012 2:23:39 PM
> | >> | > | Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
> | >> | > |
> | >> | > |
> | >> | > | On Jan 13, 2012, at 4:49 PM, Dale Henrichs wrote:
> | >> | > |
> | >> | > | > Lawrence,
> | >> | > | >
> | >> | > | > That should have been:
> | >> | > | >
> | >> | > | >  ConfigurationOfGsMisc project currentVersion load:
> | >> | > | >  'System-Digital-Signatures'.
> | >> | > | >
> | >> | > |
> | >> | > |   Well, this seems to work and returns this:
> | >> | > |
> | >> | > | Loading 0.239.1 of ConfigurationOfGsMisc...
> | >> | > | ...finished 0.239.1
> | >> | > |
> | >> | > | but the SecureHashAlgorithm class does not exist in the
> | >> | > | image, I
> | >> | > | don't get System-Digital-Signatures but I do have
> | >> | > | System-Digital-Signatures-Tests. Puzzling.
> | >> | > | Also, I can no longer reach my running server with a http,
> | >> | > | it
> | >> | > | insists
> | >> | > | on trying to use https, where it fails.
> | >> | > |
> | >> | > |
> | >> | > |
> | >> | > | > I recommend that you perform a backup[1] before doing a
> | >> | > | > load of
> | >> | > | > software, because then it is very easy to restore[2] to a
> | >> | > | > known
> | >> | > | > point ... I typically keep a number of backups around for
> | >> | > | > this
> | >> | > | > purpose.
> | >> | > | >
> | >> | > |
> | >> | > |   At the moment, I have spun up two AMI instances, one
> | >> | > |   called
> | >> | > |   production and one called staging. I am doing my hacking
> | >> | > |   on the
> | >> | > |   staging instance.
> | >> | > | Nothing is live, yet, but I should get used to not
> | >> | > | destroying the
> | >> | > | production system. ;-) Your point is well taken, I will
> | >> | > | start
> | >> | > | making
> | >> | > | backups.
> | >> | > |
> | >> | > | > If SystemHashing is the only problem area (and you don't
> | >> | > | > have a
> | >> | > | > backup:), then you can unload the SystemHashing package
> | >> | > | > using
> | >> | > | > the
> | >> | > | > Monticello browser[3], then load the GemStone version
> | >> | > | > using the
> | >> | > | > expression above ...
> | >> | > | >
> | >> | > | > Let me know if you have other issues,
> | >> | > | >
> | >> | > | > Dale
> | >> | > | >
> | >> | > | >
> | >> | > | > [1]
> | >> | > | > http://code.google.com/p/glassdb/wiki/GemToolsAdmin#Backup
> | >> | > | > [2]
> | >> | > | > http://code.google.com/p/glassdb/wiki/GemToolsAdmin#Restore_w/o_tranlogs
> | >> | > | > [3]
> | >> | > | > http://code.google.com/p/glassdb/wiki/GemToolsTools#Monticello
> | >> | > | > ----- Original Message -----
> | >> | > | > | From: "Lawrence Kellogg" <[hidden email]>
> | >> | > | > | To: "GemStone Seaside beta discussion"
> | >> | > | > | <[hidden email]>
> | >> | > | > | Sent: Friday, January 13, 2012 1:03:34 PM
> | >> | > | > | Subject: Re: [GS/SS Beta] Configuring Seaside for
> | >> | > | > | deployment
> | >> | > | > |
> | >> | > | > |
> | >> | > | > | On Jan 13, 2012, at 1:38 PM, Dale Henrichs wrote:
> | >> | > | > |
> | >> | > | > | > Lawrence,
> | >> | > | > | >
> | >> | > | > | > First off, there is an implementation of
> | >> | > | > | > SecureHashAlgorithm
> | >> | > | > | > already ported to GemStone. To load the correct
> | >> | > | > | > version you
> | >> | > | > | > can
> | >> | > | > | > try this expression:
> | >> | > | > | >
> | >> | > | > | >  ConfigurationOfGsMisc currentVersion load:
> | >> | > | > | >  'System-Digital-Signatures'.
> | >> | > | > | >
> | >> | > | > |
> | >> | > | > |   Thanks Dale, unfortunately, my ConfigurationOfGsMisc
> | >> | > | > |   class
> | >> | > | > |   does
> | >> | > | > |   not
> | >> | > | > |   have a current method, so it fails.
> | >> | > | > | I am on GemStone64Bit2.4.4.1-x86_64.Linux.
> | >> | > | > |
> | >> | > | > |   Did you mean:
> | >> | > | > |
> | >> | > | > |   ConfigurationOfGsMisc project load:
> | >> | > | > |   'System-Digital-Signatures'
> | >> | > | > |   ??
> | >> | > | > |
> | >> | > | > |   but that doesn't work because it expects a version
> | >> | > | > |   string.
> | >> | > | > |
> | >> | > | > |   I know that I totally messed up my configuration when
> | >> | > | > |   I
> | >> | > | > |   loaded
> | >> | > | > |   the
> | >> | > | > |   System-Hashing stuff from Squeak.
> | >> | > | > |
> | >> | > | > |   How do I restore my Gemstone configuration?
> | >> | > | > |
> | >> | > | > |   Larry
> | >> | > | > |
> | >> | > | > |
> | >> | > | > |
> | >> | > | > | > Using the version that is already ported to GemStone
> | >> | > | > | > will
> | >> | > | > | > definitely address the issue you had with the
> | >> | > | > | > #processBuffer
> | >> | > | > | > method (MNU for #primHasSecureHashPrimitive).
> | >> | > | > | >
> | >> | > | > | >> From looking at the code, I would have to guess that
> | >> | > | > | >> you
> | >> | > | > | >> must
> | >> | > | > | >> be
> | >> | > | > | >> passing in a FileStream in the #hashStream: method.
> | >> | > | > | >> FileStream>>next: returns a nil explicitly and that
> | >> | > | > | >> looks
> | >> | > | > | >> like
> | >> | > | > | >> a
> | >> | > | > | >> bug to me ... The fix would be for FileStream to
> | >> | > | > | >> return
> | >> | > | > | >> result,
> | >> | > | > | >> which should be empty on an error...
> | >> | > | > | >
> | >> | > | > | > If you're not using a FileStream there, then I would
> | >> | > | > | > be
> | >> | > | > | > interested
> | >> | > | > | > in a stack to understand what is wrong ...
> | >> | > | > | >
> | >> | > | > | > Dale
> | >> | > | > | > ----- Original Message -----
> | >> | > | > | > | From: "Lawrence Kellogg" <[hidden email]>
> | >> | > | > | > | To: "GemStone Seaside beta discussion"
> | >> | > | > | > | <[hidden email]>
> | >> | > | > | > | Sent: Thursday, January 12, 2012 8:41:44 PM
> | >> | > | > | > | Subject: [GS/SS Beta] Configuring Seaside for
> | >> | > | > | > | deployment
> | >> | > | > | > |
> | >> | > | > | > | Hello,
> | >> | > | > | > | So, I have started going through the chapter on what
> | >> | > | > | > | it
> | >> | > | > | > | takes
> | >> | > | > | > | to
> | >> | > | > | > | deploy an application with Seaside.
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > | I can bring up the Configuration option by clicking
> | >> | > | > | > | Configure
> | >> | > | > | > | at
> | >> | > | > | > | the
> | >> | > | > | > | bottom of the browser but if I try to
> | >> | > | > | > | password prptect the configure app, I get a crash in
> | >> | > | > | > | the
> | >> | > | > | > | SecureHashAlgorithm class, with the message
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > | "Byte objects store values from 0 to 255, not nil"
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > | (Same issue if I try to execute:
> | >> | > | > | > | "WAConfigurationTool
> | >> | > | > | > | initialize"
> | >> | > | > | > | initialize
> | >> | > | > | > | (WAAdmin register: self asApplicationAt: 'config'
> | >> | > | > | > | user:
> | >> | > | > | > | 'admin'
> | >> | > | > | > | password: 'seaside') addLibrary: WAToolFiles)
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > | The trouble is:
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > | buf := aPositionableStream next: 64 which returns
> | >> | > | > | > | nil
> | >> | > | > | > | when it
> | >> | > | > | > | tries
> | >> | > | > | > | to go through the next 64 elements,
> | >> | > | > | > | there aren't 64 elements...
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > | from here:
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > | hashStream: aPositionableStream
> | >> | > | > | > | "Hash the contents of the given stream from the
> | >> | > | > | > | current
> | >> | > | > | > | position
> | >> | > | > | > | to
> | >> | > | > | > | the end using the Secure Hash Algorithm. The SHA
> | >> | > | > | > | algorithm is
> | >> | > | > | > | defined in FIPS PUB 180-1. It is also described on
> | >> | > | > | > | p. 442
> | >> | > | > | > | of
> | >> | > | > | > | 'Applied Cryptography: Protocols, Algorithms, and
> | >> | > | > | > | Source
> | >> | > | > | > | Code
> | >> | > | > | > | in
> | >> | > | > | > | C'
> | >> | > | > | > | by Bruce Scheier, Wiley, 1996."
> | >> | > | > | > | "SecureHashAlgorithm new hashStream: (ReadStream on:
> | >> | > | > | > | 'foo')"
> | >> | > | > | > | "(SecureHashAlgorithm new hashMessage: '') radix: 16
> | >> | > | > | > | => 'DA39A3EE5E6B4B0D3255BFEF95601890AFD80709'"
> | >> | > | > | > |
> | >> | > | > | > | | startPosition buf bitLength |
> | >> | > | > | > | self initializeTotals.
> | >> | > | > | > |
> | >> | > | > | > | aPositionableStream atEnd ifTrue: [self
> | >> | > | > | > | processFinalBuffer:
> | >> | > | > | > | #()
> | >> | > | > | > | bitLength: 0].
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > | startPosition := aPositionableStream position.
> | >> | > | > | > | [aPositionableStream atEnd] whileFalse:
> | >> | > | > | > | [ buf := aPositionableStream next: 64.
> | >> | > | > | > | <<<<<<<<<<<<<<<<<<<<<<-----
> | >> | > | > | > | (aPositionableStream atEnd not and: [buf size = 64])
> | >> | > | > | > | ifTrue: [self processBuffer: buf]
> | >> | > | > | > | ifFalse: [ bitLength := (aPositionableStream
> | >> | > | > | > | position -
> | >> | > | > | > | startPosition) * 8.
> | >> | > | > | > | self processFinalBuffer: buf bitLength: bitLength]].
> | >> | > | > | > | ^ self finalHash
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > | and also in SecureHashAlgorithm, which does not
> | >> | > | > | > | understand
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > | self primHasSecureHashPrimitive
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > | from
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > | processBuffer: aByteArray
> | >> | > | > | > | "Process given 64-byte buffer, accumulating the
> | >> | > | > | > | results
> | >> | > | > | > | in
> | >> | > | > | > | totalA
> | >> | > | > | > | through totalE."
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > | | a b c d e w tmp |
> | >> | > | > | > | self <<<<<<<<<<<<<<<<<<<<<<<<<<<<
> | >> | > | > | > | ifTrue: [^ self processBufferUsingPrimitives:
> | >> | > | > | > | aByteArray]
> | >> | > | > | > | ifFalse: [totals := nil].
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > | "initialize registers a through e from the current
> | >> | > | > | > | totals"
> | >> | > | > | > | a := totalA copy.
> | >> | > | > | > | b := totalB copy.
> | >> | > | > | > | c := totalC copy.
> | >> | > | > | > | d := totalD copy.
> | >> | > | > | > | e := totalE copy.
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > | "expand and process the buffer"
> | >> | > | > | > | w := self expandedBlock: aByteArray.
> | >> | > | > | > | 1 to: 80 do: [:i |
> | >> | > | > | > | tmp := (a copy leftRotateBy: 5)
> | >> | > | > | > | += (self hashFunction: i of: b with: c with: d);
> | >> | > | > | > | += e;
> | >> | > | > | > | += (w at: i);
> | >> | > | > | > | += (self constantForStep: i).
> | >> | > | > | > | e := d.
> | >> | > | > | > | d := c.
> | >> | > | > | > | c := b copy leftRotateBy: 30.
> | >> | > | > | > | b := a.
> | >> | > | > | > | a := tmp].
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > | "add a through e into total accumulators"
> | >> | > | > | > | totalA += a.
> | >> | > | > | > | totalB += b.
> | >> | > | > | > | totalC += c.
> | >> | > | > | > | totalD += d.
> | >> | > | > | > | totalE += e.
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > | I'm wondering if I somehow messed up my
> | >> | > | > | > | SecureHashAlgorithm
> | >> | > | > | > | class
> | >> | > | > | > | with the other troubles I had
> | >> | > | > | > | with Cloudfork or am I just destined to run into all
> | >> | > | > | > | kinds of
> | >> | > | > | > | security problems. ;-)
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > | Any thoughts?
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > | > | Larry
> | >> | > | > | > |
> | >> | > | > | > |
> | >> | > | > |
> | >> | > | > |
> | >> | > |
> | >> | > |
> | >> |
> | >> |
> | >
> |
> |

Reply | Threaded
Open this post in threaded view
|

Re: Configuring Seaside for deployment

Larry Kellogg

On Jan 13, 2012, at 8:42 PM, Lawrence Kellogg wrote:


On Jan 13, 2012, at 8:13 PM, Dale Henrichs wrote:

Lawrence,

I'll have to dig into Seaside a bit on over the weekend (holiday on Monday) to check into this...which adaptor are you using (FastCGI, Swazoo, or Zinc)?


 I run the FastCGI servers on port 9001 and I'm reaching Seaside through Swazoo running on port 8080.
I'll keep poking around.


Somehow,  this WAStrictTransportSecurityFilter was applied to my WATask. I removed it, through the Development configuration options, and I'm now 
able to reach my login task!! 

  Great news. Thanks, Dale.

  Larry





 Thanks for the help!

 Larry


Dale

----- Original Message -----
| From: "Lawrence Kellogg" <[hidden email]>
| To: "GemStone Seaside beta discussion" <[hidden email]>
| Sent: Friday, January 13, 2012 4:16:07 PM
| Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
|
|
| On Jan 13, 2012, at 6:37 PM, Lawrence Kellogg wrote:
|
| >
| > On Jan 13, 2012, at 6:05 PM, Dale Henrichs wrote:
| >
| >> Lawrence,
| >>
| >> I think there must be a configuration setting that has been
| >> changed ... not sure which one though?
| >>
| >
| >  I suppose so, but it is a mystery to me, at the moment. The sad
| >  thing is that I don't need Cloudfork under GLASS, after all.
| > Yesterday, I coded around the requirement for Cloudfork.
| >
| >  So, I unloaded all of the Cloudfork packages, updated GLASS,
| >  loaded all kinds of changes from Monticello, but I still
| > cannot reach my server with http. I have no idea what config option
| > I managed to change. I'll keep looking at it.
| >
| >  Thanks for the help.
| >
|
|   Well, here is an interesting fact. I can navigate to the default
|   Seaside page, and run the configuration, without any problems.
| If I try to bring up my login task, a WATask, the request gets
| changed to https and I cannot reach the server.
|
|   Does this fact help in any way? I re-ran the initialize code on my
|   WATask but it did not make any difference.
|
|   Larry
|
|
|
|
| >  Larry
| >
| >
| >
| >> Dale
| >>
| >> ----- Original Message -----
| >> | From: "Lawrence Kellogg" <[hidden email]>
| >> | To: "GemStone Seaside beta discussion"
| >> | <[hidden email]>
| >> | Sent: Friday, January 13, 2012 2:55:13 PM
| >> | Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
| >> |
| >> |
| >> | On Jan 13, 2012, at 5:49 PM, Dale Henrichs wrote:
| >> |
| >> | > Interesting ... Did you unload the old pacakge first? Do you
| >> | > happen
| >> | > to know if your current system (the one serving HTTP requests)
| >> | > was
| >> | > trying to use the class SecureHashAlgorithm? When you say "the
| >> | > SecureHashAlgorithm class does not exist in the image" do you
| >> | > mean
| >> | > you don't see it in the SystemBrowser or that you get an error
| >> | > message somewhere that is trying to use the class? What are
| >> | > you
| >> | > using to server http pages?
| >> | >
| >> |
| >> |   Yes, I unloaded the old package first. I don't believe my old
| >> |   system was using the SecureHashAlgorithm because that class
| >> |   fails
| >> |   when I try to
| >> | set a password on the Seaside config, which was what I was doing
| >> | when
| >> | I started figuring out a deployment configuration..
| >> |
| >> |   I sent another note to the list. I have the
| >> |   SecureHashAlgorithm
| >> |   now, after loading it from Monticello, manually. I thought
| >> |   your
| >> |   command would load it
| >> | automatically. Sorry about that.
| >> |
| >> |   I am running Seaside to serve my http pages. I'm not sure why
| >> |   this
| >> |   new instance insists on https for everything.
| >> |
| >> |   Larry
| >> |
| >> |
| >> | > Dale
| >> | >
| >> | > ----- Original Message -----
| >> | > | From: "Lawrence Kellogg" <[hidden email]>
| >> | > | To: "GemStone Seaside beta discussion"
| >> | > | <[hidden email]>
| >> | > | Sent: Friday, January 13, 2012 2:23:39 PM
| >> | > | Subject: Re: [GS/SS Beta] Configuring Seaside for deployment
| >> | > |
| >> | > |
| >> | > | On Jan 13, 2012, at 4:49 PM, Dale Henrichs wrote:
| >> | > |
| >> | > | > Lawrence,
| >> | > | >
| >> | > | > That should have been:
| >> | > | >
| >> | > | >  ConfigurationOfGsMisc project currentVersion load:
| >> | > | >  'System-Digital-Signatures'.
| >> | > | >
| >> | > |
| >> | > |   Well, this seems to work and returns this:
| >> | > |
| >> | > | Loading 0.239.1 of ConfigurationOfGsMisc...
| >> | > | ...finished 0.239.1
| >> | > |
| >> | > | but the SecureHashAlgorithm class does not exist in the
| >> | > | image, I
| >> | > | don't get System-Digital-Signatures but I do have
| >> | > | System-Digital-Signatures-Tests. Puzzling.
| >> | > | Also, I can no longer reach my running server with a http,
| >> | > | it
| >> | > | insists
| >> | > | on trying to use https, where it fails.
| >> | > |
| >> | > |
| >> | > |
| >> | > | > I recommend that you perform a backup[1] before doing a
| >> | > | > load of
| >> | > | > software, because then it is very easy to restore[2] to a
| >> | > | > known
| >> | > | > point ... I typically keep a number of backups around for
| >> | > | > this
| >> | > | > purpose.
| >> | > | >
| >> | > |
| >> | > |   At the moment, I have spun up two AMI instances, one
| >> | > |   called
| >> | > |   production and one called staging. I am doing my hacking
| >> | > |   on the
| >> | > |   staging instance.
| >> | > | Nothing is live, yet, but I should get used to not
| >> | > | destroying the
| >> | > | production system. ;-) Your point is well taken, I will
| >> | > | start
| >> | > | making
| >> | > | backups.
| >> | > |
| >> | > | > If SystemHashing is the only problem area (and you don't
| >> | > | > have a
| >> | > | > backup:), then you can unload the SystemHashing package
| >> | > | > using
| >> | > | > the
| >> | > | > Monticello browser[3], then load the GemStone version
| >> | > | > using the
| >> | > | > expression above ...
| >> | > | >
| >> | > | > Let me know if you have other issues,
| >> | > | >
| >> | > | > Dale
| >> | > | >
| >> | > | >
| >> | > | > [1]
| >> | > | > http://code.google.com/p/glassdb/wiki/GemToolsAdmin#Backup
| >> | > | > [2]
| >> | > | > http://code.google.com/p/glassdb/wiki/GemToolsAdmin#Restore_w/o_tranlogs
| >> | > | > [3]
| >> | > | > http://code.google.com/p/glassdb/wiki/GemToolsTools#Monticello
| >> | > | > ----- Original Message -----
| >> | > | > | From: "Lawrence Kellogg" <[hidden email]>
| >> | > | > | To: "GemStone Seaside beta discussion"
| >> | > | > | <[hidden email]>
| >> | > | > | Sent: Friday, January 13, 2012 1:03:34 PM
| >> | > | > | Subject: Re: [GS/SS Beta] Configuring Seaside for
| >> | > | > | deployment
| >> | > | > |
| >> | > | > |
| >> | > | > | On Jan 13, 2012, at 1:38 PM, Dale Henrichs wrote:
| >> | > | > |
| >> | > | > | > Lawrence,
| >> | > | > | >
| >> | > | > | > First off, there is an implementation of
| >> | > | > | > SecureHashAlgorithm
| >> | > | > | > already ported to GemStone. To load the correct
| >> | > | > | > version you
| >> | > | > | > can
| >> | > | > | > try this expression:
| >> | > | > | >
| >> | > | > | >  ConfigurationOfGsMisc currentVersion load:
| >> | > | > | >  'System-Digital-Signatures'.
| >> | > | > | >
| >> | > | > |
| >> | > | > |   Thanks Dale, unfortunately, my ConfigurationOfGsMisc
| >> | > | > |   class
| >> | > | > |   does
| >> | > | > |   not
| >> | > | > |   have a current method, so it fails.
| >> | > | > | I am on GemStone64Bit2.4.4.1-x86_64.Linux.
| >> | > | > |
| >> | > | > |   Did you mean:
| >> | > | > |
| >> | > | > |   ConfigurationOfGsMisc project load:
| >> | > | > |   'System-Digital-Signatures'
| >> | > | > |   ??
| >> | > | > |
| >> | > | > |   but that doesn't work because it expects a version
| >> | > | > |   string.
| >> | > | > |
| >> | > | > |   I know that I totally messed up my configuration when
| >> | > | > |   I
| >> | > | > |   loaded
| >> | > | > |   the
| >> | > | > |   System-Hashing stuff from Squeak.
| >> | > | > |
| >> | > | > |   How do I restore my Gemstone configuration?
| >> | > | > |
| >> | > | > |   Larry
| >> | > | > |
| >> | > | > |
| >> | > | > |
| >> | > | > | > Using the version that is already ported to GemStone
| >> | > | > | > will
| >> | > | > | > definitely address the issue you had with the
| >> | > | > | > #processBuffer
| >> | > | > | > method (MNU for #primHasSecureHashPrimitive).
| >> | > | > | >
| >> | > | > | >> From looking at the code, I would have to guess that
| >> | > | > | >> you
| >> | > | > | >> must
| >> | > | > | >> be
| >> | > | > | >> passing in a FileStream in the #hashStream: method.
| >> | > | > | >> FileStream>>next: returns a nil explicitly and that
| >> | > | > | >> looks
| >> | > | > | >> like
| >> | > | > | >> a
| >> | > | > | >> bug to me ... The fix would be for FileStream to
| >> | > | > | >> return
| >> | > | > | >> result,
| >> | > | > | >> which should be empty on an error...
| >> | > | > | >
| >> | > | > | > If you're not using a FileStream there, then I would
| >> | > | > | > be
| >> | > | > | > interested
| >> | > | > | > in a stack to understand what is wrong ...
| >> | > | > | >
| >> | > | > | > Dale
| >> | > | > | > ----- Original Message -----
| >> | > | > | > | From: "Lawrence Kellogg" <[hidden email]>
| >> | > | > | > | To: "GemStone Seaside beta discussion"
| >> | > | > | > | <[hidden email]>
| >> | > | > | > | Sent: Thursday, January 12, 2012 8:41:44 PM
| >> | > | > | > | Subject: [GS/SS Beta] Configuring Seaside for
| >> | > | > | > | deployment
| >> | > | > | > |
| >> | > | > | > | Hello,
| >> | > | > | > | So, I have started going through the chapter on what
| >> | > | > | > | it
| >> | > | > | > | takes
| >> | > | > | > | to
| >> | > | > | > | deploy an application with Seaside.
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | I can bring up the Configuration option by clicking
| >> | > | > | > | Configure
| >> | > | > | > | at
| >> | > | > | > | the
| >> | > | > | > | bottom of the browser but if I try to
| >> | > | > | > | password prptect the configure app, I get a crash in
| >> | > | > | > | the
| >> | > | > | > | SecureHashAlgorithm class, with the message
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | "Byte objects store values from 0 to 255, not nil"
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | (Same issue if I try to execute:
| >> | > | > | > | "WAConfigurationTool
| >> | > | > | > | initialize"
| >> | > | > | > | initialize
| >> | > | > | > | (WAAdmin register: self asApplicationAt: 'config'
| >> | > | > | > | user:
| >> | > | > | > | 'admin'
| >> | > | > | > | password: 'seaside') addLibrary: WAToolFiles)
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | The trouble is:
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | buf := aPositionableStream next: 64 which returns
| >> | > | > | > | nil
| >> | > | > | > | when it
| >> | > | > | > | tries
| >> | > | > | > | to go through the next 64 elements,
| >> | > | > | > | there aren't 64 elements...
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | from here:
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | hashStream: aPositionableStream
| >> | > | > | > | "Hash the contents of the given stream from the
| >> | > | > | > | current
| >> | > | > | > | position
| >> | > | > | > | to
| >> | > | > | > | the end using the Secure Hash Algorithm. The SHA
| >> | > | > | > | algorithm is
| >> | > | > | > | defined in FIPS PUB 180-1. It is also described on
| >> | > | > | > | p. 442
| >> | > | > | > | of
| >> | > | > | > | 'Applied Cryptography: Protocols, Algorithms, and
| >> | > | > | > | Source
| >> | > | > | > | Code
| >> | > | > | > | in
| >> | > | > | > | C'
| >> | > | > | > | by Bruce Scheier, Wiley, 1996."
| >> | > | > | > | "SecureHashAlgorithm new hashStream: (ReadStream on:
| >> | > | > | > | 'foo')"
| >> | > | > | > | "(SecureHashAlgorithm new hashMessage: '') radix: 16
| >> | > | > | > | => 'DA39A3EE5E6B4B0D3255BFEF95601890AFD80709'"
| >> | > | > | > |
| >> | > | > | > | | startPosition buf bitLength |
| >> | > | > | > | self initializeTotals.
| >> | > | > | > |
| >> | > | > | > | aPositionableStream atEnd ifTrue: [self
| >> | > | > | > | processFinalBuffer:
| >> | > | > | > | #()
| >> | > | > | > | bitLength: 0].
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | startPosition := aPositionableStream position.
| >> | > | > | > | [aPositionableStream atEnd] whileFalse:
| >> | > | > | > | [ buf := aPositionableStream next: 64.
| >> | > | > | > | <<<<<<<<<<<<<<<<<<<<<<-----
| >> | > | > | > | (aPositionableStream atEnd not and: [buf size = 64])
| >> | > | > | > | ifTrue: [self processBuffer: buf]
| >> | > | > | > | ifFalse: [ bitLength := (aPositionableStream
| >> | > | > | > | position -
| >> | > | > | > | startPosition) * 8.
| >> | > | > | > | self processFinalBuffer: buf bitLength: bitLength]].
| >> | > | > | > | ^ self finalHash
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | and also in SecureHashAlgorithm, which does not
| >> | > | > | > | understand
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | self primHasSecureHashPrimitive
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | from
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | processBuffer: aByteArray
| >> | > | > | > | "Process given 64-byte buffer, accumulating the
| >> | > | > | > | results
| >> | > | > | > | in
| >> | > | > | > | totalA
| >> | > | > | > | through totalE."
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | | a b c d e w tmp |
| >> | > | > | > | self <<<<<<<<<<<<<<<<<<<<<<<<<<<<
| >> | > | > | > | ifTrue: [^ self processBufferUsingPrimitives:
| >> | > | > | > | aByteArray]
| >> | > | > | > | ifFalse: [totals := nil].
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | "initialize registers a through e from the current
| >> | > | > | > | totals"
| >> | > | > | > | a := totalA copy.
| >> | > | > | > | b := totalB copy.
| >> | > | > | > | c := totalC copy.
| >> | > | > | > | d := totalD copy.
| >> | > | > | > | e := totalE copy.
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | "expand and process the buffer"
| >> | > | > | > | w := self expandedBlock: aByteArray.
| >> | > | > | > | 1 to: 80 do: [:i |
| >> | > | > | > | tmp := (a copy leftRotateBy: 5)
| >> | > | > | > | += (self hashFunction: i of: b with: c with: d);
| >> | > | > | > | += e;
| >> | > | > | > | += (w at: i);
| >> | > | > | > | += (self constantForStep: i).
| >> | > | > | > | e := d.
| >> | > | > | > | d := c.
| >> | > | > | > | c := b copy leftRotateBy: 30.
| >> | > | > | > | b := a.
| >> | > | > | > | a := tmp].
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | "add a through e into total accumulators"
| >> | > | > | > | totalA += a.
| >> | > | > | > | totalB += b.
| >> | > | > | > | totalC += c.
| >> | > | > | > | totalD += d.
| >> | > | > | > | totalE += e.
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | I'm wondering if I somehow messed up my
| >> | > | > | > | SecureHashAlgorithm
| >> | > | > | > | class
| >> | > | > | > | with the other troubles I had
| >> | > | > | > | with Cloudfork or am I just destined to run into all
| >> | > | > | > | kinds of
| >> | > | > | > | security problems. ;-)
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | Any thoughts?
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > | > | Larry
| >> | > | > | > |
| >> | > | > | > |
| >> | > | > |
| >> | > | > |
| >> | > |
| >> | > |
| >> |
| >> |
| >
|
|


Reply | Threaded
Open this post in threaded view
|

Fatal Internal Notification from Gem

Larry Kellogg
Hello,
  So, my GLASS server has been running for days on Amazon's service. I logged in many
times a day, and worked with it, no problems.

  I gave the server information to someone else to try, and the server crashed with the
following error: (from the seaside.log)

--- 01/13/2012 03:39:21 AM.771 UTC :    Session 2 with processId 1384 is now the Symbol Creation Gem.
    Session 3 with processId 1383 is now the Admin Gem.

    Session 4 with processId 1382 is now the Page Reclaim Gem for
    extents 0 through 0.

--- 01/15/2012 06:16:58 PM UTC ---
    Fatal Internal Error Notification from Gem, user = DataCurator  Session = 6
      Gem hostName = localhost , Gem processId = 1590,
      current  CommitRecord = 2376
                                                                           
=======================================

Any idea on how I can debug something like this? I have no idea what happened.
There are no walkbacks in the Debug option on the Gemtools launcher. All I know is
that the user was clicking around with FIrefox and it crashed.

Furthermore, is there an easy way for me to restart my Gems once they go down?
I start them with this:

WAGemStoneRunSeasideGems default
        name: 'Swazoo';
        adaptorClass: WAGsSwazooAdaptor;
        ports: #(8080).
WAGemStoneRunSeasideGems restartGems.

After the crash, I restarted the Gems and the server process was fine.

  Regards,

  Larry
Reply | Threaded
Open this post in threaded view
|

Running SeasideGems, confusion

Larry Kellogg
Hello,
  So, I'm a little confused about running Seaside Gems from the command line
versus from within an image.

I have installed Apache and I am bringing up a page that embeds my Seaside
server in an iFrame.

  Now, if I just run Seaside Gems from the command line with this command:

runSeasideGems30 start  WAFastCGIAdaptor 9001

I cannot forward to my Seaside app on port 9001 from within my index.html but if I bring up
a Smalltalk image and run this command in a workspace:


WAGemStoneRunSeasideGems default
        name: 'Swazoo';
        adaptorClass: WAGsSwazooAdaptor;
        ports: #(8080).
WAGemStoneRunSeasideGems restartGems.

then I can forward to port 8080 for my application, from within index.html.

I'm just a little confused about what is going on here.
Is the FastCGI server being used at all? Should I just start
Swazoo from inside the image and not start the FastCGI stuff?

  Why can't I get any response from the FastCGI code running on
port 9001?

  I'm not clear on what is going on.

  Thanks,

  Larry
Reply | Threaded
Open this post in threaded view
|

Re: Fatal Internal Notification from Gem

James Foster-8
In reply to this post by Larry Kellogg
Larry,

GemStone has a lot of moving parts and it can be confusing to tell which piece is involved. In your case the stone log reports that a gem (with PID 1590) crashed. When the gem was started, was there a script that redirected output to a file? If so, do you have that file available?

A typical explanation for this sort of problem is running out of temporary object cache in a gem. Doing so will cause the gem to crash and not be able to report anything to the object log (as it would do for a non-fatal error). Depending on what the user clicked on, your code may have taken a different path, or tried to load different objects.

Auto-restarting a gem is typically done with a shell script (e.g., bash). You can have a loop that checks for the existence of a file and if it is present (or absent, depending on your preference), then start the gem. When the gem crashes, control will return to the script and the loop will continue. If you want to stop the loop you can manually remove (or create) the flag file (or just manually kill the process running the shell script).

-James

On Jan 15, 2012, at 11:40 AM, Lawrence Kellogg wrote:

> Hello,
>  So, my GLASS server has been running for days on Amazon's service. I logged in many
> times a day, and worked with it, no problems.
>
>  I gave the server information to someone else to try, and the server crashed with the
> following error: (from the seaside.log)
>
> --- 01/13/2012 03:39:21 AM.771 UTC :    Session 2 with processId 1384 is now the Symbol Creation Gem.
>    Session 3 with processId 1383 is now the Admin Gem.
>
>    Session 4 with processId 1382 is now the Page Reclaim Gem for
>    extents 0 through 0.
>
> --- 01/15/2012 06:16:58 PM UTC ---
>    Fatal Internal Error Notification from Gem, user = DataCurator  Session = 6
>      Gem hostName = localhost , Gem processId = 1590,
>      current  CommitRecord = 2376
>
> =======================================
>
> Any idea on how I can debug something like this? I have no idea what happened.
> There are no walkbacks in the Debug option on the Gemtools launcher. All I know is
> that the user was clicking around with FIrefox and it crashed.
>
> Furthermore, is there an easy way for me to restart my Gems once they go down?
> I start them with this:
>
> WAGemStoneRunSeasideGems default
> name: 'Swazoo';
> adaptorClass: WAGsSwazooAdaptor;
> ports: #(8080).
> WAGemStoneRunSeasideGems restartGems.
>
> After the crash, I restarted the Gems and the server process was fine.
>
>  Regards,
>
>  Larry

Reply | Threaded
Open this post in threaded view
|

Re: Fatal Internal Notification from Gem

Johan Brichau-2
In reply to this post by Larry Kellogg
Hi Lawrence,

The stone log (from which you sent the contents) does not contain the actual error.
There should also be a 'Swazoo' gem log file. I guess that will contain the actual error. Can you send that one?

Johan

On 15 Jan 2012, at 20:40, Lawrence Kellogg wrote:

> Hello,
>  So, my GLASS server has been running for days on Amazon's service. I logged in many
> times a day, and worked with it, no problems.
>
>  I gave the server information to someone else to try, and the server crashed with the
> following error: (from the seaside.log)
>
> --- 01/13/2012 03:39:21 AM.771 UTC :    Session 2 with processId 1384 is now the Symbol Creation Gem.
>    Session 3 with processId 1383 is now the Admin Gem.
>
>    Session 4 with processId 1382 is now the Page Reclaim Gem for
>    extents 0 through 0.
>
> --- 01/15/2012 06:16:58 PM UTC ---
>    Fatal Internal Error Notification from Gem, user = DataCurator  Session = 6
>      Gem hostName = localhost , Gem processId = 1590,
>      current  CommitRecord = 2376
>
> =======================================
>
> Any idea on how I can debug something like this? I have no idea what happened.
> There are no walkbacks in the Debug option on the Gemtools launcher. All I know is
> that the user was clicking around with FIrefox and it crashed.
>
> Furthermore, is there an easy way for me to restart my Gems once they go down?
> I start them with this:
>
> WAGemStoneRunSeasideGems default
> name: 'Swazoo';
> adaptorClass: WAGsSwazooAdaptor;
> ports: #(8080).
> WAGemStoneRunSeasideGems restartGems.
>
> After the crash, I restarted the Gems and the server process was fine.
>
>  Regards,
>
>  Larry

Reply | Threaded
Open this post in threaded view
|

Re: Running SeasideGems, confusion

Johan Brichau-2
In reply to this post by Larry Kellogg
Larry,

Are you trying to connect to port 9001 from your webbrowser?

If yes: Swazoo and FastCGI adaptors are different kinds of servers.

A Swazoo adaptor brings up an http server, which you can directly connect to from your webbrowser.
A FastCGI adaptor brings up a FastCGI server, which can only be connected to via a front-end http server (such as apache, nginx, lighttpd,...)

While Swazoo works OK, using a FastCGI behind a frond-end webserver is a lot faster (in my experience).

A good post on using Seaside with FastCGI can be found here:
http://www.monkeysnatchbanana.com/posts/2010/08/17/using-fastcgi-with-nginx-and-seaside.html

cheers,
Johan

On 16 Jan 2012, at 20:15, Lawrence Kellogg wrote:

> Hello,
>  So, I'm a little confused about running Seaside Gems from the command line
> versus from within an image.
>
> I have installed Apache and I am bringing up a page that embeds my Seaside
> server in an iFrame.
>
>  Now, if I just run Seaside Gems from the command line with this command:
>
> runSeasideGems30 start  WAFastCGIAdaptor 9001
>
> I cannot forward to my Seaside app on port 9001 from within my index.html but if I bring up
> a Smalltalk image and run this command in a workspace:
>
>
> WAGemStoneRunSeasideGems default
> name: 'Swazoo';
> adaptorClass: WAGsSwazooAdaptor;
> ports: #(8080).
> WAGemStoneRunSeasideGems restartGems.
>
> then I can forward to port 8080 for my application, from within index.html.
>
> I'm just a little confused about what is going on here.
> Is the FastCGI server being used at all? Should I just start
> Swazoo from inside the image and not start the FastCGI stuff?
>
>  Why can't I get any response from the FastCGI code running on
> port 9001?
>
>  I'm not clear on what is going on.
>
>  Thanks,
>
>  Larry

Reply | Threaded
Open this post in threaded view
|

Re: Fatal Internal Notification from Gem

Larry Kellogg
In reply to this post by James Foster-8
James,
  Well, I think I traced the crash to the fact that I has mistakenly reintroduced some code that was trying to call out to Cloudfork.
I removed that code and everything seems to be running better now, but it is a little too early to tell, for sure.

  Looking through the log files, and in particular, a Swazoo server log file, I guess this
walkback brought down the Gem. Is this of any help?

  Thanks for the tips with regards to writing a little shell script to restart my Ges.
I'll do that. With all the moving parts, I'm amazed that I have gotten as much up
and running as I have. ;-)

  Regards,

  Larry

 
 

The object with object ID 81065893475386368 does not exist.
Error Category: 231169 [GemStone] Number: 2101 Arg Count: 1 Context : 361105409
Arg 1: [648527147803090946 sz:0 cls: 74241 SmallInteger] 81065893475386368

Now executing the following command saved from "iferr 1":
   where
==> 1 GsProcess class >> installPartialContinuation:atLevel:value: @2 line 1   [GsMethod 4487425]
2 WAPartialContinuation >> value: @13 line 11   [GsMethod 212791041]
3 WAPartialContinuation >> valueWithPossibleArguments: @2 line 2   [GsMethod 218326273]
4 ComplexBlock in WAComponent >> show:onAnswer:delegation: @7 line 7   [GsMethod 194749185]
5 ComplexBlock in ExecutableBlock >> valueWithPossibleArguments: @12 line 8   [GsMethod 116163585]
6 WAAnswerHandler >> handleAnswer:continueWith: @3 line 2   [GsMethod 194735873]
7 WADecoration >> handleAnswer: @6 line 3   [GsMethod 194731009]
8 WAComponent >> answer: @2 line 5   [GsMethod 194751745]
9 MyComponent >> sendAnswerToCurrentComponent @2 line 2   [GsMethod 278171137]
10 ComplexBlock in MyComponent >> renderNavigationMenuOn: @53 line 47   [GsMethod 259119617]
11 ComplexBlock in ExecutableBlock >> valueWithPossibleArguments: @6 line 4   [GsMethod 116163585]
12 WAActionCallback >> evaluateWithArgument: @3 line 2   [GsMethod 176951297]
13 WACallback >> evaluateWithFieldValues: @5 line 2   [GsMethod 177495553]
14 ComplexBlock in WACallbackRegistry >> handle: @16 line 10   [GsMethod 177951489]
15 Collection >> do: @5 line 10   [GsMethod 1547777]
16 WACallbackRegistry >> handle: @17 line 9   [GsMethod 177951489]
17 ComplexBlock in WAActionPhaseContinuation >> runCallbacks @7 line 4   [GsMethod 202613505]
18 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
19 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
20 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
21 WARenderLoopContinuation >> withNotificationHandlerDo: @3 line 2   [GsMethod 202608385]
22 ComplexVCBlock in WAActionPhaseContinuation >> runCallbacks @8 line 3   [GsMethod 202613505]
23 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
24 ComplexVCBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
25 WAActionPhaseContinuation >> runCallbacks @18 line 6   [GsMethod 202613505]
26 WAActionPhaseContinuation >> handleRequest @1 line 2   [GsMethod 202614017]
27 ComplexBlock in WASessionContinuation >> basicValue @3 line 2   [GsMethod 202625537]
28 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
29 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
30 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
31 WASessionContinuation >> withUnregisteredHandlerDo: @7 line 3   [GsMethod 202627073]
32 WASessionContinuation >> basicValue @4 line 2   [GsMethod 202625537]
33 WASessionContinuation >> value @3 line 5   [GsMethod 202623745]
34 WASession >> handleFiltered: @14 line 10   [GsMethod 202205441]
35 WARequestFilter >> handleFiltered: @2 line 4   [GsMethod 176192513]
36 ComplexBlock in WADeprecatedToolFilter >> handleFiltered: @3 line 2   [GsMethod 203213313]
37 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
38 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
39 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
40 WADeprecatedToolFilter >> handleFiltered: @6 line 3   [GsMethod 203213313]
41 WARequestFilter >> handleFiltered: @2 line 4   [GsMethod 176192513]
42 ComplexBlock in WATimingToolFilter >> handleFiltered: @4 line 3   [GsMethod 203208449]
43 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
44 ComplexBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
45 WATimingToolFilter >> handleFiltered: @8 line 4   [GsMethod 203208449]
46 ComplexBlock in WARequestHandler >> handle: @4 line 4   [GsMethod 178568961]
47 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
48 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
49 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
50 WADynamicVariable class >> use:during: @4 line 4   [GsMethod 177805825]
51 ComplexBlock in WARequestContext >> push:during: @4 line 5   [GsMethod 176176129]
52 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
53 ComplexBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
54 WARequestContext >> push:during: @7 line 6   [GsMethod 176176129]
55 WARequestHandler >> handle: @5 line 4   [GsMethod 178568961]
56 WASession >> handle: @10 line 11   [GsMethod 202210561]
57 WARegistry >> dispatch:to: @1 line 5   [GsMethod 176153857]
58 WARegistry >> handleKeyed:with: @2 line 5   [GsMethod 176155137]
59 WARegistry >> handleFiltered: @33 line 19   [GsMethod 176146945]
60 WAApplication >> handleFiltered: @9 line 8   [GsMethod 202644225]
61 WARequestFilter >> handleFiltered: @2 line 4   [GsMethod 176192513]
62 ComplexBlock in WAExceptionFilter >> handleFiltered: @3 line 3   [GsMethod 178300417]
63 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
64 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
65 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
66 WAExceptionHandler >> handleExceptionsDuring: @8 line 3   [GsMethod 177803521]
67 WAExceptionHandler class >> handleExceptionsDuring:context: @2 line 2   [GsMethod 177810177]
68 WAExceptionFilter >> handleFiltered: @4 line 3   [GsMethod 178300417]
69 ComplexBlock in WARequestHandler >> handle: @4 line 4   [GsMethod 178568961]
70 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
71 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
72 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
73 WADynamicVariable class >> use:during: @4 line 4   [GsMethod 177805825]
74 ComplexBlock in WARequestContext >> push:during: @4 line 5   [GsMethod 176176129]
75 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
76 ComplexBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
77 WARequestContext >> push:during: @7 line 6   [GsMethod 176176129]
78 WARequestHandler >> handle: @5 line 4   [GsMethod 178568961]
79 WADispatcher >> handleFiltered:named: @7 line 5   [GsMethod 179090945]
80 WADispatcher >> handleFiltered: @7 line 6   [GsMethod 179087617]
81 ComplexBlock in WARequestHandler >> handle: @4 line 4   [GsMethod 178568961]
82 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
83 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
84 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
85 WADynamicVariable class >> use:during: @4 line 4   [GsMethod 177805825]
86 ComplexBlock in WARequestContext >> push:during: @4 line 5   [GsMethod 176176129]
87 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
88 ComplexBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
89 WARequestContext >> push:during: @7 line 6   [GsMethod 176176129]
90 WARequestHandler >> handle: @5 line 4   [GsMethod 178568961]
91 ComplexBlock in WAServerAdaptor >> handleRequest: @4 line 4   [GsMethod 176816641]
92 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
93 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
94 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
95 WAServerAdaptor >> handleRequest: @6 line 5   [GsMethod 176816641]
96 WAServerAdaptor >> handle: @1 line 4   [GsMethod 176817921]
97 ComplexBlock in WAServerAdaptor >> process: @5 line 6   [GsMethod 176817153]
98 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
99 ComplexBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
100 WAServerAdaptor >> process: @9 line 7   [GsMethod 176817153]
101 ComplexBlock in WAGsSwazooAdaptor >> process: @3 line 6   [GsMethod 209224705]
102 ComplexBlock in GRGemStonePlatform >> seasideProcessRequestWithRetry:resultBlock: @12 line 11   [GsMethod 175179265]
103 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
104 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
105 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
106 ComplexVCBlock in GRGemStonePlatform >> seasideProcessRequestWithRetry:resultBlock: @18 line 12   [GsMethod 175179265]
107 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
108 ComplexVCBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
109 TransientRecursionLock >> critical: @15 line 8   [GsMethod 21159937]
110 GRGemStonePlatform >> seasideProcessRequestWithRetry:resultBlock: @39 line 5   [GsMethod 175179265]
111 ComplexBlock in GRGemStonePlatform >> seasideProcessRequest:adaptor:resultBlock: @7 line 9   [GsMethod 175179521]
112 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
113 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
114 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
115 GRGemStonePlatform >> seasideProcessRequest:adaptor:resultBlock: @32 line 17   [GsMethod 175179521]
116 WAGsSwazooAdaptor >> process: @4 line 4   [GsMethod 209224705]
117 WAPluggableSite >> answerTo: @2 line 2   [GsMethod 203002625]
118 WAPluggableSite >> helpResolve: @7 line 3   [GsMethod 203002113]
119 URIResolution >> visitResource: @1 line 2   [GsMethod 185922561]
120 ComplexBlock in URIResolution >> visitChildrenOf:advancing: @10 line 7   [GsMethod 185924097]
121 Collection >> do: @5 line 10   [GsMethod 1547777]
122 URIResolution >> visitChildrenOf:advancing: @15 line 5   [GsMethod 185924097]
123 URIResolution >> resolveTransparentComposite: @2 line 2   [GsMethod 185924609]
124 URIResolution >> resolveServerRoot: @1 line 2   [GsMethod 185920257]
125 ServerRootComposite >> helpResolve: @1 line 2   [GsMethod 186024449]
126 URIResolution >> visitResource: @1 line 2   [GsMethod 185922561]
127 URIResolution class >> resolveRequest:startingAt: @3 line 2   [GsMethod 185802241]
128 HTTPServer >> answerTo: @3 line 3   [GsMethod 186053889]
129 ComplexBlock in HTTPConnection >> produceResponseFor: @9 line 5   [GsMethod 185650433]
130 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
131 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
132 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
133 HTTPConnection >> produceResponseFor: @23 line 6   [GsMethod 185650433]
134 HTTPConnection >> getAndDispatchMessages @9 line 9   [GsMethod 185651201]
135 ComplexBlock in HTTPConnection >> interact @7 line 6   [GsMethod 185651457]
136 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
137 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
138 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
139 ComplexVCBlock in HTTPConnection >> interact @12 line 9   [GsMethod 185651457]
140 ComplexBlock in ExecutableBlock >> ifCurtailed: @4 line 6   [GsMethod 116163329]
141 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
142 ComplexBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
143 ComplexVCBlock in ExecutableBlock >> ifCurtailed: @8 line 8   [GsMethod 116163329]
144 ComplexVCBlock in HTTPConnection >> interact @19 line 13   [GsMethod 185651457]
145 HTTPConnection >> interact @26 line 18   [GsMethod 185651457]
146 HTTPServer >> acceptConnection @14 line 13   [GsMethod 186054145]
147 ComplexBlock in HTTPServer >> start @13 line 6   [GsMethod 186054913]
148 ComplexBlock in BlockClosure >> repeat @3 line 5   [GsMethod 19138561]
149 ComplexVCBlock in HTTPServer >> start @14 line 6   [GsMethod 186054913]
150 GsProcess >> _startPart2 @15 line 17   [GsMethod 4501249]
151 GsProcess >> _start @1 line 9   [GsMethod 4501761]
  [GsProcess 361105409]
topaz 1> GemStone Smalltalk Compiler Errors:
   GemToGemAnnouncement uninstallStaticHandler.
   System beginTransaction.
   (ObjectLogEntry
     fatal: '8080: topaz exit'
     object:
       'port: ', Swazoo printString, ' ',
 *               ^1                                                   *******
       'pid: ', (System gemVersionReport at: 'processId') printString) addToLog.
   System commitTransaction.

1: [1031] undefined symbol

Now executing the following command saved from "iferr 1":
   where
Stack is not active
topaz 1> Sun Jan 15 18:16:58 UTC 2012
Sun Jan 15 18:16:58 UTC 2012

hostcalldebugger invoked in process 1590, at 01/15/2012 06:16:58 PM.598 UTC
 notifying stone of fatal error

[Info]: Logging out at 01/15/2012 06:16:58 PM UTC


On Jan 16, 2012, at 2:42 PM, James Foster wrote:

> Larry,
>
> GemStone has a lot of moving parts and it can be confusing to tell which piece is involved. In your case the stone log reports that a gem (with PID 1590) crashed. When the gem was started, was there a script that redirected output to a file? If so, do you have that file available?
>
> A typical explanation for this sort of problem is running out of temporary object cache in a gem. Doing so will cause the gem to crash and not be able to report anything to the object log (as it would do for a non-fatal error). Depending on what the user clicked on, your code may have taken a different path, or tried to load different objects.
>
> Auto-restarting a gem is typically done with a shell script (e.g., bash). You can have a loop that checks for the existence of a file and if it is present (or absent, depending on your preference), then start the gem. When the gem crashes, control will return to the script and the loop will continue. If you want to stop the loop you can manually remove (or create) the flag file (or just manually kill the process running the shell script).
>
> -James
>
> On Jan 15, 2012, at 11:40 AM, Lawrence Kellogg wrote:
>
>> Hello,
>> So, my GLASS server has been running for days on Amazon's service. I logged in many
>> times a day, and worked with it, no problems.
>>
>> I gave the server information to someone else to try, and the server crashed with the
>> following error: (from the seaside.log)
>>
>> --- 01/13/2012 03:39:21 AM.771 UTC :    Session 2 with processId 1384 is now the Symbol Creation Gem.
>>   Session 3 with processId 1383 is now the Admin Gem.
>>
>>   Session 4 with processId 1382 is now the Page Reclaim Gem for
>>   extents 0 through 0.
>>
>> --- 01/15/2012 06:16:58 PM UTC ---
>>   Fatal Internal Error Notification from Gem, user = DataCurator  Session = 6
>>     Gem hostName = localhost , Gem processId = 1590,
>>     current  CommitRecord = 2376
>>
>> =======================================
>>
>> Any idea on how I can debug something like this? I have no idea what happened.
>> There are no walkbacks in the Debug option on the Gemtools launcher. All I know is
>> that the user was clicking around with FIrefox and it crashed.
>>
>> Furthermore, is there an easy way for me to restart my Gems once they go down?
>> I start them with this:
>>
>> WAGemStoneRunSeasideGems default
>> name: 'Swazoo';
>> adaptorClass: WAGsSwazooAdaptor;
>> ports: #(8080).
>> WAGemStoneRunSeasideGems restartGems.
>>
>> After the crash, I restarted the Gems and the server process was fine.
>>
>> Regards,
>>
>> Larry
>

Reply | Threaded
Open this post in threaded view
|

Re: Running SeasideGems, confusion

Larry Kellogg
In reply to this post by Johan Brichau-2
Johan,

On Jan 16, 2012, at 2:53 PM, Johan Brichau wrote:

> Larry,
>
> Are you trying to connect to port 9001 from your webbrowser?
>

  Yes, well, from within an index.html file that was being served up by an Apache server, from within an
iFrame, like this:

<body class="borderless">
<iframe src="http://myseasideserver.com:9001"
 name="myapp" width="795" marginwidth="0" height="880" marginheight="0" scrolling="no" frameborder="0" class="borderless"></iframe>
</body>

I guess this is not legit.


> If yes: Swazoo and FastCGI adaptors are different kinds of servers.
>
> A Swazoo adaptor brings up an http server, which you can directly connect to from your webbrowser.
> A FastCGI adaptor brings up a FastCGI server, which can only be connected to via a front-end http server (such as apache, nginx, lighttpd,...)
>

  So, nginx is a replacement for Apache, right? I just went through a few hours of work to get Apache
running but if nginx is better, I can try that route.

> While Swazoo works OK, using a FastCGI behind a frond-end webserver is a lot faster (in my experience).
>
> A good post on using Seaside with FastCGI can be found here:
> http://www.monkeysnatchbanana.com/posts/2010/08/17/using-fastcgi-with-nginx-and-seaside.html
>

  Thanks for the link. I will study it and try to configure my system so that it uses nginx.
I appear to have nginx installed, at least, that's what sudo yum install nginx claims...

Setting up Install Process
Package nginx-0.8.54-1.4.amzn1.x86_64 already installed and latest version
Nothing to do


  Regards,

  Larry
 

> cheers,
> Johan
>
> On 16 Jan 2012, at 20:15, Lawrence Kellogg wrote:
>
>> Hello,
>> So, I'm a little confused about running Seaside Gems from the command line
>> versus from within an image.
>>
>> I have installed Apache and I am bringing up a page that embeds my Seaside
>> server in an iFrame.
>>
>> Now, if I just run Seaside Gems from the command line with this command:
>>
>> runSeasideGems30 start  WAFastCGIAdaptor 9001
>>
>> I cannot forward to my Seaside app on port 9001 from within my index.html but if I bring up
>> a Smalltalk image and run this command in a workspace:
>>
>>
>> WAGemStoneRunSeasideGems default
>> name: 'Swazoo';
>> adaptorClass: WAGsSwazooAdaptor;
>> ports: #(8080).
>> WAGemStoneRunSeasideGems restartGems.
>>
>> then I can forward to port 8080 for my application, from within index.html.
>>
>> I'm just a little confused about what is going on here.
>> Is the FastCGI server being used at all? Should I just start
>> Swazoo from inside the image and not start the FastCGI stuff?
>>
>> Why can't I get any response from the FastCGI code running on
>> port 9001?
>>
>> I'm not clear on what is going on.
>>
>> Thanks,
>>
>> Larry
>

Reply | Threaded
Open this post in threaded view
|

Re: Fatal Internal Notification from Gem

James Foster-8
In reply to this post by Larry Kellogg
You found the correct log file and provided a useful dump of the error. Now, as to the error... I think that "object does not exist" is something that shouldn't happen--that is, it probably isn't your configuration or Smalltalk code that is in error. What version of GemStone are you running?

-James

On Jan 16, 2012, at 12:21 PM, Lawrence Kellogg wrote:

> James,
>  Well, I think I traced the crash to the fact that I has mistakenly reintroduced some code that was trying to call out to Cloudfork.
> I removed that code and everything seems to be running better now, but it is a little too early to tell, for sure.
>
>  Looking through the log files, and in particular, a Swazoo server log file, I guess this
> walkback brought down the Gem. Is this of any help?
>
>  Thanks for the tips with regards to writing a little shell script to restart my Ges.
> I'll do that. With all the moving parts, I'm amazed that I have gotten as much up
> and running as I have. ;-)
>
>  Regards,
>
>  Larry
>
>
>
>
> The object with object ID 81065893475386368 does not exist.
> Error Category: 231169 [GemStone] Number: 2101 Arg Count: 1 Context : 361105409
> Arg 1: [648527147803090946 sz:0 cls: 74241 SmallInteger] 81065893475386368
>
> Now executing the following command saved from "iferr 1":
>   where
> ==> 1 GsProcess class >> installPartialContinuation:atLevel:value: @2 line 1   [GsMethod 4487425]
> 2 WAPartialContinuation >> value: @13 line 11   [GsMethod 212791041]
> 3 WAPartialContinuation >> valueWithPossibleArguments: @2 line 2   [GsMethod 218326273]
> 4 ComplexBlock in WAComponent >> show:onAnswer:delegation: @7 line 7   [GsMethod 194749185]
> 5 ComplexBlock in ExecutableBlock >> valueWithPossibleArguments: @12 line 8   [GsMethod 116163585]
> 6 WAAnswerHandler >> handleAnswer:continueWith: @3 line 2   [GsMethod 194735873]
> 7 WADecoration >> handleAnswer: @6 line 3   [GsMethod 194731009]
> 8 WAComponent >> answer: @2 line 5   [GsMethod 194751745]
> 9 MyComponent >> sendAnswerToCurrentComponent @2 line 2   [GsMethod 278171137]
> 10 ComplexBlock in MyComponent >> renderNavigationMenuOn: @53 line 47   [GsMethod 259119617]
> 11 ComplexBlock in ExecutableBlock >> valueWithPossibleArguments: @6 line 4   [GsMethod 116163585]
> 12 WAActionCallback >> evaluateWithArgument: @3 line 2   [GsMethod 176951297]
> 13 WACallback >> evaluateWithFieldValues: @5 line 2   [GsMethod 177495553]
> 14 ComplexBlock in WACallbackRegistry >> handle: @16 line 10   [GsMethod 177951489]
> 15 Collection >> do: @5 line 10   [GsMethod 1547777]
> 16 WACallbackRegistry >> handle: @17 line 9   [GsMethod 177951489]
> 17 ComplexBlock in WAActionPhaseContinuation >> runCallbacks @7 line 4   [GsMethod 202613505]
> 18 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
> 19 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
> 20 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
> 21 WARenderLoopContinuation >> withNotificationHandlerDo: @3 line 2   [GsMethod 202608385]
> 22 ComplexVCBlock in WAActionPhaseContinuation >> runCallbacks @8 line 3   [GsMethod 202613505]
> 23 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
> 24 ComplexVCBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
> 25 WAActionPhaseContinuation >> runCallbacks @18 line 6   [GsMethod 202613505]
> 26 WAActionPhaseContinuation >> handleRequest @1 line 2   [GsMethod 202614017]
> 27 ComplexBlock in WASessionContinuation >> basicValue @3 line 2   [GsMethod 202625537]
> 28 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
> 29 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
> 30 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
> 31 WASessionContinuation >> withUnregisteredHandlerDo: @7 line 3   [GsMethod 202627073]
> 32 WASessionContinuation >> basicValue @4 line 2   [GsMethod 202625537]
> 33 WASessionContinuation >> value @3 line 5   [GsMethod 202623745]
> 34 WASession >> handleFiltered: @14 line 10   [GsMethod 202205441]
> 35 WARequestFilter >> handleFiltered: @2 line 4   [GsMethod 176192513]
> 36 ComplexBlock in WADeprecatedToolFilter >> handleFiltered: @3 line 2   [GsMethod 203213313]
> 37 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
> 38 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
> 39 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
> 40 WADeprecatedToolFilter >> handleFiltered: @6 line 3   [GsMethod 203213313]
> 41 WARequestFilter >> handleFiltered: @2 line 4   [GsMethod 176192513]
> 42 ComplexBlock in WATimingToolFilter >> handleFiltered: @4 line 3   [GsMethod 203208449]
> 43 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
> 44 ComplexBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
> 45 WATimingToolFilter >> handleFiltered: @8 line 4   [GsMethod 203208449]
> 46 ComplexBlock in WARequestHandler >> handle: @4 line 4   [GsMethod 178568961]
> 47 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
> 48 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
> 49 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
> 50 WADynamicVariable class >> use:during: @4 line 4   [GsMethod 177805825]
> 51 ComplexBlock in WARequestContext >> push:during: @4 line 5   [GsMethod 176176129]
> 52 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
> 53 ComplexBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
> 54 WARequestContext >> push:during: @7 line 6   [GsMethod 176176129]
> 55 WARequestHandler >> handle: @5 line 4   [GsMethod 178568961]
> 56 WASession >> handle: @10 line 11   [GsMethod 202210561]
> 57 WARegistry >> dispatch:to: @1 line 5   [GsMethod 176153857]
> 58 WARegistry >> handleKeyed:with: @2 line 5   [GsMethod 176155137]
> 59 WARegistry >> handleFiltered: @33 line 19   [GsMethod 176146945]
> 60 WAApplication >> handleFiltered: @9 line 8   [GsMethod 202644225]
> 61 WARequestFilter >> handleFiltered: @2 line 4   [GsMethod 176192513]
> 62 ComplexBlock in WAExceptionFilter >> handleFiltered: @3 line 3   [GsMethod 178300417]
> 63 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
> 64 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
> 65 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
> 66 WAExceptionHandler >> handleExceptionsDuring: @8 line 3   [GsMethod 177803521]
> 67 WAExceptionHandler class >> handleExceptionsDuring:context: @2 line 2   [GsMethod 177810177]
> 68 WAExceptionFilter >> handleFiltered: @4 line 3   [GsMethod 178300417]
> 69 ComplexBlock in WARequestHandler >> handle: @4 line 4   [GsMethod 178568961]
> 70 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
> 71 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
> 72 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
> 73 WADynamicVariable class >> use:during: @4 line 4   [GsMethod 177805825]
> 74 ComplexBlock in WARequestContext >> push:during: @4 line 5   [GsMethod 176176129]
> 75 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
> 76 ComplexBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
> 77 WARequestContext >> push:during: @7 line 6   [GsMethod 176176129]
> 78 WARequestHandler >> handle: @5 line 4   [GsMethod 178568961]
> 79 WADispatcher >> handleFiltered:named: @7 line 5   [GsMethod 179090945]
> 80 WADispatcher >> handleFiltered: @7 line 6   [GsMethod 179087617]
> 81 ComplexBlock in WARequestHandler >> handle: @4 line 4   [GsMethod 178568961]
> 82 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
> 83 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
> 84 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
> 85 WADynamicVariable class >> use:during: @4 line 4   [GsMethod 177805825]
> 86 ComplexBlock in WARequestContext >> push:during: @4 line 5   [GsMethod 176176129]
> 87 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
> 88 ComplexBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
> 89 WARequestContext >> push:during: @7 line 6   [GsMethod 176176129]
> 90 WARequestHandler >> handle: @5 line 4   [GsMethod 178568961]
> 91 ComplexBlock in WAServerAdaptor >> handleRequest: @4 line 4   [GsMethod 176816641]
> 92 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
> 93 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
> 94 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
> 95 WAServerAdaptor >> handleRequest: @6 line 5   [GsMethod 176816641]
> 96 WAServerAdaptor >> handle: @1 line 4   [GsMethod 176817921]
> 97 ComplexBlock in WAServerAdaptor >> process: @5 line 6   [GsMethod 176817153]
> 98 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
> 99 ComplexBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
> 100 WAServerAdaptor >> process: @9 line 7   [GsMethod 176817153]
> 101 ComplexBlock in WAGsSwazooAdaptor >> process: @3 line 6   [GsMethod 209224705]
> 102 ComplexBlock in GRGemStonePlatform >> seasideProcessRequestWithRetry:resultBlock: @12 line 11   [GsMethod 175179265]
> 103 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
> 104 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
> 105 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
> 106 ComplexVCBlock in GRGemStonePlatform >> seasideProcessRequestWithRetry:resultBlock: @18 line 12   [GsMethod 175179265]
> 107 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
> 108 ComplexVCBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
> 109 TransientRecursionLock >> critical: @15 line 8   [GsMethod 21159937]
> 110 GRGemStonePlatform >> seasideProcessRequestWithRetry:resultBlock: @39 line 5   [GsMethod 175179265]
> 111 ComplexBlock in GRGemStonePlatform >> seasideProcessRequest:adaptor:resultBlock: @7 line 9   [GsMethod 175179521]
> 112 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
> 113 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
> 114 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
> 115 GRGemStonePlatform >> seasideProcessRequest:adaptor:resultBlock: @32 line 17   [GsMethod 175179521]
> 116 WAGsSwazooAdaptor >> process: @4 line 4   [GsMethod 209224705]
> 117 WAPluggableSite >> answerTo: @2 line 2   [GsMethod 203002625]
> 118 WAPluggableSite >> helpResolve: @7 line 3   [GsMethod 203002113]
> 119 URIResolution >> visitResource: @1 line 2   [GsMethod 185922561]
> 120 ComplexBlock in URIResolution >> visitChildrenOf:advancing: @10 line 7   [GsMethod 185924097]
> 121 Collection >> do: @5 line 10   [GsMethod 1547777]
> 122 URIResolution >> visitChildrenOf:advancing: @15 line 5   [GsMethod 185924097]
> 123 URIResolution >> resolveTransparentComposite: @2 line 2   [GsMethod 185924609]
> 124 URIResolution >> resolveServerRoot: @1 line 2   [GsMethod 185920257]
> 125 ServerRootComposite >> helpResolve: @1 line 2   [GsMethod 186024449]
> 126 URIResolution >> visitResource: @1 line 2   [GsMethod 185922561]
> 127 URIResolution class >> resolveRequest:startingAt: @3 line 2   [GsMethod 185802241]
> 128 HTTPServer >> answerTo: @3 line 3   [GsMethod 186053889]
> 129 ComplexBlock in HTTPConnection >> produceResponseFor: @9 line 5   [GsMethod 185650433]
> 130 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
> 131 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
> 132 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
> 133 HTTPConnection >> produceResponseFor: @23 line 6   [GsMethod 185650433]
> 134 HTTPConnection >> getAndDispatchMessages @9 line 9   [GsMethod 185651201]
> 135 ComplexBlock in HTTPConnection >> interact @7 line 6   [GsMethod 185651457]
> 136 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
> 137 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
> 138 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
> 139 ComplexVCBlock in HTTPConnection >> interact @12 line 9   [GsMethod 185651457]
> 140 ComplexBlock in ExecutableBlock >> ifCurtailed: @4 line 6   [GsMethod 116163329]
> 141 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
> 142 ComplexBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
> 143 ComplexVCBlock in ExecutableBlock >> ifCurtailed: @8 line 8   [GsMethod 116163329]
> 144 ComplexVCBlock in HTTPConnection >> interact @19 line 13   [GsMethod 185651457]
> 145 HTTPConnection >> interact @26 line 18   [GsMethod 185651457]
> 146 HTTPServer >> acceptConnection @14 line 13   [GsMethod 186054145]
> 147 ComplexBlock in HTTPServer >> start @13 line 6   [GsMethod 186054913]
> 148 ComplexBlock in BlockClosure >> repeat @3 line 5   [GsMethod 19138561]
> 149 ComplexVCBlock in HTTPServer >> start @14 line 6   [GsMethod 186054913]
> 150 GsProcess >> _startPart2 @15 line 17   [GsMethod 4501249]
> 151 GsProcess >> _start @1 line 9   [GsMethod 4501761]
>  [GsProcess 361105409]
> topaz 1> GemStone Smalltalk Compiler Errors:
>   GemToGemAnnouncement uninstallStaticHandler.
>   System beginTransaction.
>   (ObjectLogEntry
>     fatal: '8080: topaz exit'
>     object:
>       'port: ', Swazoo printString, ' ',
> *               ^1                                                   *******
>       'pid: ', (System gemVersionReport at: 'processId') printString) addToLog.
>   System commitTransaction.
>
> 1: [1031] undefined symbol
>
> Now executing the following command saved from "iferr 1":
>   where
> Stack is not active
> topaz 1> Sun Jan 15 18:16:58 UTC 2012
> Sun Jan 15 18:16:58 UTC 2012
>
> hostcalldebugger invoked in process 1590, at 01/15/2012 06:16:58 PM.598 UTC
> notifying stone of fatal error
>
> [Info]: Logging out at 01/15/2012 06:16:58 PM UTC
>
>
> On Jan 16, 2012, at 2:42 PM, James Foster wrote:
>
>> Larry,
>>
>> GemStone has a lot of moving parts and it can be confusing to tell which piece is involved. In your case the stone log reports that a gem (with PID 1590) crashed. When the gem was started, was there a script that redirected output to a file? If so, do you have that file available?
>>
>> A typical explanation for this sort of problem is running out of temporary object cache in a gem. Doing so will cause the gem to crash and not be able to report anything to the object log (as it would do for a non-fatal error). Depending on what the user clicked on, your code may have taken a different path, or tried to load different objects.
>>
>> Auto-restarting a gem is typically done with a shell script (e.g., bash). You can have a loop that checks for the existence of a file and if it is present (or absent, depending on your preference), then start the gem. When the gem crashes, control will return to the script and the loop will continue. If you want to stop the loop you can manually remove (or create) the flag file (or just manually kill the process running the shell script).
>>
>> -James
>>
>> On Jan 15, 2012, at 11:40 AM, Lawrence Kellogg wrote:
>>
>>> Hello,
>>> So, my GLASS server has been running for days on Amazon's service. I logged in many
>>> times a day, and worked with it, no problems.
>>>
>>> I gave the server information to someone else to try, and the server crashed with the
>>> following error: (from the seaside.log)
>>>
>>> --- 01/13/2012 03:39:21 AM.771 UTC :    Session 2 with processId 1384 is now the Symbol Creation Gem.
>>>  Session 3 with processId 1383 is now the Admin Gem.
>>>
>>>  Session 4 with processId 1382 is now the Page Reclaim Gem for
>>>  extents 0 through 0.
>>>
>>> --- 01/15/2012 06:16:58 PM UTC ---
>>>  Fatal Internal Error Notification from Gem, user = DataCurator  Session = 6
>>>    Gem hostName = localhost , Gem processId = 1590,
>>>    current  CommitRecord = 2376
>>>
>>> =======================================
>>>
>>> Any idea on how I can debug something like this? I have no idea what happened.
>>> There are no walkbacks in the Debug option on the Gemtools launcher. All I know is
>>> that the user was clicking around with FIrefox and it crashed.
>>>
>>> Furthermore, is there an easy way for me to restart my Gems once they go down?
>>> I start them with this:
>>>
>>> WAGemStoneRunSeasideGems default
>>> name: 'Swazoo';
>>> adaptorClass: WAGsSwazooAdaptor;
>>> ports: #(8080).
>>> WAGemStoneRunSeasideGems restartGems.
>>>
>>> After the crash, I restarted the Gems and the server process was fine.
>>>
>>> Regards,
>>>
>>> Larry
>>
>

Reply | Threaded
Open this post in threaded view
|

Re: Running SeasideGems, confusion

Johan Brichau-2
In reply to this post by Larry Kellogg
Larry,

You can use FastCGI with Apache as well: http://www.fastcgi.com/mod_fastcgi/docs/mod_fastcgi.html
There is no need to switch to Nginx for that.

But you cannot connect to the fastcgi port with your webbrowser, simply because a FastCGI adaptor does not serve http.
Instead, it serves the FastCGI protocol, which is understood by the fastcgi module of your front-end webserver. In turn, the front-end webserver, will serve http.

So, the link in your iframe can never work if port 9001 is serving FastCGI.

Johan

On 16 Jan 2012, at 21:27, Lawrence Kellogg wrote:

> Johan,
>
> On Jan 16, 2012, at 2:53 PM, Johan Brichau wrote:
>
>> Larry,
>>
>> Are you trying to connect to port 9001 from your webbrowser?
>>
>
>  Yes, well, from within an index.html file that was being served up by an Apache server, from within an
> iFrame, like this:
>
> <body class="borderless">
> <iframe src="http://myseasideserver.com:9001"
> name="myapp" width="795" marginwidth="0" height="880" marginheight="0" scrolling="no" frameborder="0" class="borderless"></iframe>
> </body>
>
> I guess this is not legit.
>
>
>> If yes: Swazoo and FastCGI adaptors are different kinds of servers.
>>
>> A Swazoo adaptor brings up an http server, which you can directly connect to from your webbrowser.
>> A FastCGI adaptor brings up a FastCGI server, which can only be connected to via a front-end http server (such as apache, nginx, lighttpd,...)
>>
>
>  So, nginx is a replacement for Apache, right? I just went through a few hours of work to get Apache
> running but if nginx is better, I can try that route.
>
>> While Swazoo works OK, using a FastCGI behind a frond-end webserver is a lot faster (in my experience).
>>
>> A good post on using Seaside with FastCGI can be found here:
>> http://www.monkeysnatchbanana.com/posts/2010/08/17/using-fastcgi-with-nginx-and-seaside.html
>>
>
>  Thanks for the link. I will study it and try to configure my system so that it uses nginx.
> I appear to have nginx installed, at least, that's what sudo yum install nginx claims...
>
> Setting up Install Process
> Package nginx-0.8.54-1.4.amzn1.x86_64 already installed and latest version
> Nothing to do
>
>
>  Regards,
>
>  Larry
>
>
>> cheers,
>> Johan
>>
>> On 16 Jan 2012, at 20:15, Lawrence Kellogg wrote:
>>
>>> Hello,
>>> So, I'm a little confused about running Seaside Gems from the command line
>>> versus from within an image.
>>>
>>> I have installed Apache and I am bringing up a page that embeds my Seaside
>>> server in an iFrame.
>>>
>>> Now, if I just run Seaside Gems from the command line with this command:
>>>
>>> runSeasideGems30 start  WAFastCGIAdaptor 9001
>>>
>>> I cannot forward to my Seaside app on port 9001 from within my index.html but if I bring up
>>> a Smalltalk image and run this command in a workspace:
>>>
>>>
>>> WAGemStoneRunSeasideGems default
>>> name: 'Swazoo';
>>> adaptorClass: WAGsSwazooAdaptor;
>>> ports: #(8080).
>>> WAGemStoneRunSeasideGems restartGems.
>>>
>>> then I can forward to port 8080 for my application, from within index.html.
>>>
>>> I'm just a little confused about what is going on here.
>>> Is the FastCGI server being used at all? Should I just start
>>> Swazoo from inside the image and not start the FastCGI stuff?
>>>
>>> Why can't I get any response from the FastCGI code running on
>>> port 9001?
>>>
>>> I'm not clear on what is going on.
>>>
>>> Thanks,
>>>
>>> Larry
>>
>

Reply | Threaded
Open this post in threaded view
|

Re: Fatal Internal Notification from Gem

Larry Kellogg
In reply to this post by James Foster-8
  I'm on Gemstone 2.4.4.1, with the latest updates loaded for GLASS and the GemTools launcher.
At the point, I believe the error was due to a call into Cloudfork, it's the most likely culprit. I haven't seen
the error after I unloaded all of the Cloudfork packages.

  I'll keep an eye on it to see if it happens again. The system seems quite stable now, although
there is no heavy load on it, yet. Thanks for the help.

  Regards,

  Larry

On Jan 16, 2012, at 3:31 PM, James Foster wrote:

> You found the correct log file and provided a useful dump of the error. Now, as to the error... I think that "object does not exist" is something that shouldn't happen--that is, it probably isn't your configuration or Smalltalk code that is in error. What version of GemStone are you running?
>
> -James
>
> On Jan 16, 2012, at 12:21 PM, Lawrence Kellogg wrote:
>
>> James,
>> Well, I think I traced the crash to the fact that I has mistakenly reintroduced some code that was trying to call out to Cloudfork.
>> I removed that code and everything seems to be running better now, but it is a little too early to tell, for sure.
>>
>> Looking through the log files, and in particular, a Swazoo server log file, I guess this
>> walkback brought down the Gem. Is this of any help?
>>
>> Thanks for the tips with regards to writing a little shell script to restart my Ges.
>> I'll do that. With all the moving parts, I'm amazed that I have gotten as much up
>> and running as I have. ;-)
>>
>> Regards,
>>
>> Larry
>>
>>
>>
>>
>> The object with object ID 81065893475386368 does not exist.
>> Error Category: 231169 [GemStone] Number: 2101 Arg Count: 1 Context : 361105409
>> Arg 1: [648527147803090946 sz:0 cls: 74241 SmallInteger] 81065893475386368
>>
>> Now executing the following command saved from "iferr 1":
>>  where
>> ==> 1 GsProcess class >> installPartialContinuation:atLevel:value: @2 line 1   [GsMethod 4487425]
>> 2 WAPartialContinuation >> value: @13 line 11   [GsMethod 212791041]
>> 3 WAPartialContinuation >> valueWithPossibleArguments: @2 line 2   [GsMethod 218326273]
>> 4 ComplexBlock in WAComponent >> show:onAnswer:delegation: @7 line 7   [GsMethod 194749185]
>> 5 ComplexBlock in ExecutableBlock >> valueWithPossibleArguments: @12 line 8   [GsMethod 116163585]
>> 6 WAAnswerHandler >> handleAnswer:continueWith: @3 line 2   [GsMethod 194735873]
>> 7 WADecoration >> handleAnswer: @6 line 3   [GsMethod 194731009]
>> 8 WAComponent >> answer: @2 line 5   [GsMethod 194751745]
>> 9 MyComponent >> sendAnswerToCurrentComponent @2 line 2   [GsMethod 278171137]
>> 10 ComplexBlock in MyComponent >> renderNavigationMenuOn: @53 line 47   [GsMethod 259119617]
>> 11 ComplexBlock in ExecutableBlock >> valueWithPossibleArguments: @6 line 4   [GsMethod 116163585]
>> 12 WAActionCallback >> evaluateWithArgument: @3 line 2   [GsMethod 176951297]
>> 13 WACallback >> evaluateWithFieldValues: @5 line 2   [GsMethod 177495553]
>> 14 ComplexBlock in WACallbackRegistry >> handle: @16 line 10   [GsMethod 177951489]
>> 15 Collection >> do: @5 line 10   [GsMethod 1547777]
>> 16 WACallbackRegistry >> handle: @17 line 9   [GsMethod 177951489]
>> 17 ComplexBlock in WAActionPhaseContinuation >> runCallbacks @7 line 4   [GsMethod 202613505]
>> 18 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
>> 19 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
>> 20 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
>> 21 WARenderLoopContinuation >> withNotificationHandlerDo: @3 line 2   [GsMethod 202608385]
>> 22 ComplexVCBlock in WAActionPhaseContinuation >> runCallbacks @8 line 3   [GsMethod 202613505]
>> 23 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
>> 24 ComplexVCBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
>> 25 WAActionPhaseContinuation >> runCallbacks @18 line 6   [GsMethod 202613505]
>> 26 WAActionPhaseContinuation >> handleRequest @1 line 2   [GsMethod 202614017]
>> 27 ComplexBlock in WASessionContinuation >> basicValue @3 line 2   [GsMethod 202625537]
>> 28 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
>> 29 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
>> 30 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
>> 31 WASessionContinuation >> withUnregisteredHandlerDo: @7 line 3   [GsMethod 202627073]
>> 32 WASessionContinuation >> basicValue @4 line 2   [GsMethod 202625537]
>> 33 WASessionContinuation >> value @3 line 5   [GsMethod 202623745]
>> 34 WASession >> handleFiltered: @14 line 10   [GsMethod 202205441]
>> 35 WARequestFilter >> handleFiltered: @2 line 4   [GsMethod 176192513]
>> 36 ComplexBlock in WADeprecatedToolFilter >> handleFiltered: @3 line 2   [GsMethod 203213313]
>> 37 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
>> 38 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
>> 39 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
>> 40 WADeprecatedToolFilter >> handleFiltered: @6 line 3   [GsMethod 203213313]
>> 41 WARequestFilter >> handleFiltered: @2 line 4   [GsMethod 176192513]
>> 42 ComplexBlock in WATimingToolFilter >> handleFiltered: @4 line 3   [GsMethod 203208449]
>> 43 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
>> 44 ComplexBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
>> 45 WATimingToolFilter >> handleFiltered: @8 line 4   [GsMethod 203208449]
>> 46 ComplexBlock in WARequestHandler >> handle: @4 line 4   [GsMethod 178568961]
>> 47 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
>> 48 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
>> 49 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
>> 50 WADynamicVariable class >> use:during: @4 line 4   [GsMethod 177805825]
>> 51 ComplexBlock in WARequestContext >> push:during: @4 line 5   [GsMethod 176176129]
>> 52 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
>> 53 ComplexBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
>> 54 WARequestContext >> push:during: @7 line 6   [GsMethod 176176129]
>> 55 WARequestHandler >> handle: @5 line 4   [GsMethod 178568961]
>> 56 WASession >> handle: @10 line 11   [GsMethod 202210561]
>> 57 WARegistry >> dispatch:to: @1 line 5   [GsMethod 176153857]
>> 58 WARegistry >> handleKeyed:with: @2 line 5   [GsMethod 176155137]
>> 59 WARegistry >> handleFiltered: @33 line 19   [GsMethod 176146945]
>> 60 WAApplication >> handleFiltered: @9 line 8   [GsMethod 202644225]
>> 61 WARequestFilter >> handleFiltered: @2 line 4   [GsMethod 176192513]
>> 62 ComplexBlock in WAExceptionFilter >> handleFiltered: @3 line 3   [GsMethod 178300417]
>> 63 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
>> 64 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
>> 65 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
>> 66 WAExceptionHandler >> handleExceptionsDuring: @8 line 3   [GsMethod 177803521]
>> 67 WAExceptionHandler class >> handleExceptionsDuring:context: @2 line 2   [GsMethod 177810177]
>> 68 WAExceptionFilter >> handleFiltered: @4 line 3   [GsMethod 178300417]
>> 69 ComplexBlock in WARequestHandler >> handle: @4 line 4   [GsMethod 178568961]
>> 70 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
>> 71 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
>> 72 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
>> 73 WADynamicVariable class >> use:during: @4 line 4   [GsMethod 177805825]
>> 74 ComplexBlock in WARequestContext >> push:during: @4 line 5   [GsMethod 176176129]
>> 75 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
>> 76 ComplexBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
>> 77 WARequestContext >> push:during: @7 line 6   [GsMethod 176176129]
>> 78 WARequestHandler >> handle: @5 line 4   [GsMethod 178568961]
>> 79 WADispatcher >> handleFiltered:named: @7 line 5   [GsMethod 179090945]
>> 80 WADispatcher >> handleFiltered: @7 line 6   [GsMethod 179087617]
>> 81 ComplexBlock in WARequestHandler >> handle: @4 line 4   [GsMethod 178568961]
>> 82 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
>> 83 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
>> 84 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
>> 85 WADynamicVariable class >> use:during: @4 line 4   [GsMethod 177805825]
>> 86 ComplexBlock in WARequestContext >> push:during: @4 line 5   [GsMethod 176176129]
>> 87 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
>> 88 ComplexBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
>> 89 WARequestContext >> push:during: @7 line 6   [GsMethod 176176129]
>> 90 WARequestHandler >> handle: @5 line 4   [GsMethod 178568961]
>> 91 ComplexBlock in WAServerAdaptor >> handleRequest: @4 line 4   [GsMethod 176816641]
>> 92 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
>> 93 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
>> 94 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
>> 95 WAServerAdaptor >> handleRequest: @6 line 5   [GsMethod 176816641]
>> 96 WAServerAdaptor >> handle: @1 line 4   [GsMethod 176817921]
>> 97 ComplexBlock in WAServerAdaptor >> process: @5 line 6   [GsMethod 176817153]
>> 98 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
>> 99 ComplexBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
>> 100 WAServerAdaptor >> process: @9 line 7   [GsMethod 176817153]
>> 101 ComplexBlock in WAGsSwazooAdaptor >> process: @3 line 6   [GsMethod 209224705]
>> 102 ComplexBlock in GRGemStonePlatform >> seasideProcessRequestWithRetry:resultBlock: @12 line 11   [GsMethod 175179265]
>> 103 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
>> 104 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
>> 105 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
>> 106 ComplexVCBlock in GRGemStonePlatform >> seasideProcessRequestWithRetry:resultBlock: @18 line 12   [GsMethod 175179265]
>> 107 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
>> 108 ComplexVCBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
>> 109 TransientRecursionLock >> critical: @15 line 8   [GsMethod 21159937]
>> 110 GRGemStonePlatform >> seasideProcessRequestWithRetry:resultBlock: @39 line 5   [GsMethod 175179265]
>> 111 ComplexBlock in GRGemStonePlatform >> seasideProcessRequest:adaptor:resultBlock: @7 line 9   [GsMethod 175179521]
>> 112 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
>> 113 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
>> 114 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
>> 115 GRGemStonePlatform >> seasideProcessRequest:adaptor:resultBlock: @32 line 17   [GsMethod 175179521]
>> 116 WAGsSwazooAdaptor >> process: @4 line 4   [GsMethod 209224705]
>> 117 WAPluggableSite >> answerTo: @2 line 2   [GsMethod 203002625]
>> 118 WAPluggableSite >> helpResolve: @7 line 3   [GsMethod 203002113]
>> 119 URIResolution >> visitResource: @1 line 2   [GsMethod 185922561]
>> 120 ComplexBlock in URIResolution >> visitChildrenOf:advancing: @10 line 7   [GsMethod 185924097]
>> 121 Collection >> do: @5 line 10   [GsMethod 1547777]
>> 122 URIResolution >> visitChildrenOf:advancing: @15 line 5   [GsMethod 185924097]
>> 123 URIResolution >> resolveTransparentComposite: @2 line 2   [GsMethod 185924609]
>> 124 URIResolution >> resolveServerRoot: @1 line 2   [GsMethod 185920257]
>> 125 ServerRootComposite >> helpResolve: @1 line 2   [GsMethod 186024449]
>> 126 URIResolution >> visitResource: @1 line 2   [GsMethod 185922561]
>> 127 URIResolution class >> resolveRequest:startingAt: @3 line 2   [GsMethod 185802241]
>> 128 HTTPServer >> answerTo: @3 line 3   [GsMethod 186053889]
>> 129 ComplexBlock in HTTPConnection >> produceResponseFor: @9 line 5   [GsMethod 185650433]
>> 130 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
>> 131 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
>> 132 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
>> 133 HTTPConnection >> produceResponseFor: @23 line 6   [GsMethod 185650433]
>> 134 HTTPConnection >> getAndDispatchMessages @9 line 9   [GsMethod 185651201]
>> 135 ComplexBlock in HTTPConnection >> interact @7 line 6   [GsMethod 185651457]
>> 136 ExceptionHandler >> doTryBlock: @9 line 7   [GsMethod 10065409]
>> 137 ExceptionHandler >> try:on:do: @15 line 18   [GsMethod 10062081]
>> 138 ComplexBlock in ExecutableBlock >> on:do: @2 line 8   [GsMethod 9005057]
>> 139 ComplexVCBlock in HTTPConnection >> interact @12 line 9   [GsMethod 185651457]
>> 140 ComplexBlock in ExecutableBlock >> ifCurtailed: @4 line 6   [GsMethod 116163329]
>> 141 ComplexBlock in ExecutableBlock >> ensure: @4 line 11   [GsMethod 2304001]
>> 142 ComplexBlock in ExecutableBlock >> ensure: @6 line 11   [GsMethod 2304001]
>> 143 ComplexVCBlock in ExecutableBlock >> ifCurtailed: @8 line 8   [GsMethod 116163329]
>> 144 ComplexVCBlock in HTTPConnection >> interact @19 line 13   [GsMethod 185651457]
>> 145 HTTPConnection >> interact @26 line 18   [GsMethod 185651457]
>> 146 HTTPServer >> acceptConnection @14 line 13   [GsMethod 186054145]
>> 147 ComplexBlock in HTTPServer >> start @13 line 6   [GsMethod 186054913]
>> 148 ComplexBlock in BlockClosure >> repeat @3 line 5   [GsMethod 19138561]
>> 149 ComplexVCBlock in HTTPServer >> start @14 line 6   [GsMethod 186054913]
>> 150 GsProcess >> _startPart2 @15 line 17   [GsMethod 4501249]
>> 151 GsProcess >> _start @1 line 9   [GsMethod 4501761]
>> [GsProcess 361105409]
>> topaz 1> GemStone Smalltalk Compiler Errors:
>>  GemToGemAnnouncement uninstallStaticHandler.
>>  System beginTransaction.
>>  (ObjectLogEntry
>>    fatal: '8080: topaz exit'
>>    object:
>>      'port: ', Swazoo printString, ' ',
>> *               ^1                                                   *******
>>      'pid: ', (System gemVersionReport at: 'processId') printString) addToLog.
>>  System commitTransaction.
>>
>> 1: [1031] undefined symbol
>>
>> Now executing the following command saved from "iferr 1":
>>  where
>> Stack is not active
>> topaz 1> Sun Jan 15 18:16:58 UTC 2012
>> Sun Jan 15 18:16:58 UTC 2012
>>
>> hostcalldebugger invoked in process 1590, at 01/15/2012 06:16:58 PM.598 UTC
>> notifying stone of fatal error
>>
>> [Info]: Logging out at 01/15/2012 06:16:58 PM UTC
>>
>>
>> On Jan 16, 2012, at 2:42 PM, James Foster wrote:
>>
>>> Larry,
>>>
>>> GemStone has a lot of moving parts and it can be confusing to tell which piece is involved. In your case the stone log reports that a gem (with PID 1590) crashed. When the gem was started, was there a script that redirected output to a file? If so, do you have that file available?
>>>
>>> A typical explanation for this sort of problem is running out of temporary object cache in a gem. Doing so will cause the gem to crash and not be able to report anything to the object log (as it would do for a non-fatal error). Depending on what the user clicked on, your code may have taken a different path, or tried to load different objects.
>>>
>>> Auto-restarting a gem is typically done with a shell script (e.g., bash). You can have a loop that checks for the existence of a file and if it is present (or absent, depending on your preference), then start the gem. When the gem crashes, control will return to the script and the loop will continue. If you want to stop the loop you can manually remove (or create) the flag file (or just manually kill the process running the shell script).
>>>
>>> -James
>>>
>>> On Jan 15, 2012, at 11:40 AM, Lawrence Kellogg wrote:
>>>
>>>> Hello,
>>>> So, my GLASS server has been running for days on Amazon's service. I logged in many
>>>> times a day, and worked with it, no problems.
>>>>
>>>> I gave the server information to someone else to try, and the server crashed with the
>>>> following error: (from the seaside.log)
>>>>
>>>> --- 01/13/2012 03:39:21 AM.771 UTC :    Session 2 with processId 1384 is now the Symbol Creation Gem.
>>>> Session 3 with processId 1383 is now the Admin Gem.
>>>>
>>>> Session 4 with processId 1382 is now the Page Reclaim Gem for
>>>> extents 0 through 0.
>>>>
>>>> --- 01/15/2012 06:16:58 PM UTC ---
>>>> Fatal Internal Error Notification from Gem, user = DataCurator  Session = 6
>>>>   Gem hostName = localhost , Gem processId = 1590,
>>>>   current  CommitRecord = 2376
>>>>
>>>> =======================================
>>>>
>>>> Any idea on how I can debug something like this? I have no idea what happened.
>>>> There are no walkbacks in the Debug option on the Gemtools launcher. All I know is
>>>> that the user was clicking around with FIrefox and it crashed.
>>>>
>>>> Furthermore, is there an easy way for me to restart my Gems once they go down?
>>>> I start them with this:
>>>>
>>>> WAGemStoneRunSeasideGems default
>>>> name: 'Swazoo';
>>>> adaptorClass: WAGsSwazooAdaptor;
>>>> ports: #(8080).
>>>> WAGemStoneRunSeasideGems restartGems.
>>>>
>>>> After the crash, I restarted the Gems and the server process was fine.
>>>>
>>>> Regards,
>>>>
>>>> Larry
>>>
>>
>

123456