I am using Heroku Automated Certificate Management and Namecheap Basic DNS.
My problem is that my non-SSL domains are still reachable.
Here is how they map in practice:
|---------------------|------------------------------|
| Entered Domain | Result Domain |
|---------------------|------------------------------|
| name.tld | https://www.name.tld/ |
|---------------------|------------------------------|
| www.name.tld | http://www.name.tld/ |
|---------------------|------------------------------|
| http://www.name.tld | http://www.name.tld/ |
|---------------------|------------------------------|
|https://www.name.tld | https://www.name.tld/ |
|---------------------|------------------------------|
| http://name.tld | https://www.name.tld/ |
|---------------------|------------------------------|
| https://name.tld | error: does not resolve |
|---------------------|------------------------------|
My Heroku Domains settings are:
|---------------------|-------------------|
| Domain Name | DNS Target |
|---------------------|-------------------|
| name.tld |name1.herokudns.com|
|---------------------|-------------------|
| www.name.tld |name2.herokudns.com|
|---------------------|-------------------|
My Namecheap Redirect Domain settings are:
|---------------------|---------------------|
| Source URL | Destination URL |
|---------------------|---------------------|
| name.tld |https://www.name.tld/|
|---------------------|---------------------|
| www.name.tld |https://www.name.tld/|
|---------------------|---------------------|
And my Namecheap Host Records settings are:
|---------------------|---------------------|---------------------|
| Type | Host | Value |
|---------------------|---------------------|---------------------|
| CNAME Record | www | name1.herokudns.com.|
|---------------------|---------------------|---------------------|
| URL Redirect Record | # |https://www.name.tld/|
|---------------------|---------------------|---------------------|
Something to note is I do not put name2.herokudns.com into Namecheap because it would conflict, I think.
Related
I am trying to integrate Spring Auth Server with an existing authentication provider, IBM WebSeal in the context of an OICD flow.
Basically, I want Spring Auth Server to use Webseal login page to authenticate a user (coming from a SPA/front-end app) and then return a JWT token to the front-end app.
On successful authentication, WebSeal redirects to a configurable URL adding a header to the request. This header contains the actual username and signals that the user is authenticated.
I was able to implement the flow and have Spring Auth Server use the external login page, but I don't understand to which URL should WebSeal redirect. Do I need to create an explicit end-point (such as /authenticated)?
It seems that the OAUTH2 spec doesn't define an explicit endpoint for this particular case.
Adding diagram for clarity:
+----------------+ +------------------+
| | | |
| | | |
| FRONT END APP | | BACK-END APP |
| | | (SPRING BOOT) |
| | | |
| | | |
+---|----|-------+ +------------------+
| |
4 - /oauth2/token | | 1 - /oauth2/authorize?
| |
| |
| |
+---|----|-------+ +----------------+
| | 3 - send header | |
| SPRING -------------------- |
| AUTH | | WEBSEAL |
| SERVER -------------------| |
| | 2 - show form | |
| | +----------------+
+----------------+
Thanks!
I have a blade template where I call a route to the show method:
<div class="user"><div><img src="{{asset('images/user.svg')}}" alt=""></div></div>
That route is controlled by a resource controller and the routes are set like this:
Route::resource('profile', 'App\Http\Controllers\ProfileController')->middleware('auth');
All the routes of that controller are defined as you can see from the output of my php artisan route:list:
| | GET|HEAD | profile | profile.index | App\Http\Controllers\ProfileController#index | web |
| | | | | | auth |
| | POST | profile | profile.store | App\Http\Controllers\ProfileController#store | web |
| | | | | | auth |
| | GET|HEAD | profile/create | profile.create | App\Http\Controllers\ProfileController#create | web |
| | | | | | auth |
| | GET|HEAD | profile/{profile} | profile.show | App\Http\Controllers\ProfileController#show | web |
| | | | | | auth |
| | DELETE | profile/{profile} | profile.destroy | App\Http\Controllers\ProfileController#destroy | web |
| | | | | | auth |
| | PUT|PATCH | profile/{profile} | profile.update | App\Http\Controllers\ProfileController#update | web |
| | | | | | auth |
| | GET|HEAD | profile/{profile}/edit | profile.edit | App\Http\Controllers\ProfileController#edit | web |
| | | | | | auth |
So far the controller only has a dd function since I haven't started writing it yet and the show method is the only one with anything written yet:
public function show($id)
{ dd($id);}
But for some reason, whenever I try acessing that route, it returns a 404 Not Found error. I tried accessing the index method and it works, but the show method always returns the 404 Not Found error. I also tried php artisan route:clear but it didn't solve the problem. What could I be doing wrong here?
Try out it , list all of router
php artisan route:list
Or you can as such that
Route::resource('profile', 'ProfileController', [
'names' => [
'index' => 'show.show'
'store' => 'profile.new',
]
]);
And if you try this ?
<div class="user"><div><img src="{{asset('images/user.svg')}}" alt=""></div></div>
This is my output on console:
+---------------+---------------------------------------------------+
| Summary for cert 2.96.1 |
+---------------+---------------------------------------------------+
| development | false |
| force | false |
| username | correctappleid#gmail.com |
| team_id | CSCORRECTTEAMID |
| keychain_path | /Users/bartek/Library/Keychains/login.keychain-db |
| platform | ios |
+---------------+---------------------------------------------------+
[09:01:23]: Starting login with user 'correctappleid#gmail.com'
[09:01:27]: Successfully logged in
[09:01:28]: Certificate 98TLCZS7BR (iOS Distribution) can't be found on your local computer
[09:01:29]: Found the certificate 6K5C2MFHUL (iOS Distribution) which is installed on the local machine. Using this one.
[09:01:30]: Verifying the certificate is properly installed locally...
[09:01:30]: Successfully installed certificate 6K5C2MFHUL
[09:01:30]: Use signing certificate '6K5C2MFHUL' from now on!
[09:01:30]: --------------------------------------
[09:01:30]: --- Step: get_provisioning_profile ---
[09:01:30]: --------------------------------------
+-------------------------------------+-------------------------------------------+
| Summary for sigh 2.96.1 |
+-------------------------------------+-------------------------------------------+
| adhoc | false |
| development | false |
| skip_install | false |
| force | false |
| app_identifier | my.app.identifier |
| username | wrongname#company.com |
| team_id | CSTEAMID |
| ignore_profiles_with_different_name | false |
| cert_id | 6K5C2MFHUL |
| skip_fetch_profiles | false |
| skip_certificate_verification | false |
| platform | ios |
| readonly | false |
+-------------------------------------+-------------------------------------------+
[09:01:30]: Starting login with user 'wrongname#company.com'
-------------------------------------------------------------------------------------
Please provide your Apple Developer Program account credentials
The login information you enter will be stored in your macOS Keychain
You can also pass the password using the `FASTLANE_PASSWORD` environment variable
See more information about it on GitHub: https://github.com/fastlane/fastlane/tree/master/credentials_manager
Why fastlane try to fetch provisionings with wrong user account?
How can I force it to change it?
Where it is defined?
Have you tried setting the user account directly?
https://docs.fastlane.tools/actions/upload_to_app_store/#parameters
https://docs.fastlane.tools/actions/sigh/#parameters
I'm working on mocking endpoints for an iOS app that hits over a dozen different HTTPS hosts. Based on my understanding from the WireMock docs and this answer from the maintainer, WireMock is designed to proxy / mock only one host. My current plan is to use dnsmasq to point one host at WireMock at a time.
+----------+ +-------------------+
| | | |
| WireMock +-->Proxy+---> 123.example.com |
| | | |
+----^-----+ +-------------------+
|
| +-------------------+
+-------+ +----+----+ | |
| +---> https://123.example.com +---> | +-----> xyz.example.com |
| | | | | | |
| App +---> https://xyz.example.com +---> dnsmasq +---+ +-------------------+
| | | |
| +---> https://9.different.com +---> +---+ +-------------------+
+-------+ +---------+ | | |
+-----> 9.different.com |
| |
+-------------------+
This seems pretty clunky, is there a better way to mock multiple hosts like this? One of the primary constraints is that these have to be tested over HTTPS and not unencrypted.
You should be able to achieve this by creating stubs that have a host header condition in the request. That way e.g. a request to
GET /hello
Host: firsthost.example.com
And a request to
GET /hello
Host: secondhost.example.com
would match different stubs and there return different responses.
I am in the process of moving and testing a development site on the actual domain name now and I just wanted to check if I was missing anything and also get some advice.
It is a Magento 1.8.1 install from Turnkey Linux running on an m1.medium instance.
What I have done (so far) is, create an image of the development instance, made a new account and copied it over to there. I then made an elastic IP and associated it with the new instance. Next I pointed the A name record of the production domain to the elastic IP.
Now, if I go to the production domain I get redirected to the development domain. Is there a reason for this?
Ideally I would like to have two instances, one dev one that is off unless needed and of course the production on which is going to be live 24/7. However if I turn the development domain off it stops the other too.
I have a feeling it's just because I need to change instances of the dev domain in the Magento database / back-end however I wanted to get a more knowledgable answer as I don't want to break either of the instance.
Also, I should probably mention that the development domain is a subdomain i.e. shop.mysite.com and the live one is just normal i.e. mysite.com. Not entirely sure this is relevant but thought it worth a mention.
Thanks in advance for any help.
The reason your URL on your new instance is getting redirected to the old URL is because in the core_config_data table of your magento database the web/unsecure/base_url and web/secure/base_url paths point to your old URL.
So if you are using mysql you can query your database as follows:
mysql> use magento;
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
Database changed
mysql> select * from core_config_data;
+-----------+---------+----------+-------------------------------+-------------------------------------+
| config_id | scope | scope_id | path | value |
+-----------+---------+----------+-------------------------------+-------------------------------------+
| 1 | default | 0 | web/seo/use_rewrites | 1 |
| 2 | default | 0 | admin/dashboard/enable_charts | 0 |
| 3 | default | 0 | web/unsecure/base_url | http://magento.myolddomain.com/ |
| 4 | default | 0 | web/secure/use_in_frontend | 1 |
| 5 | default | 0 | web/secure/base_url | https://magento.myolddomain.com/ |
| 6 | default | 0 | web/secure/use_in_adminhtml | 1 |
| 7 | default | 0 | general/locale/code | en_US |
| 8 | default | 0 | general/locale/timezone | Europe/London |
| 9 | default | 0 | currency/options/base | USD |
| 10 | default | 0 | currency/options/default | USD |
| 11 | default | 0 | currency/options/allow | USD |
| 12 | default | 0 | general/region/display_all | 1 |
| 13 | default | 0 | general/region/state_required | AT,CA,CH,DE,EE,ES,FI,FR,LT,LV,RO,US |
| 14 | default | 0 | catalog/category/root_id | 2 |
+-----------+---------+----------+-------------------------------+-------------------------------------+
14 rows in set (0.00 sec)
and you can change it as follows:
mysql> update core_config_data set value='http://magento.mynewdomain.com' where path='web/unsecure/base_url';
mysql> update core_config_data set value='https://magento.mynewdomain.com' where path='web/secure/base_url';